Hi Folks
I have an Execute SQL Task where I have created a Parameter Mapping for System::UserName, Direction is input, Parameter = 0 and Parameter Size = -1.
I am attempting to insert the username into the a table in the CreatedBY field using an OLEDB connection with a query like below
Insert into Table A ([UPDATED], [CREATEDBY]) Select 'Customer Name' as UPDATED, ? from Table B
I have also tried a DECLARE @UID Varchar(255), Set @UID = ? and used @UID in place of the ? but still get the same error. But this works fine if I change the ? to a text value like 'AlfE' so I assume I have not got the parameter mapping working correctly for some reason.
The error I get "error executing the query "insert into...failed with the following error Incorrect Syntax near ). Possible failure reasons Problem with the query, resultset property not set correctly.
Thanks
Binway
Binway