Hello all.
Help needed here from anyone who has done this before or have an idea of how to do this.
SITUATION: I have an ASP page that creates a DTS.Package object in order to initialize and run a DTS package i will create on my MS SQL Server 2000 database. Package name is [COLOR=red yellow]pkgExtract[/color]. The ASP code when called will create an SQL statement and store it in a string variable. That SQL statement needs to be run by the DTS package in order to, in the end, generate a file that is a database extraction of specified data.
PROBLEM: How does one send an SQL statement as a globalvariable parameter to a DTS package and have it be execute by the package?
DISCLAIMER (sort of): i'm not a SQL Server/DTS Package guru, quite new to it actually. Possible solutions i thought of were to put the sql statement into a temporary database table, then pull the value out of the table when the DTS package starts. The problem still exists i think, i.e. once the sql statement value is retrieved from the database, can i still run it directly in the package? do i just do that in the 'ActiveX Script Task' part of the dts package?
Any thoughts or ideas would be greatly appreciated.
- skurpyun
Help needed here from anyone who has done this before or have an idea of how to do this.
SITUATION: I have an ASP page that creates a DTS.Package object in order to initialize and run a DTS package i will create on my MS SQL Server 2000 database. Package name is [COLOR=red yellow]pkgExtract[/color]. The ASP code when called will create an SQL statement and store it in a string variable. That SQL statement needs to be run by the DTS package in order to, in the end, generate a file that is a database extraction of specified data.
PROBLEM: How does one send an SQL statement as a globalvariable parameter to a DTS package and have it be execute by the package?
DISCLAIMER (sort of): i'm not a SQL Server/DTS Package guru, quite new to it actually. Possible solutions i thought of were to put the sql statement into a temporary database table, then pull the value out of the table when the DTS package starts. The problem still exists i think, i.e. once the sql statement value is retrieved from the database, can i still run it directly in the package? do i just do that in the 'ActiveX Script Task' part of the dts package?
Any thoughts or ideas would be greatly appreciated.
- skurpyun