Debugging And ActiveX Script Task In A DTS Package Running On SQL Server 2005

Sep 13, 2006

I have a DTS package that I brought over from SQL server 2000 in to SQL Server 2005. I have installed all of the legacy components to run the DTS packages but I need to debug an ActiveX script task. In SQL Server 2000 I could turn on Just-In-Time debugging and use the stop operator (in my vbscript) to break the running script and launch the debugger.

I don't see how to do this in SQL Server 2005 Management Studio. Is it possible to debug a script object in a DTS package running in SQL Server 2005?



Jay Abbott

View 1 Replies


ADVERTISEMENT

Help Using VBScript In An ActiveX Task In DTS Package

Jan 16, 2004

Hi,

Thanks for reading.

I am creating a DTS package to import a .txt file into sql. I have everything in place, but the text file needs to have the last record deleted before the import. I need help with this part

I would like to delete the last record from a fixed width text file before I import it into sql. The number of rows will vary from file to file.

Can any one offer suggestions on the best way to do this.

I understand that I have to use the FSO to open and read the file, but I am not sure the best way to proceed after that.

Thanks in advance,
Steve

View 1 Replies View Related

Can You Reference A Package Using ActiveX Script Task?

Aug 23, 2007



Using ActiveX Script Task it is possible create office automation objects such as Word and Excel typically using the CreateObject() Syntax. Can you use this syntax to create a Package object using CreateObject("DTS.Package")? If not Why not? I am not sure whether it was possible in DTS.

I am aware of the fact that ActuveX Script Task is included in this Version of SSIS and will be deprecated.

View 2 Replies View Related

About ActiveX Script Error In Ssis Package In SQL Server 2005

Feb 27, 2007

when i run activex Script it's shows this error

[ActiveX Script Task] Error: Retrieving the file name for a component failed with error code 0x001B6438

View 2 Replies View Related

Running A Ssis Package In Sql Server Agent With Execute Process Task

Apr 1, 2008

Hello

I'm trying to run a task that executes a script file (cmd). When i run it with in bids with my own users (domain admin) it works. When i start a cmd prompt and try to run the cmd file directly from the network location where it is it works (with my own rights and with the sql server agent user).

Now when i try to run in from smss > agent jobs > job and run job it never completes. Im not getting any error message either it just keeps on running on the step ??? It seems like a rights issue, but the account running the sql server agent is able to execute the cmd file directly from the command prompt.

There are no errors in any error logs anywhere and no error is displayed...

Ps. Im running the job step as a integration service pacgake.

View 8 Replies View Related

Out Of Memory Exception When Running A Package With XML Task

Jun 1, 2007

Hi..



I'm running a package that has a XML Task in the control flow. This task tranforms a XML file with a XSLT.



The file is about 2 megs on a daily basis, but at the end of the month there is a full dump of data that makes the file to be around 400 megs. There is where my problem is.



I run this on my 2 GB memory workstation and when the memory gauge on the task manager reaches about 1.5gb the package fails with an "Out of memory exception".



I also run this package on a 8GB Ram server, and same applies.



Is there any way of making this package utilize all the available memory, I even increased the virtual memory to see if that helped my issue, but nothing.



Thanks

View 10 Replies View Related

SQL Task Works Running The Package But Not When Called Via C#

Jun 13, 2007

This should be a very easy question.



I'm trying to develop an SSIS package that will eventually do many things, but I can't get it to do very basic things.



My current test package has 2 tasks in it:

1) File System Task ( FST )

2) Execute SQL Task ( EST )



When running just the SSIS package via the VS2005 IDE ( as startup project ), everything works fine. The FST moves a file from DIR_A to DIR_B and the EST inserts a test record into the test table.



If I set my C# app to the the startup project and execute the package from within the C#, it kinda works. The FST works fine, but the EST does not work and the package returns a "FAILURE" code to the C#.



The EST is incredibly basic. This is the SQL text:

insert into tmpssis ( tmpdata ) values ( 66 );



I'm using ADO.NET, Direct input, FALSE for IsQueryStoredProcedure, and it's using the only connection I've set up to the database.



The FST block runs - the file gets moved, but then it fails on the SQL block for some reason.



I'm open to any suggestions.

Thanks,

-BEP

View 6 Replies View Related

Get Server Name In ActiveX Where DTS Package Lives

Nov 2, 2000

