Quantcast
Channel: SQL Server Integration Services forum
Viewing all 24688 articles
Browse latest View live

Creating Script Task programatically from C# code in SQL Server 2012

$
0
0
Hello Everyone,

General question is: How can I add a script to Script Task from C# code in SQL Server 2012?

We are using C# to dynamically create SSIS packages. Right now we are working on generating them for SQL Server 2012. Our previous implementation (for SQL Server 2008 R2) was calling VSTATaskScriptingEngine methods: InitNewScript, AddProjectReference, AddCodeFile, SaveScriptToStorage, CloseIDE, Build and ShowDesigner. Sadly it seems these methods had been removed in SQL Server 2012 libraries.

Can anybody point me to a solution to this problem (any reference or direct solution will do)? I've searched for an answer for a while, but so far without any success.

Thanks in advance.

Error: "To run a SSIS Package outside of BIDS you must install the Standard Edition of Integration Services or higher"

$
0
0

Hello!

I am using the MSDN Sql Server 2008 R2 which I thought is supposed to have the full functionality for Sql Server. Does anyone have any idea why I am getting this message when I run in non debug mode (Cntr - F5)?

Thanks
Mike


Mike Kiser

COMBINING DOCUMENTS IN SSIS

$
0
0

I have two tables in sql server 2005 that I have exported in Excel and I have attached the results. I want to create an SSIS Package to update the TABLE2 which has just 2 columns(work_id, pages). The logic here is to look at the TABLE1 and check to see if the WORK_TYPE, WORK_NUMBER, WORK_DATE is the same, update TABLE2.WORK_ID to just one work_id. For example, the first record for work_number 888877 in TABLE1 should have 5 pages in the TABLE2.PAGES column and the WORK_ID column be updated to 100 instead of 100 and 103 and so on.

TABLE2



Fatoumatta Barry


Suppress Warning Script Task

$
0
0

Hi,

After importing a salesforce (partner or enterprise) WSDL via web services I get the following warning:

"Custom tool warning: Schema validation error: Schema item 'simpleType' named 'FaultCode' from namespace 'urn:fault.partner.soap.com' is invalid. The Enumeration constraining facet is an undelcared prefix."

After spending a lot of time investigating if the WSDL is corrupted I have come to the conclusion, with help from several posts, that it is not and issue with the WSDL and the issue is actually a bug in VS.

Has anyone else out there come across this issue?

Some have suggested to ignore the warning, however I cannot find a way to suppress the warning at run time?

Cheers

Andy



Connection timing out - SqlClient Data Provider with ADO.NET Source

$
0
0

I have an ADO.NET source that is selecting from a view using a connection manager of type .Net Providers\SqlClient Data Provider.  I have set the timeout to 0 in the connection manager (which I understand to mean "do not timeout ever").

When I define the view as SELECT TOP 1000 it works fine and pretty quickly, goes through all transformations, and ends up in the destination table in the database with no issues.  If I define it as SELECT TOP 1000000 or remove the TOP clause it times out after 30 seconds.  The Test Connection button returns success immediately each time.  I don't get any rows to the point of my first transformation, so it's not an error in a transformation or the destination.

I thought that a timeout would not occur at all if the SELECT had started at all.  It looks like it's timing out because no records have been returned after 30 seconds.

So my two questions are 1 - is my thought directly above incorrect, and 2 - if I'm setting timeout to 0 why is it timing out after 30 seconds?

Thanks!

Problem with 'set_execution_parameter_value' and project parameter

$
0
0

Hi,

In my SSIS Package I'm using a Project Parameter of type string. I want to set this parameter from stored procedure by using "set_execution_parameter_value". Here is my code.

DECLARE @customerFilter sql_variant = 'N0000' 
EXEC [SSISDB].[catalog].[set_execution_parameter_value]
        @exec_id,
        @object_type = 20,
        @parameter_name=N'CustomerFilter',
        @parameter_value = @customerFilter

According technet article the parameter_value needs to be sql_variant. But if I do so I get error

