#27458 closed Bug (fixed)
Oracle backend giving ORA-00911 : Invalid Character, querying with a literal "%s"
Reported by: | Gabriel Canto de Souza | Owned by: | Andrew Nester |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | dev |
Severity: | Normal | Keywords: | Oracle |
Cc: | felisiak.mariusz@…, Simon Charette | Triage Stage: | Ready for checkin |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
This happened after trying to create a new object in the Django Admin interface which has a many to many field with another class, the full html debug page is attached to the ticket
The last query before the error was raised is this :
'SELECT "GEO"."DJANGO_PESSOA"."OBJECTID" FROM "GEO"."DJANGO_PESSOA" INNER '
'JOIN "GEO"."DJANGO_DOCUMENTO"_PF951 ON ("GEO"."DJANGO_PESSOA"."OBJECTID" = '
'"GEO"."DJANGO_DOCUMENTO"_PF951."DJANGOTESTPESSOA_ID") WHERE '
'"GEO"."DJANGO_DOCUMENTO"_PF951."DJANGOTESTDOCUMENTO_ID" = %s'
models.py:
from __future__ import unicode_literals from django.db import models class DjangoTestPessoa(models.Model): objectid = models.BigIntegerField(primary_key=True,unique=True) nome = models.CharField(max_length=150, blank=True, null=True) class Meta: db_table = '"GEO"."DJANGO_PESSOA"' class DjangoTestDocumento(models.Model): objectid = models.BigIntegerField(primary_key=True,unique=True) numero = models.CharField(max_length=150, blank=True, null=True) pessoas = models.ManyToManyField(DjangoTestPessoa) class Meta: db_table = '"GEO"."DJANGO_DOCUMENTO"'
Change History (13)
comment:1 by , 8 years ago
Cc: | added |
---|---|
Keywords: | Oracle added; cx_oracle ora-00911 removed |
Triage Stage: | Unreviewed → Accepted |
comment:2 by , 8 years ago
comment:4 by , 8 years ago
Has patch: | set |
---|---|
Owner: | changed from | to
Status: | new → assigned |
Just created pull request for this ticket PR
comment:5 by , 8 years ago
Patch needs improvement: | set |
---|
comment:6 by , 8 years ago
Patch needs improvement: | unset |
---|
I've updated pull request, that's why Patch needs improvement set to No
comment:7 by , 8 years ago
Cc: | added |
---|---|
Triage Stage: | Accepted → Ready for checkin |
Version: | 1.10 → master |
LGTM pending a final docstring review of the strip_trailing_quotes
function from a native speaker.
comment:8 by , 8 years ago
Patch needs improvement: | set |
---|---|
Triage Stage: | Ready for checkin → Accepted |
I left some comments for improvement on the PR and closed #18514 as a duplicate.
comment:9 by , 8 years ago
Patch needs improvement: | unset |
---|---|
Triage Stage: | Accepted → Ready for checkin |
Would you like to prepare PR? If not, assign it to me.