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
 Transact-SQL (2000)
 Using sp_OAXXXXX on a schedule

Author  Topic 

thecremlin
Starting Member

2 Posts

Posted - 2004-05-05 : 11:56:35
Hiya,

We have a stored procedure which utilises sp_OAXXXXX to use COM objects via TSQL.

If we run this stored procedure by hand from say query analyser or execute it via ADO it works.

However, if we setup a "job" to execute the stored procedure at a particular date/time. It fails. The job finishes successfully, it is the call to sp_OAMethod that fails with "error in loading dll".

For our testing the server is local to the machine the application is running on and we have setup the job to run as a system administrator.

Any ideas?

Alex

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2004-05-05 : 13:09:50
I wonder if this has to do with permissions. Jobs run under the account that the SQLSERVERAGENT services logs on with. Check which account you are using for that service. You should be using a domain account that has local admin privs.

Tara
Go to Top of Page

thecremlin
Starting Member

2 Posts

Posted - 2004-05-06 : 11:13:41
We had already thought of this. We have tried running the agent under the local administrator, the domain administrator and various other users all with the same results.

The COM object is a VB 6 ActiveX exe which utilises 2 VB 6 ActiveX DLLs. Is this possibly an issue?

Alex
Go to Top of Page
   

- Advertisement -