1 of 1 people found this helpful
As you wrote, add AND phrase with "?" for parameter, then add parameter value in function call.
quote = //<quoteID from current table>
; query =
SELECT SUM ( <number field in line item table> )
FROM <name of line item table>
WHERE <category field in line item table> = 'keyword'
AND <foreign key field in line item record> = ?
; result = ExecuteSQL ( query ; "" ; "" ; quote )
3 of 3 people found this helpful
I would also pass the 'keyword' literal/constant as a parameter.
Sent from miPhone
Thank you very much for your help. Your syntax worked and I was also able to adapt it to the rest of a series of subtotals.
Thanks Beverly. That's also helpful—helps me to get my head around the overall syntax and how best to manipulate it.