cubicweb #491212 RQL variable AS [resolved]

RQL can generate AS variable wich is SLQ reserved variable.

exemple :

DISTINCT Any U,V ORDERBY V WHERE X is WorkCase, X creation_date AA, X title AB, X modification_date AC, S for_workcase X, S with_company
T, S type 'client', U included_in W, U applied_to T, U name V, W applied_to_field 'code_naf'
ReST / HTML errors:System Message: WARNING/2 (&lt;string&gt; , line 7)</p>
Definition list ends without a blank line; unexpected unindent.

2009-10-20 17:41:21 - (cubicweb.sources.system) CRITICAL: sql: 'SELECT DISTINCT AS.cw_eid, AS.cw_loginnFROM created_by_relation AS rel_ created_by0, cw_CWUser AS AS, cw_WorkCase AS XnWHERE rel_created_by0.eid_from=X.cw_eid AND rel_created_by0.eid_to=AS.cw_eidnORDER BY 2 '

ReST / HTML errors:System Message: ERROR/3 (&lt;string&gt; , line 10)</p>
Unexpected indentation.
args: {}
ReST / HTML errors:System Message: WARNING/2 (&lt;string&gt; , line 11)</p>
Block quote ends without a blank line; unexpected unindent.
dbms message: 'ERREUR: erreur de syntaxe sur ou prxc3xa8s de xc2xab AS xc2xbbnLINE 1: SELECT DISTINCT AS.cw_eid, AS.cw_loginn
^n'
ReST / HTML errors:System Message: WARNING/2 (&lt;string&gt; , line 13)</p>
Definition list ends without a blank line; unexpected unindent.

2009-10-20 17:41:21 - (cubicweb.sources.system) CRITICAL: transaction has been rollbacked 2009-10-20 17:41:21 - (cubicweb.repository) ERROR: unexpected error Traceback (most recent call last):

ReST / HTML errors:System Message: ERROR/3 (&lt;string&gt; , line 16)</p>
Unexpected indentation.
File "/home/katia/src/prive/fcube/cubicweb/server/repository.py", line 610, in execute
build_descr)
File "/home/katia/src/prive/fcube/cubicweb/server/querier.py", line 650, in execute
results = plan.execute()
File "/home/katia/src/prive/fcube/cubicweb/server/querier.py", line 163, in execute
result = step.execute()
File "/home/katia/src/prive/fcube/cubicweb/server/ssplanner.py", line 286, in execute
inputmap)
File "/home/katia/src/prive/fcube/cubicweb/server/sources/native.py", line 324, in syntax_tree_search
cursor = self.doexec(session, sql, args)
File "/home/katia/src/prive/fcube/cubicweb/server/sources/native.py", line 431, in doexec
cursor.execute(str(query), args)
ReST / HTML errors:System Message: WARNING/2 (&lt;string&gt; , line 28)</p>
Block quote ends without a blank line; unexpected unindent.

ProgrammingError: ERREUR: erreur de syntaxe sur ou près de « AS » LINE 1: SELECT DISTINCT AS.cw_eid, AS.cw_login

Docutils System Messages

ReST / HTML errors:System Message: ERROR/3 (&lt;string&gt; , line 7); <em>backlink</em></p>
Unknown target name: "rel".
priorityimportant
typebug
done in3.5.5
load left0.000
closed by<not specified>