AnsweredAssumed Answered

eSQL and underscore question

Question asked by glorifindal on Nov 23, 2015
Latest reply on Nov 23, 2015 by beverly

Hi there,

greetings from Thailand.

 

I'm having trouble with the following - I think that I have correctly escaped the field name within the sub query ...

 

[code]

$_qry = "SELECT id_phase

FROM SQLphase

WHERE id_phase IN (SELECT id_phase FROM SQLphase2project WHERE id_project =? AND \”_Flag|x|REM\” =1 ) AND id_client =? " ;

$_target.phase =

ExecuteSQL ( $_qry ; field.sep ; row.sep ; $_cur.project.id ; $$_clientID ) ;

[/code]

 

When I remove the AND \”_Flag|x|REM\” =1 from the subquery it works fine - it returns the record set that I expect.

When I leave it in - it returns a question mark.

Is it due to the pipes in the field name ? I thought that the escaping would take care of that.

 

My head is splitting . many thanks for any help, rebuke, advice etc

 

Kindest

 

G

Outcomes