![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hello Gurus, I have SQL 2000 DTS package transfers data from one server to another server. I have execute sql task with following sql SELECT count(*) FROM table1 In output parameter i have created Global variable with output parameter type =Rowset On sucess i call following activexscript set objResults = DTSGlobalVariables("gResultsMaterial").Value while not objResults.EOF strRecord = "Records transferred: " & objResults.Fields(0).value objStream.WriteLine(strRecord) (ObjStream is File System Object to write output in txt file) objStream.WriteBlankLines(1) objResults.MoveNext wend sometimes, instead of writing exact count(*) as result in text file, it is resulting ZERO. This does not happen everyday, almost twice in a week. I have scheduled (windows scheduler) to run dts package, all i have following code in that batch file. dtsrun /s SERVERNAME /E /N myDTSpackagename Any help, Thanks, Krish |
#3
| |||
| |||
|
|
Would this not be a row value as opposed to the Rowset? The value is then in the Global Variable -- Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP) www.SQLDTS.com - The site for all your DTS needs. www.SQLIS.com - SQL Server 2005 Integration Services. www.Konesans.com "Krish" <NOspam (AT) Nospam (DOT) org> wrote in message news:urGXFLaUFHA.1204 (AT) TK2MSFTNGP10 (DOT) phx.gbl... Hello Gurus, I have SQL 2000 DTS package transfers data from one server to another server. I have execute sql task with following sql SELECT count(*) FROM table1 In output parameter i have created Global variable with output parameter type =Rowset On sucess i call following activexscript set objResults = DTSGlobalVariables("gResultsMaterial").Value while not objResults.EOF strRecord = "Records transferred: " & objResults.Fields(0).value objStream.WriteLine(strRecord) (ObjStream is File System Object to write output in txt file) objStream.WriteBlankLines(1) objResults.MoveNext wend sometimes, instead of writing exact count(*) as result in text file, it is resulting ZERO. This does not happen everyday, almost twice in a week. I have scheduled (windows scheduler) to run dts package, all i have following code in that batch file. dtsrun /s SERVERNAME /E /N myDTSpackagename Any help, Thanks, Krish |
#4
| |||
| |||
|
|
You are right, it should be row value, but iam not sure how it works sometime and does not work sometime. Thanks, Krish "Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote Would this not be a row value as opposed to the Rowset? The value is then in the Global Variable -- Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP) www.SQLDTS.com - The site for all your DTS needs. www.SQLIS.com - SQL Server 2005 Integration Services. www.Konesans.com "Krish" <NOspam (AT) Nospam (DOT) org> wrote Hello Gurus, I have SQL 2000 DTS package transfers data from one server to another server. I have execute sql task with following sql SELECT count(*) FROM table1 In output parameter i have created Global variable with output parameter type =Rowset On sucess i call following activexscript set objResults = DTSGlobalVariables("gResultsMaterial").Value while not objResults.EOF strRecord = "Records transferred: " & objResults.Fields(0).value objStream.WriteLine(strRecord) (ObjStream is File System Object to write output in txt file) objStream.WriteBlankLines(1) objResults.MoveNext wend sometimes, instead of writing exact count(*) as result in text file, it is resulting ZERO. This does not happen everyday, almost twice in a week. I have scheduled (windows scheduler) to run dts package, all i have following code in that batch file. dtsrun /s SERVERNAME /E /N myDTSpackagename Any help, Thanks, Krish |
![]() |
| Thread Tools | |
| Display Modes | |
| |