Error with Parameters named "like" variables
Posted: Fri 23 Nov 2018 17:46
Hello,
I have a problem with TMSQuery, supose this simple SQL put into a TMSQuery.SQL property
DECLARE @CLIENTE_ID INT
SET @CLIENTE_ID = :CLIENTE_ID
SELECT 'CLIENTE :'+CAST(@CLIENTE_ID AS VARCHAR)
When Set Active the component, get thiw message :
The name of variable @CLIENTE_ID has already been declared. The names of variables must bue unique on every batch os queries or stored procedures
Do you know a way to fix this error.
I have used this kind of querys years ago with BDE, TADOQuery, TFDQuery but is not working with TMSQuery.
Thank you!
I have a problem with TMSQuery, supose this simple SQL put into a TMSQuery.SQL property
DECLARE @CLIENTE_ID INT
SET @CLIENTE_ID = :CLIENTE_ID
SELECT 'CLIENTE :'+CAST(@CLIENTE_ID AS VARCHAR)
When Set Active the component, get thiw message :
The name of variable @CLIENTE_ID has already been declared. The names of variables must bue unique on every batch os queries or stored procedures
Do you know a way to fix this error.
I have used this kind of querys years ago with BDE, TADOQuery, TFDQuery but is not working with TMSQuery.
Thank you!