Project

General

Profile

Actions

Bug #19246

open

Long integer value in Tasks in WebU gives error: Oops, we're sorry but something went wrong PG::Error: ERROR: value "1489607391328" is out of range for type integer

Added by Adam Ruzicka almost 7 years ago. Updated over 5 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1440157

Description of problem:

When put a long integer, 1489607391328 for example into the Task Search then receive the following error:

Oops, we're sorry but something went wrong PG::Error: ERROR: value "1489607391328" is out of range for type integer LINE 11: WHERE "foreman_tasks_task_groups"."id" = '1489607391328' ))... ^ : SELECT DISTINCT "foreman_tasks_tasks"."id", "foreman_tasks_tasks"."started_at" AS alias_0 FROM "foreman_tasks_tasks" INNER JOIN "foreman_tasks_locks" ON "foreman_tasks_locks"."task_id" = "foreman_tasks_tasks"."id" LEFT OUTER JOIN "foreman_tasks_task_group_members" ON "foreman_tasks_task_group_members"."task_id" = "foreman_tasks_tasks"."id" LEFT OUTER JOIN "foreman_tasks_task_groups" ON "foreman_tasks_task_groups"."id" = "foreman_tasks_task_group_members"."task_group_id" INNER JOIN foreman_tasks_locks AS foreman_tasks_locks_owner ON (foreman_tasks_locks_owner.task_id = foreman_tasks_tasks.id AND foreman_tasks_locks_owner.resource_type = 'User' AND foreman_tasks_locks_owner.name = 'task_owner') INNER JOIN users ON (users.id = foreman_tasks_locks_owner.resource_id) WHERE (("foreman_tasks_tasks"."id" ILIKE '%1489607391328%' OR "foreman_tasks_tasks"."label" ILIKE '%1489607391328%' OR "foreman_tasks_tasks"."state" ILIKE '%1489607391328%' OR "foreman_tasks_tasks"."result" ILIKE '%1489607391328%' OR "foreman_tasks_tasks"."parent_task_id" ILIKE '%1489607391328%' OR foreman_tasks_locks."resource_type" ILIKE '1489607391328' OR foreman_tasks_locks."resource_type" = '1489607391328' OR users.login = '1489607391328' or users.firstname = '1489607391328' OR users.login ILIKE '1489607391328' or users.firstname ILIKE '1489607391328' OR users.login ILIKE '1489607391328' or users.firstname ILIKE '1489607391328' OR "foreman_tasks_tasks"."id" IN (SELECT "foreman_tasks_tasks"."id" FROM "foreman_tasks_tasks" INNER JOIN "foreman_tasks_task_group_members" ON "foreman_tasks_tasks"."id" = "foreman_tasks_task_group_members"."task_id" INNER JOIN "foreman_tasks_task_groups" ON "foreman_tasks_task_group_members"."task_group_id" = "foreman_tasks_task_groups"."id" WHERE "foreman_tasks_task_groups"."id" = '1489607391328' ))) ORDER BY "foreman_tasks_tasks"."started_at" DESC NULLS LAST LIMIT 20 OFFSET 0

and in the tasks state it gives error as:

Runtime Error RESTEASY001185: Could not find resource for relative : /products//content/1489607391328 of full path: https://localhost:8443/candlepin/products//content/1489607391328?enabled=true at org.jboss.resteasy.core.registry.PathParamSegment.matchPattern:209"

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Go to Satellite WebUI --> Monitor --> Tasks --> Put the integer value (Eg 1489607391328
2.
3.

Actual results:
A error message is displayed

Expected results:
It should show the task.

Additional info:

Actions #1

Updated by Adam Ruzicka almost 7 years ago

  • Subject changed from Long integer value in Tasks on Satellite WebU gives error: Oops, we're sorry but something went wrong PG::Error: ERROR: value "1489607391328" is out of range for type integer to Long integer value in Tasks in WebU gives error: Oops, we're sorry but something went wrong PG::Error: ERROR: value "1489607391328" is out of range for type integer
  • Target version set to 113

If the provided search query is not in the form of "$key $operator $value", scoped search searches in all columns which don't have :explicit_only => true. It may raise database error if it tries to search for a large number on an integer column

Actions

Also available in: Atom PDF