﻿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
31589	Raw queries do not work if any DB content column has the % symbol.	jotauses	nobody	"**Only fails if any DB content column has the % symbol**.

{{{
query_postgresql = """"""SELECT *, similarity(titulo, '{0}') AS similarity FROM pdc_pdc  ORDER BY similarity DESC;""""""

pdc = Pdc.objects.raw(query_postgresql.format(titulo_infocor))
}}}

Column ""titulo"" content = ""This is a test 80%"".


Traceback:

{{{
  File ""C:\Users\-----\AppData\Local\Programs\Python\Python38-32\lib\site-packages\django\db\backends\utils.py"", line 86, in _execute
    return self.cursor.execute(sql, params)
IndexError: tuple index out of range
}}}



"	Bug	closed	Database layer (models, ORM)	3.0	Normal	invalid	raw query		Unreviewed	0	0	0	0	0	0
