Re: [cx-oracle-users] [SPAM] How to perform a subquery??
Brought to you by:
atuining
From: Shai B. <sh...@pl...> - 2015-10-06 23:11:43
|
Hi Eduardo, On Tuesday 06 October 2015 23:25:48 Eduardo Nascimento wrote: > > My question is how to do a subquery, every time is like a subquery displays > an error: > What makes you think the problem is with subqueries? > DatabaseError: ORA-00936: missing expression > > > Attached the file that I am using sql and script in python. > > > > Could help me with this issue? Try executing the queries one-by-one. Your current code tries to execute a string with several queries in it as if it were one query (and if I understand correctly, the error is caused because Oracle sees, in the first query: ... group by mc.conn_source_1 -select ... Oracle tries to parse that as an expression -- (mc.conn_source_1 - something) except that, instead of "something", it finds the reserved word "select" -- hence a missing expression. HTH, Shai. |