Msg 27147, Level 16, State 1, Procedure check_data_type_value, Line 26 The data type of the input value is not compatible with the data type of the 'String'.

Same when I use varchar(8000)

DECLARE @customerFilter varchar(8000) = 'N0000' 

having troubles deploying SSIS packages to a named instance for SQL 2005

$
0
0

Hello,

I have  a user that is having trouble deploying a SSIS package to a named instance in SQL 2005.  After he deploys it, he doesn't see the package when he logs into SQL 2005

I added the named instance in the XML and restarted the sql service but to no effect.  Also, I am unable to find a guide/walkthrough on what to do when deploying SSIS packages to a named instance.

Comments would be greatly appreciated.

Thanks,

Move records - insert into destination and delete from source

$
0
0

In tsql I can use delete from...output into... where...

How can I do something similar with a dataflow task?

Table A > Table B

The tables are identical in structure.  One is used for "history"

I want to insert into Table B based on a condition, and then those same records should be deleted from Table A

Like all things SSIS, there is usually more than one way to do it.

Current approach Im thinking is:two dataflow tasks and use transactions

Is there another way?

I suppose I could use a sql task and use my sql statement I was using earlier.


ole db error

$
0
0

Hi I am still having issues with this OLE DB. I think I have it figured out BUT now once I have that fixed now I look at my mail merge and somehow between pulling it from excel into word it has added digits to one of my # fields. I have tried protecting the spreadsheet etc and nothing is working. Can anyone help me stop this!

Error Handling to send error row in another table

$
0
0

hi all

I need to do some error handling based on condition like.

I have one datafolw task

Source:Select top 10 email,id from customer

I can not use redirect option .(because I have one trigger at destination).

Now I need if any of row is not inserted at destination (Failed).

Then email address will insert in another table either based on Event handler and all.

I tried wiith Event handler with datafolw and onerror option but there is no luck

Please help me to do this task.

Thanks

Error Handling and Logging with Propagate as False in SSIS

$
0
0

Hi,

I'm using a Foreach Loop Container with different tasks included like like,XML task,Execute SQL Task,Script Task

Here the foreach container is used to flow through XML files in a folder.The requirement is that,even if i found any file corrupted,i just should log it and transfer the file to a FAILED folder and just continue the foreach with next file.

For that i have set the Propagate Property of ErrorHandler Event as False,which is letting me continue even at the case of error.But my logging and moving the corrupted files to Failed folder is not happening...

Please help with your valuable suggestions..


Erro while attempting to perform a type cast in derived column component

$
0
0

Hi

I'm trying to perform a DataType change of a column from DataType DT_STR to (DT_UI1).

The syntax i'm using is: (DT_UI1)LEFT(RIGHT(Section,3),1)

I'm getting the following error when i'm executing the package:

[Deviding Section Field [32]] Error: An error occurred while attempting to perform a type cast.

I'll be happy for assustance :)

thanks

Yaron


Yaron

what is diffrent between task and container?

$
0
0

Dear all,

mostly asking in interview question

i don't how to explain this question

please anybody can explain?

1.what is diffrent between task and container?

2.what is task?

what is Container?

if any body can help me?

thanks


SSIS Data Errors Handling

$
0
0

Hi ,

I have been creating a package for automating  few files from a selected location  ,the source files are generated with all different type of data as there is no or   minimal validation  at source,i have selected  a sample of files and profiled the data and based on the results i'm implimenting the data types using a derived transform   and at  the source adapter i'm not doing anytype of validation  as i want to make this process  a measured and controlled process for data  errors and the batch to be easy to handle.

To the redirected error rows  at derived column which does  type casting i have added  script componant to get error description  but the error description  is  same  as invalid expression for all errors ,when  I do the same at the source componanent error rows i'm getting  relevent error description.

I request  members who faced similar situation  to give there  thoughts  on this approach and any preventative measures which need to be taken for the whole process to be less error prone and easy to debug as i  have seen data  with out validation is an accident waiting to  happen  

