Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All, so I want to limit row to 1 when ingest the data from production.
In My tDBInputMySQL, iquery like this:
"select `xid`,
`yid`,
`zid`
from BLABLA.FIN"+StringHandling.DQUOTE("record") "where limit = 1"
It returns syntax error delete this token ""where limit = 1""
"select `xid`,
`yid`,
`zid`
from BLABLA.FIN"+StringHandling.DQUOTE("record") where limit =1
It returns where where cannot resolved to a type talend
What went wrong? What should I do?
Hi
The key world limit in a query is used to limit the number of return records, for example:
"select `xid`,
`yid`,
`zid`
from BLABLA.FIN"+StringHandling.DQUOTE("record") limit 1"
I don't understand your requirement about "delete this token where limiting rows = 1", if you want to do further action such as delete something if the query only return 1 row, there is a global variable available for you to check the number of returning lines.
((Integer)globalMap.get("tDBInput_1_NB_LINE"))
Regards
Shong