sql syntax for Data Driven Query


I am quite new to DTS but have decided (so far anyway) that a Data Driven Query is the solution to my problem of keeping a SQL Server database updated from an old Sybase Adaptive Server anywhere db.

We originally used the Transform data task which is great and fast but we need to ability to update the record if it exists in the destination the next time the transfer is done.

We have placed a Data Driven Query in our visual editor within EM and have set (what we think) it up correctly but when we try and run it we receive the following error :-

Error Source : Microsoft Data Transformation Services (DTS) Data Pump
Error Description : DataDrivenQuery: No query specification returned by Transform Status.

Here is the basic (for our test) query for INSERT :-

INTO TicketHeaders(TicketNumber, Contract, Currency, Exchange)
VALUES     (?, ?,?,?)

Any thoughts to what we are doing wrong?


Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Could you give some more information please -->
 ie the paramater place holders you have in the insert statement
have they been assigned to global variables, where do you set these global variables?
JAMESAuthor Commented:
We dont set them - we assumed they would be populated from the "source" table as they are mapped in the transformations tab.
nope thats your problem, the parameter place holders are for inputs into a query and must be set explicitly
You willl notice the parameter tab on the DataDriveQuery task , when you click this then you will notice a list in which  you assign global variables to the parameters.

What you rather want to do , is  program the logic into the ActiveXScript of the Transform Task (DTSDestination...  = DTSSource... ),
You could make use of the Lookups here .. Lookup will return a single value for each processed row from which you could for example
determine if the record already exists.

You would check out this site, it is an excellent resource for DTS programming


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
JAMESAuthor Commented:
Great thanks.

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.