>>=SQLEXEC(lnHandle, "sp_NewID" + lcBaseTable, "newid")
>>
>>So the table name is part of the stored procedure name and is not a parameter.
>>Mat
>
>You might want to check with Kevin and see if that may supposed to be:
>
>=SQLEXEC(lnHandle, "sp_NewID " + lcBaseTable, "newid")
>
>cause I can't see writing a SP for every table, but I can see writing ONE that accepts the tablename as a parameter.
>
>BOb
Bob,
Actually, you are correct. The code does contain the space to pass the table as a parameter. I did not see it until you pointed it out. I will have to create the stored procedure like you suggested.
My mistake came in executing the code from the command window and the space got "lost".
Kind Regards,
Mat