The following statements create a query with a parameter. The parameter in the SQL statement, preceded by a colon, automatically creates the corresponding element in the params array.

q = new Query( )

q.sql = "select * from CUST where CUST_ID = :custid"

q.params[ "custid" ] = 123

q.active = true