Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2003-01-10 : 08:31:52
|
| Ashish Dhar writes "I want to ask query related to DTSGlobalvariable.How can I get a column value against DTSGlobalvariablee.g;I have a Containers table and I have CntrNo as a Column in it and what I want is how can I pass SQL statement in a DTSGlobalVariable.SQL query is as:"Select * from Containers where CntrNo=?"I want the value for CntrNo through DTSGlobalvariable till there are no records for CntrNo in the Containers table.If you have any clarifications to be made please mail meRegardsAshish" |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2003-01-10 : 08:42:03
|
| Just define a global variable a CntrNo, load the package set the variable then execute.Better to do this from VB but can be done from an SP.See www.nigelrivett.com for loading and setting the variables from an SP.This also shows how to get data from a table in a dts package.Then you just have to loop through the table.Are you sure you want to do this in a dts package though - sounds like a complicated way depending on what you want to do.==========================================Cursors are useful if you don't know sql.DTS can be used in a similar way.Beer is not cold and it isn't fizzy. |
 |
|
|
|
|
|