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.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 DTS.PackageInfo

Author  Topic 

nr
SQLTeam MVY

12543 Posts

Posted - 2002-07-23 : 08:48:24
I am trying to access this from VB (as a precursor to coding it in a stored proc)
VB6, sql server 7
and the code

dim objPck as DTS.PackageSQLServer
dim objPckInfs as DTS.PackageInfos
dim objPckInf as DTS.PackageIno
dim objDTSApp as new DTS.Application

set objPck = objDTSApp.GetPackageSQLServer("local)","sa","pwd",DTSSQLStgFlag_def
set objPckInfs = objPck.EnumPackageInfos("", false, "")

for each objPckInf in objPckInfs
next

and also

set objPckInf = objPckInfs.next

both give the error Column does not exist when trying to set objPckInf.

objPckInfs.EOF is false

I can execute objPckInfs.next and get the column error until EOF = true (and it is iterating through the packages) in which case it will succeed - so it is probably something wrong with the cration of the PackageIno object.

Anyone else tried this?


==========================================
Cursors are useful if you don't know sql.
Beer is not cold and it isn't fizzy.

Edited by - nr on 07/23/2002 09:55:42

nr
SQLTeam MVY

12543 Posts

Posted - 2002-07-23 : 10:46:28
It's something wrong with my installation of sql server (or sql server in general). It works fine on v2000.
I don't even have the sp in msdb on v7 to enumerate the log recs.
I'll have a look at some other installations and see if it is just a problem with v7.


==========================================
Cursors are useful if you don't know sql.
Beer is not cold and it isn't fizzy.
Go to Top of Page

Page47
Master Smack Fu Yak Hacker

2878 Posts

Posted - 2002-07-23 : 11:28:20
quote:

It's something wrong with my installation of sql server (or sql server in general). It works fine on v2000.
I don't even have the sp in msdb on v7 to enumerate the log recs.
I'll have a look at some other installations and see if it is just a problem with v7.


==========================================
Cursors are useful if you don't know sql.
Beer is not cold and it isn't fizzy.



V7 doesn't log DTS packages does it?

<O>
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2002-07-24 : 06:09:12
Probably not.
I think I can get all the properties from the package to script evrything for sourcesafe - just can't find the package names.
I can do that from sysdtspackages and sysdtscategories though.

Don't know whether I will go as far as creating the packages from scripts but I might. It would be consistent with everything else.

Hate companies that decide to use technology just because it's there whether it's suitable or not.

==========================================
Cursors are useful if you don't know sql.
Beer is not cold and it isn't fizzy.
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2002-07-25 : 06:18:41
Thoughts about dts - see signature.

==========================================
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.
Go to Top of Page
   

- Advertisement -