﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
12721	PostgreSQL problem deleting objects with GenericRelation and non-integer object_id	Karen Tracey	Carl Meyer	"Follow-on from #10015. Failing test case attached.  Failure is:

{{{
======================================================================
ERROR: test_charlink_delete (regressiontests.generic_relations_regress.tests.GenericRelationTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File ""/home/kmt/django/trunk/tests/regressiontests/generic_relations_regress/tests.py"", line 37, in test_charlink_delete
    oddrel.delete()
  File ""/home/kmt/django/trunk/django/db/models/base.py"", line 604, in delete
    delete_objects(seen_objs, using)
  File ""/home/kmt/django/trunk/django/db/models/query.py"", line 1275, in delete_objects
    del_query.delete_batch_related(pk_list, using=using)
  File ""/home/kmt/django/trunk/django/db/models/sql/subqueries.py"", line 65, in delete_batch_related
    self.do_query(f.m2m_db_table(), where, using=using)
  File ""/home/kmt/django/trunk/django/db/models/sql/subqueries.py"", line 27, in do_query
    self.get_compiler(using).execute_sql(None)
  File ""/home/kmt/django/trunk/django/db/models/sql/compiler.py"", line 740, in execute_sql
    cursor.execute(sql, params)
ProgrammingError: operator does not exist: character varying = integer
LINE 1: ...ic_relations_regress_charlink"" WHERE (""object_id"" IN (1) AND...
                                                             ^
HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.


======================================================================
ERROR: test_textlink_delete (regressiontests.generic_relations_regress.tests.GenericRelationTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File ""/home/kmt/django/trunk/tests/regressiontests/generic_relations_regress/tests.py"", line 42, in test_textlink_delete
    oddrel.delete()
  File ""/home/kmt/django/trunk/django/db/models/base.py"", line 604, in delete
    delete_objects(seen_objs, using)
  File ""/home/kmt/django/trunk/django/db/models/query.py"", line 1275, in delete_objects
    del_query.delete_batch_related(pk_list, using=using)
  File ""/home/kmt/django/trunk/django/db/models/sql/subqueries.py"", line 65, in delete_batch_related
    self.do_query(f.m2m_db_table(), where, using=using)
  File ""/home/kmt/django/trunk/django/db/models/sql/subqueries.py"", line 27, in do_query
    self.get_compiler(using).execute_sql(None)
  File ""/home/kmt/django/trunk/django/db/models/sql/compiler.py"", line 740, in execute_sql
    cursor.execute(sql, params)
ProgrammingError: operator does not exist: text = integer
LINE 1: ...ic_relations_regress_textlink"" WHERE (""object_id"" IN (1) AND...
                                                             ^
HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.


----------------------------------------------------------------------
Ran 4 tests in 0.557s

FAILED (errors=2)

}}}

No idea where the fix belongs."		closed	Uncategorized	dev		fixed		ramusus@…	Unreviewed	1	0	0	0	0	0
