>Nir
>
>I assume vClients.client_id is also C(3)
>
>Might be worth trying
>
>
myclient=vClients.client_id
>myTable = 'clients'
>myWhere = 'client_id=?myclient'
>myResult = sqlExec(myCinn,[select * from]+myTable+[ where ]+mywhere,'myCursor')
>
>Regards
>
>JR
The content of myclient (which is equal to the content of vClients.client_id) is an ID value, not a variable name that SQL Server knows about, so try:
myWhere = [client_id =] + ['] + myclients + [']
Alex