cancel
Showing results for 
Search instead for 
Did you mean: 

Incorrect syntax near oinv.docentry

former_member645084
Participant
0 Kudos
127

Hi

On below query i am getting above error

SELECT Top 1 T0.LocCode FROM INV1 T0 WHERE T0.DocEntry = $[OINV.DocEntry]

Thanks

ens_
Active Participant
0 Kudos

jsshivalik,

What is your setup? Where are you running this FS and whats the scenario? The syntax is correct. The problem lies elsewhere.

Sincerely,

Varnavas Eleftheriou

Accepted Solutions (0)

Answers (2)

Answers (2)

msundararaja_perumal
Active Contributor
0 Kudos

Hello,

Of course, if you run the query as its in the query manager, it will throw terror.

This query syntax is intended for only Formatted Search, please assign this query to the field, then the formatted search, it should work fine.

Please do some reading on the formatting search.

Thanks.

Abdul
Active Contributor
0 Kudos

Dear

you cannot get docentry at run time because docentry generates after posting the document instead of docentry use doc number or any other field which has value on run time.