I'm looking for a way to get the name of the server on which the DTS package lives.

I copy packages between servers. The problem is that everytime a package is copied
to different server, I have to change the reference in the connection strings to point
to the new server name. I'd like to find an automatic way to interrogate the server
name where the package currently lives and dynamically change connection strings
from within an ActiveX task. That would cut maintenance way down.

View 2 Replies View Related

ActiveX Script Running DTS Causes Error

Apr 14, 2005

Hello All,
I have an ActiveX script that runs DTS pachkages. In the event that a package fails I want to display the error message. I found the following code (in bold) for doing this but I keep getting an error message as follows.
Type mismatch 'oSoStep.GetExecutionErrorInfo'
All help appreciated.
Thanks, Gary

View 2 Replies View Related

Debugging SQL Server 2005 Stored Proc With Visual Studio 2005

Aug 2, 2006

Hello,



we have a SQL server 2005 with Visual studio Prof. 2005 in the
employment.



The debuggers function only in Visual studio correctly, as long as no
code on the SQL server must be implemented.



If a BREAK POINT in a Stored Procedure is set, this is not activated,
since this cannot be bound.

Does someone know, what it lies and can like one it eliminate?



Thank you for your assistance in advance.



Yours sincerely

Big_Ben_31

This entry was translated automatically with the translation
service babel.altavista.com from the German into English.

View 1 Replies View Related

Problem When Running A SSIS Master-package-child Package On Non Default Sql-server Instance

Dec 6, 2007

Hi there

We have a SSIS run which runs as follows


The master package has a configuration file, specifying the connect strings
The master package passes these connect-strings to the child packages in a variable
Both master package and child packages have connection managers, setup to use localhost. This is done deliberately to be able to test the packages on individual development pc€™s.
We do not want to change anything inside the packages when deploying to test, and from test to production. All differences will be in the config files (which are pretty fixed, they very seldom change). That way we can be sure that we can deploy to production without any changes at all.

The package is run from the file system, through a job-schedule.

We experience the following when running on a not default sql-server instance (called dkms5253uedw)

Case 1:
The master package starts by executing three sql-scripts (drop foreign key€™s, truncate tables, create foreign key€™s). This works fine.

The master package then executes the first child package. We then in the sysdtslog get:

Error - €œcannot connect to database xxx€?
Info - €œpackage is preparing to get connection string from parent €¦€?

The child package then executes OK, does all it€™s work, and finish. Because there has been an error, the master package then stops with an error.

Case 2:
When we run exactly the same, but with the connection strings in the config file pointing to the default instance (dkms5253), the everything works fine.

Case 3:
When we run exactly the same, again against the dkms5253uedw instance, but now with the exact same databases defined in the default instance, it also works perfect.

Case 4:
When we then stop the sql-server on the default instance, the package faults again, this time with


Error - €œtimeout when connect to database xxx€?
Info - €œpackage is preparing to get connection string from parent €¦€?

And the continues as in the first case

From all this we conclude, that the child package tries to connect to the database before it knows the connection string it gets passed in the variable from the master package. It therefore tries to connect to the default instance, and this only works if the default instance is running and has the same databases defined. As far as we can see, the child package does no work against the default instance (no logging etc.).

We have tried delayed validation in the packages and in the connection managers, but with the same results (error).

So we are desperately hoping that someone can help us solve this problem.


Thanx,
/Nils M - Copenhagen

View 3 Replies View Related

SQL Server 2005 DTS Conversion, Activex And MSDASQL

Mar 29, 2006

Hi all

I am migrating some DTS2000 packages to SSIS via the migration wizard. However there is an activex script in each DTS that connects to an AS400 to retrieve record count for integrity checking. Under SQL server 2000 this worked fine but now it errors with "The OLE DB provider "MSADSQL" has not been registered" how do i get this to work i suspect its because this is a 32 bit dll and my new system is a 64bit sql server on windows 2003. The odbc driver for the as400 has been installed also. The script is as follows:

dim cn 'sql connection
dim rs 'sql recordset for the insertion of new as400 records
dim insertstr 'sql insert string
dim rs1 'sql recordset for the insertion of new as400 records
dim insertstr1 'sql insert string

set cn = createobject("ADODB.Connection")
set rs = createobject("ADODB.Recordset")

Function Main()
'set up connection for sql
cn.provider="sqloledb"
cn.commandtimeout = 3600 'timeout in seconds
cn.open %sqlserver05%, %user%, %password%