Regards

CKumaran



Attempted to read or write protected memory error executing SSIS package..

$
0
0

Hello,

I'm getting the following error message intermittently when trying to execute SSIS packages. The SSIS packages are hosted on SQL server 2008,10.0.2531, X64 and 100GB f RAM and with more than 10GB available memory on the server.  The package is trying to transfer data from one server to other. The source server is SQL Server 2005,x64,SP3 and destination is SQL Server 2008,10.0.2531,x64.

when the restart the same SSIS package it works fine.  I do not see any access voilation/memory assertions on the server. I would like to understand and know the root cause of this error message.

any help highly appreciated..

ERROR :

Error: 2013-07-05 1:55:10.77

  Code: 0xC002F210
   Source: SQL - Get Source Logic Execute SQL Task 
   Description: Executing the query "EXECUTE Control.GetSourceLogic ?, ? OUTPUT;" failed with the following error: "Attempted to read or write protected memory. This is often an indication that other memory is corrupt.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
End Error
DTExec: The package execution returned DTSER_FAILURE (1).
Started:  9:53:19 PM
Finished: 9:55:28 PM
Elapsed:  128.608 seconds



Issue with excel file

$
0
0

Hi all,

I developed 2008 SSIS package to export data into multiple excel files(.xlsx) by following the below links

http://www.rafael-salas.com/2006/12/import-header-line-tables-into-dynamic_22.html

http://www.rafael-salas.com/2006/12/import-header-line-tables-_116683388696570741.html

Everything works fine. but I am not able to open Excel files that i've generated. I got an error like

Excel cannot open the file asd.xlsx because the file format or file extension is not valid. verify that the file has not been corrupted and that the file extension matches the format of the file

Here is the path in Excel connection manager:

\\abc\xyz\Files\test\a.xlsx

Can anyone please suggest how to solve this issue

Thanks,

Jyo

MS Excel 2013 Issues

$
0
0

Hi All,

My company will be upgrading to MS Office 2013 from MS Office 2007 in near future. I'm in process to test if this upgradation would cause any issue in

- SSIS package I create (using Excel as Source & destination) in SQL Server 2008.

- Using Cubes created in SQL Server 2008

- Any scripting Issue?

I'll be posting back about the issue I'll face in near future, but just wanted to know if there are any known issues??

Thanks,


madhur_ms

DELECT with Rowlock and SELECT with nolock contention casuing deadlock

$
0
0

Hi,

Deleting with Rowlock and Selecting with nolock on same table with multiple processes at same time causing the deadlock.

Business Need:  Multiple tables have millions of records sitting on live database and causing the performance. So we are planning to move the (10 yrs old) records to archive database first then delete from live database. For this we wrote move procedure and delete procedure.

We made a SSIS package to move and delete records and planning to do this, move/delete with multiple processes (by keeping  multiple  tasks in container) this is leading deadlock.

Any help will be appreciated.

thanks,

 

having bold text in message body using send email task

$
0
0

I have an email which I need to send to multiple users using SSIS send mail task and the content of the body contains both variables and standard text. I would like to make some of the standard text bold - could someone possibly advise of the simplest way to accomplish this ?

many thanks

How to increase the parallel tasks on target server based on its hardware in SSIS

$
0
0

Hi,

I created the SSIS package with sequential container by placing 10 execute sql tasks in it. There is no connection for these execute sql tasks to achieve parallel execution and I set the maxconcurrentexecutable to 10.

With above settings package is doing its task parallel without any problem. we are planning to deploy on customer server which has rich hardware. Now  my question is,

how should I make sure that rich hardware can be used fully to execute my package. I mean,

1) if customer server, supports 20 concurrent processes, how should I keep 20 executable sql task in my package dynamically?

2) if customer server, support only 5 concurrent process, how should I keep only 5 executable sql tasks in my package dynamically?

3) I want, the number of maxconcurrentexecutable should be configurable, and those many executables needs to run parallel in my package?

thanks

Viewing all 24688 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>