This Query works:
system.db.runQuery(select itemdesc from locinv where locid = 1)
This does not work:
InvID = event.source.selectRow + 1
system.db.runQuery(select itemdesc from locinv where locid = InvID)
Please help
This Query works:
system.db.runQuery(select itemdesc from locinv where locid = 1)
This does not work:
InvID = event.source.selectRow + 1
system.db.runQuery(select itemdesc from locinv where locid = InvID)
Please help
You’re going to need to construct the string that’s the argument for system.db.runQuery, or switch to system.db.runPrepQuery (preferred)
InvID = event.source.selectRow + 1
queryString = "select itemdesc from locinv where locid = " + InvID
system.db.runQuery(queryString)
or
InvID = event.source.selectRow + 1
queryString = "select itemdesc from locinv where locid = ?"
system.db.runPrepQuery(queryString, [InvID])
Thank you so very much, it is now working as I expect.