'populate temporary table in sql with recordset from as400 odbc
insertstr1 = "Insert into db.dbo.%table% select 'table name',a.* from openrowset ('MSDASQL','DRIVER={Client Access ODBC Driver (32-bit)};SYSTEM=%system name%;UID=%username%;PWD=%password%','SELECT count(*) from %table%') as a"

set rs1 = cn.execute (insertstr1)

'close all objects
cn.close
Main = DTSTaskExecResult_Success
End Function

Does anyone know how i change this to work under sql server 2005. i need to resolve this quickly in order to deliver a project on time. Many thanks

Chris

View 6 Replies View Related

Debugging SQL CLR Hangs With SQL Server 2005 And VS 2005

Apr 2, 2007

Hello,



I am having a problem with SQL Server (Express) hanging during simple debugging of CLR code. I created a test project with a user defined function, and call this from the test script. The output log shows that the sqlservr.exe was auto-attached successfully, and then the everything hangs. I have to terminate debugging in order to regain control, and this takes perhaps a minute or two.



Any ideas?

View 11 Replies View Related

DTS ActiveX Script Task..vanished

Feb 9, 2004

I have no idea what's going on.. but when I open the SQL DTS designer.. there's no ActiveX Script task on the left toolbar anymore. It used to be there. How do I get it back?? I remember playing around with some dts dll files on my machine... maybe I did something that made it go away (note: the DB server is not on my machine.. I just run Enterprise Manager on my machine to access it). Should I reinstall Enterprise Manager?

View 1 Replies View Related

ActiveX Script Task - SSIS

Apr 3, 2006

Within a SQL 2000 DTS Package I have an ActiveX Script that would go within my transform tasks and update the queries by concatenating a "Where" clause with a date from a database table. This way I could keep track of when the last time I updated the table so that I could only bring down the rows since the last run. How can this be done within SSIS? I've been looking and I'm getting confused. Any help would be greatly appreciated.

View 2 Replies View Related

ActiveX Script Task] Error:

Jan 27, 2006

Hi,
 I'm trying to reset the below  Global varialbe in SSIS - Activex script.

Function Main()
DTSGlobalVariables("GxvFilename").value =null
Main = DTSTaskExecResult_Success
End Function

Getting the below  Error when executing the package.

[ActiveX Script Task] Error: Retrieving the file name for a component failed with error code 0x060339E4


Please provide me solution for this.

Thanks,

 

 

View 2 Replies View Related

Running Reporting Services ExecutionLog DTS Package In SQL 2005

Feb 21, 2006

I need some help, I am new to Microsoft SQL Server 2005 Integration Services and I am having some problems running Reporting Services ExecutionLog Package in Integration Services. After setting up and running the package, I received this warning message : "Truncation may occur due to inserting data from data flow column 'InstanceName' with a length of 38 to database column 'InstanceName' with a length of 32". I have modified the column length for 'InstanceName' from 32 to 38 in the affected table but I am still receiving this warning message : "The external metadata column collection is out of synchronization with the data source columns. The column 'InstanceName' needs to be updated in the external metadata column collection"

How do I update column 'InstanceName' in the external metadata column collection?

Where do I find the package steps logs (sysdtspackagelog or sysdtssteplog) when running the package as a job or manually.

View 1 Replies View Related

Debugging Script Task

Jul 14, 2006

Hi,

I'm trying to debug a Script Task. I set a breakpoint then start debug. I always get a COM Exception error:



unhandled exception occurred in DTAttach.exe[3332]

File position not valid for new breakpoint



Can someone suggest me something?



Thanks

View 3 Replies View Related

Reconcile ADO Dataset From ActiveX Script Task

May 12, 2006

I'm having a bear of a time with this. I have a recordset that pulls data from one, single table. I would like to iterate through the set, do some processing based on that data, then delete all of the records in that recordset.

I'm trying to do something like the following:


Set dbConn = CreateObject("ADODB.Connection")
Set dbRS = CreateObject("ADODB.Recordset")

dbConn.Open("myConnectString")
dbRS.open dbSQLCmdText, dbConn, 2, 4

While Not dbRS.EOF
Do some stuff
dbRS.Delete
Wend

dbRS.BatchUpdate

dbRS.Close
dbConn.Close


I get an error stating:

"Multiple-Step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done."

