>lcSql = "UPDATE myTable SET myField = ?myValue WHERE pk = ?mypk" > >IF oDataClass.prepare(tnConnection,lcSql) > ** tnConnection is a valid, pre-existing connection to an ODBC datasource > SCAN > mypk = table.pk > myvalue = table.value > IF NOT oDataClass.sql_execute(tnConnection) > ** this is the line that was wrong in the example. > ** You don't pass the SQL when executing a prepared statement > ** Error Handling Code > ENDIF > ENDSCAN >ELSE > ** Error Handling Code >ENDIF > >***oDataClass.prepare >LPARAMETERS tnConnection,tcSql >=SQLPREPARE(tnConnection,tcSql) >** With appropriate error handling >>