This seems to indicate the connection doesn't think it's capable of reconciling the recordset. Is there a way to do this in one batch or should I stick with executing a single delete statement for every record in my recordset?

View 2 Replies View Related

Calling Stored Procedure From An ActiveX Task

Jun 6, 2006

I'm attempting to call a storedprocedure from within an ActiveX task ina DTS and am getting a "Command Text was not set for the commandobject" error. I have no problem if I replace the stored procedure callwith the actual SQL.Is it possible to directly call a SP via an ActiveX task? If yes, couldsomebody help me with the syntax please?This is what I have currently haveSet Conn = CreateObject("ADODB.Connection")SQL = "exec (MySP)"set RLoop=conn.Execute(SQL)do while (NOT RLoop.EOF)msgbox RLoop(1)RLoop.MoveNextLoopTIAKarthik

View 1 Replies View Related

ActiveX Script Task/Function Not Found

Jul 3, 2006

We have a SQL Server 2005 Cluster that we are trying to send email from to notify when certain jobs have completed, failed, etc. We are having a bit of a problem getting the email to work and I believe that the failure is at the SMTP server, not at the SQL level.

That being said, I'm trying to create a simple SSIS package that I can use to test connectivity to the SMTP server with and send email. I've added an ActiveX Script Task that calls a COM object that actually sends the email. I keep getting a "Function not found." error when I try to execute the package, and I have no idea why I'm getting that. It says that the errors were found during validation.

Can anyone help?

View 3 Replies View Related

Error Running SQL 2005 SSIS Package When Calling It From MS Access

Dec 17, 2007


I am trying to execute an SSIS package from an MS Access 2003 database that imports a table from the Access database into a target table in SQL 2005. I saved the package in SQL 2005 and tested it out. If I run it from the Management Studio Console with Run->Execute ... everything works just fine. However, if I try to run it using "Exec master.dbo.xp_cmdshell 'DTExec /SER DATAFORCE /DTS SQL2005TestPackage /CHECKPOINTING OFF /REPORTING V'" the execution will always fail when the Access database is open (shared mode). It will only work when the Access database is not open. The connection manager looks like this: "Data Source=E:Test.mdb;Provider=Microsoft.Jet.OLEDB.4.0;Persist Security Info=False;Jet OLEDB:Global Bulk Transactions=1". The error is listed below:

Code: 0xC0202009
Source: NewPackage Connection manager "SourceConnectionOLEDB"
Description: An OLE DB error has occurred. Error code: 0x80004005.
An OLE DB record is available. Source: "Microsoft JET Database Engine" Hresult: 0x80004005 Description: "Could not use ''; file already in use.".


What am I doing wrong?

View 5 Replies View Related

Steps For Debugging Stored Procedure In Sql Server 2005

Dec 20, 2007

hi friends,
     Anyone give give me the steps we have to follow for debussing a stored procedure in sql server 2005...
 

View 2 Replies View Related

Problems Debugging A Script Task

Jan 16, 2008

First off, we are talking about a script task and not a script component. I have a task flow that has numerous script tasks. One of these is a script task within a foreach loop container. Prior to this foreach loop container there are two other script tasks. I put my breakpoints in the script task in the foreach loop. When I run DEBUG, some weird things happen:

1. The code breaks at one of the script tasks, prior to the one I entered the breakpoint in.
2. there are no breakpoints that I entered in the script task that the code breaks on.
3. The code does not break in the script task I want it to break in (the one in the foreach loop container).

I've checked the forum and couldn't find out what I need to do to get this to work correctly.

Can someone please shed some light on this problem.

Thanks,
Lee

View 5 Replies View Related

Error While Debugging The Script Task

Sep 13, 2006

I am getting an while trying to run the script task in debug mode in SSIS package.

"SQL Server Integration Services Script Task has encountered a problem and needs to close. We are sorry for the inconvenience."

Any idea why i am getting this error.

Thanks,

View 4 Replies View Related

Debugging A Script Component Task???

Jun 15, 2006

How to debug a Script Component task?

For instance, I€™ve got a Input0_ProcessInputRow procedure and I€™d like to see what happen when compiler reach this line:

dFecha = Left(Row.Column19, 4) & "-" & Mid(Row.Column19, 5, 2) & "-" & Right(Row.Column19, 2)

I€™ve put a toogle breakpoint there and then saved but when I run the package to ignore at all.

This topic has been already discussed in these newsgrups but I still have doubts.
Thanks a lot for any advice or clarification

View 14 Replies View Related

DTS - Updating DataSource Connection Via ActiveX Script Task

Jul 6, 2001

Hi,

I've written a DTS Package to pull information from a number of servers. I have a list of servers (Source Servers) and for each one I automatically update the Datasource property of the Source Server connection using vbscript in an ActiveX Script task and a global variable.

I have a transformation that occurs between the Source server and Target server.

As I process each Source Server in turn, the global variable gets set correctly and so does the Datasource property of the Source Server connection. However the transformation still runs against the first Source Server that was processed.

Looking at BOL it appears that a transformation stays connected even after it has finished. Therefore I assume that although I change the Datasource of the connection to a new server, it still runs against the first server that was used.

My question is how do I get the connection to run against the updated Datasource, i.e. do I need to do a refresh of the Connection, disconnect or what ?

Any ideas would be much appreciated.

thanks

View 2 Replies View Related

SSIS Crash When Debugging Script Task

Feb 14, 2008

I'm getting the error Visual Studio has encountered a problem and needs to close. When sending the error report to Microsoft no resolution comes up but another message like:

Microsoft Visual Studio for Applications has lost the link to .
Your work will be exported to C:Documents and Settings.... when you quit the application

Any hints on what I can try?

Thanks in advance, Michael.

View 14 Replies View Related

Edit And Continue While Debugging Script Task

Jul 4, 2007

Hi all,



I have a simple question: is it possible to use Edit and Continue feature when debugging a script task in VSA?

It seems to me that after breaking the execution of the script task and adding some code in break mode, whole edit disappears after leaving VSA environment.

I have enjoyed the Edit and Continue feature when developing in VBA, so I am wondering if it is available in VSA.



Thank you very much for the answer!



Marek Stefanek

View 3 Replies View Related

How To Debugging DTS Package

Nov 5, 2001

I have a script that works in works in Query Analyzer, but when I try to put it in a DTS package, it fails. I have the database set properly in the data source. Can someone give me direction to figure out what is going on?


Brian

View 1 Replies View Related

No Debugging And Logging When A Single Script Task Is Executed

Jul 13, 2006

Hi,

I cannot execute a script task in the VBA code window.

I cannot debug or log if I run a single script task from the right click Execute Task .

Every time I have to run the entire package in order to be able to debug.

What am I missing?

appreciate a help.

Gulden

View 4 Replies View Related

How To Get The Value Of The Variables When I Debugging A Package?

Oct 12, 2007



How to get the value of the variables when i debugging a package?

Thanks!

View 3 Replies View Related

How To Retrieve Global Variables In An ActiveX Script Task Using VBScript In SSIS

Oct 27, 2006

I need to retrieve the Global Variables set in my package configuration file within an ActiveX Script Task within an SSIS package. In DTS, I could access the Global Variables to execute a SQLXMLBulkLoad for the following statement:

==========================================

Function Main()

Response.Expires=-1

set objBL = CreateObject("SQLXMLBulkLoad.SQLXMLBulkLoad")
objBL.ConnectionString =
"provider=SQLOLEDB.1;server=ABC123;database=MyDB;Trusted_Connection=Yes;"
objBL.KeepIdentity = False
objBL.CheckConstraints = False

objBL.Execute DTSGlobalVariables("gv_XSDSchemaFile").Value, DTSGlobalVariables("gv_XMLFullPath").Value

Main = DTSTaskExecResult_Success
set objBL=Nothing

End Function
=========================================

I have tried using the Script Task to write this in VB.NET, however the MSXML4.0 is not exposed within the limited object model of the Script Task Designer. I have written a Data Flow Object using the XML Source, however it requires quite a bit of effort to have the Data Flow Component parse the XML (with 10 hierarchical nodes), transform each and provide a SQL Server Destination. This works, however the XML Source Component requires a hardcoded reference to the XSD Schema file and does not allow for a Global Variable to used. (They do provide this functionality for the XML file source though).

My requirement is to allow for the Global Variable to be passed for the Schema file at runtime. The only way I can think of is to recreate what I was doing in DTS where I could simply pull in the XML and XSD Global Variables and execute the SQLXMLBulkLoad in VB Script.

Any ideas on how to write this in VBScript within the ActiveX Script Task in SSIS?...

Michael

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved