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

EXCEL TO SQL USING SSIS Error

$
0
0

I have an .XLSLX File.  I have a DFD Task to export that xlsx file into SQL. I use SSIS 2008. However when I run the package, it fails with this error below.

[Connection manager "Excel Connection Manager"] Error: SSIS Error Code DTS_E_OLEDB_EXCEL_NOT_SUPPORTED: The Excel Connection Manager is not supported in the 64-bit version of SSIS, as no OLE DB provider is available.


script component read data flow component properties.

$
0
0

I have an OLEDB Source component on my Data Flow.

I would like to read the value of the chosen OpenRowSet property from a script component.

I am using C#.

Is this possible?


Mr Shaw

Project Deployment

$
0
0

Hi !

I have developed a package in project deployment mode and i'm able to run the package without any issues in windows environment from Dev server.

I'm deploying to Integration services catalog and executing a package by right clicking  from there. I'm just getting the package status as failure and no error messages.

Can you please help me ? where can i see error mesage when i run froom Integeration servcie catalog...


Regards,



how we can create the batch file to download the data in from URL in ssis

$
0
0

hi,

any one help on one the below requirement.

i have to create one batch file to download the report(reports is in csv format) from URL...

requirement should be like this...

1. we have some reports is there in the URL..

2.when ever we execute the url, the report should be download and save it to the local folder.

3. this requirement i have to write in the batch file

should any one let me know how we can create the batch file for the above requirement.

why not download SQLSever from DranmSpark?

Error in SSIS Script Component

$
0
0

Development environment : SQL Server Business Intelligence  Development Studio 2008

I have developed SSIS package to insert/update records to production Database. In this case I'm using  a Script component to call a Stored Procedure to do the data access. I putted a User defined variable intoReadOnlyVariables container. When execute the package I got the following error.

ERROR:

Unable to cast COM object of type 'System.__ComObject' to interface type 'Microsoft.SqlServer.Dts.Runtime.Wrapper.IDTSVariables100'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{22992C1D-393D-48FB-9A9F-4E4C62441CCA}' failed due to the following error: The application called an interface that was marshalled for a different thread. (Exception from HRESULT: 0x8001010E (RPC_E_WRONG_THREAD)).

at Microsoft.SqlServer.Dts.Runtime.Wrapper.IDTSVariables100.Unlock()
at Microsoft.SqlServer.Dts.Pipeline.ScriptComponent.UnlockReadOnlyVariables()
at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.PostExecute()

Appreciate if any assistance regarding this!

Kind Regards, 

How to make Flat File's "Column Delimiter" Dynamic

$
0
0

Hi Friends

I have a OLE DB Source which loads data into a Flat File. Now I want to make my Flat File's "Column Delimiter"  Dynamic. Will it be possible? because in package configuration we can config "Row Delimiter" but there is no option to config "Column Delimiter".

".


Royal Thomas

SSIS configuration

$
0
0

I am new to SSIS.  I need to send over some connection String configurations to my DBA in order to get a package in production.

When I look at our SSIS Configuration table the configured value looks something like this for some of the packages

Data Source=S000-SERVER;Initial Catalog=SERVER_Custom_SL;Provider=SQLNCLI10.1;Integrated Security=SSPI;Application Name=SSIS-PACKAGE-{3330B93F-2332-46CB-856A-FAFA9FC7EA2E}S000-SERVER.SERVER_Custom_SL;Auto Translate=False;

The part that I don't understand is the Application Name and the series of numbers after it.  When I use the Wizard in Visual Studio it sends over all of the information except the highlighted area.  What is this used for and is it essential that I put it in my insert statement for the ssis configuration table (I cannot write directly to the production table).  I have tried a internet search but have not been able to understand this piece.

Thanks for your explanation.


RockyKatz


Remove content in the middle of a column

$
0
0

I am attempting to pull out some data that is in a column. The column looks like this

First seen: Tuesday, 18 Feb 2014 06:14:00<br>Status: START<br>Location: 2

First seen: Tuesday, 18 Feb 2014 06:14:00<br>Status: STOP<br>Location: 2

I need to get the Status value out of this for it to look like

START

STOP

I am having trouble writing an SSIS expression for this.

Can someone help me out please?

I am using SSIS 2008

how to move SSIS packges and its connection automatically on mirrored server

$
0
0

Hi I have setup mirroring on DB sql server 2012, somehow not using alwayson feature.

so in that case we have to make a plan by which way we can move ALL the ssis packages and changed it connection point.

like whereever ssis using serverA it can be chnaged to serverB without opening each and every package.

Microsoft Connector 1.1 to Connect to SAP BW via SSIS

$
0
0

I have downloaded and installed Microsoft Connector 1.1 and created a new SSIS project.  Within the project I have defined the connection to BW 7.3 using the SAPBI connection in connection manager and also an OLE  DB Destination connection to my SQL 2008 database.  I can connect to BW with no issue.  I can see the columns and map them appropriately.  The I run the package, I receive the following error.  I have researched this issue all over the internet and thus far I have found nothing that tells me specifically how to correct this error.

SSIS package "SAPBI.dtsx" starting.
Information: 0x4004300A at Data Flow Task, SSIS.Pipeline: Validation phase is beginning.
Information: 0x4004300A at Data Flow Task, SSIS.Pipeline: Validation phase is beginning.
Warning: 0x80049304 at Data Flow Task, SSIS.Pipeline: Warning: Could not open global shared memory to communicate with performance DLL; data flow performance counters are not available.  To resolve, run this package as an administrator, or on the system's console.
Warning: 0x80047076 at Data Flow Task, SSIS.Pipeline: The output column "OHREQUID" (20) on output "SAP BW Source Output" (4) and component "SAP BW Source" (1) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance.
Warning: 0x80047076 at Data Flow Task, SSIS.Pipeline: The output column "DATAPAKID" (23) on output "SAP BW Source Output" (4) and component "SAP BW Source" (1) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance.
Warning: 0x80047076 at Data Flow Task, SSIS.Pipeline: The output column "RECORD" (26) on output "SAP BW Source Output" (4) and component "SAP BW Source" (1) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance.
Information: 0x40043006 at Data Flow Task, SSIS.Pipeline: Prepare for Execute phase is beginning.
Information: 0x40043007 at Data Flow Task, SSIS.Pipeline: Pre-Execute phase is beginning.
Information: 0x4004300C at Data Flow Task, SSIS.Pipeline: Execute phase is beginning.
Information: 0x3E8 at Data Flow Task, SAP BW Source: Process Start Process, variant Start has status Completed (instance DH2NXQB8RR7E2ZTZH07M3AX7H)
Error: 0x3E8 at Data Flow Task, SAP BW Source: Process Data Transfer Process, variant P1CUST -> ZCUSTOH has status Ended with errors (instance DTPR_00O2TMRWI0AOQHQSUFRAW08X0)
Error: 0x3E8 at Data Flow Task, SAP BW Source: An internal exception occurred.
Microsoft.SqlServer.Dts.SapBw.Connectivity.ERPException: An error occurred during the dispatch of the incoming function. The last return code was "RFC_FAILURE".
Error: 0x3E8 at Data Flow Task, SAP BW Source: The component is stopping because the Request ID is "0".
Error: 0x3E8 at Data Flow Task, SAP BW Source: No data was received.
Error: 0xC0047062 at Data Flow Task, SAP BW Source [1]: System.Exception: No data was received.
   at Microsoft.SqlServer.Dts.SapBw.Components.SapBwPipelineComponent.FireErrorAndException(String message)
   at Microsoft.SqlServer.Dts.SapBw.Components.SapBwSourceOHS.PrimeOutput(Int32 outputs, Int32[] outputIDs, PipelineBuffer[] buffers)
   at Microsoft.SqlServer.Dts.Pipeline.ManagedComponentHost.HostPrimeOutput(IDTSManagedComponentWrapper100 wrapper, Int32 outputs, Int32[] outputIDs, IDTSBuffer100[] buffers, IntPtr ppBufferWirePacket)
Error: 0xC0047038 at Data Flow Task, SSIS.Pipeline: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED.  The PrimeOutput method on component "SAP BW Source" (1) returned error code 0x80131500.  The component returned a failure code when the pipeline engine called PrimeOutput(). The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing.  There may be error messages posted before this with more information about the failure.
Information: 0x40043008 at Data Flow Task, SSIS.Pipeline: Post Execute phase is beginning.
Information: 0x4004300B at Data Flow Task, SSIS.Pipeline: "component "OLE DB Destination" (49)" wrote 0 rows.
Information: 0x40043009 at Data Flow Task, SSIS.Pipeline: Cleanup phase is beginning.
Task failed: Data Flow Task
Warning: 0x80019002 at SAPBI: SSIS Warning Code DTS_W_MAXIMUMERRORCOUNTREACHED.  The Execution method succeeded, but the number of errors raised (6) reached the maximum allowed (1); resulting in failure. This occurs when the number of errors reaches the number specified in MaximumErrorCount. Change the MaximumErrorCount or fix the errors.
SSIS package "SAPBI.dtsx" finished: Failure.

On the BW side it mentions a setting parameters for a 3RD Party API, but we are unsure of what values to set.    Any help you can provide will be greatly appreciated.  We have followed all the steps in the following article:

http://technet.microsoft.com/en-us/library/dd299430%28v=sql.100%29.aspx


Understanding a package executing through batch file

$
0
0

Hi Team,

I am trying to understanding one of the package which is development by some other person.

There is a database connection nothing assigned in properties of the connection it is just a hard-coded connection but there are variables for data source, initial catalog... i am not sure how this is working.

This is batch file script:

"C:\Program Files\Microsoft SQL Server\90\DTS\Binn\DTExec.exe" /file "C:\Test\Testing.dtsx" /set \package.variables[SQL_DATA_SOURCE].Value;"Testing" /set \package.variables[SQL_INITIAL_CATALOG].Value;"DB_Conn" /set \package.variables[DEBTPDS].Value;"C:\Test\TestingFolder" /set \package.variables[LOGPATH].Value;"C:\Test\LOGFILE.TXT" /set \package.variables[SYSPATH].Value;"C:\Test\SYSFILE.TXT" /set \package.variables[SQL_USER_ID].Value;"sa" /set \package.variables[SQL_PASSWORD].Value;"Password@123" /De test > OUTPUT.TXT

i like to know what this batch script is doing, how the variable values are passed.

There is a script task where the variables are used

'Variables being set externally
        Dim ylogFilePathParamName As String = "LOGPATH"
        Dim ystsFilePathParamName As String = "SYSPATH"
        Dim batchHomeParamName As String = "DEBTPDS"
        Dim sqlDataSourceParamName As String = "SQL_DATA_SOURCE"
        Dim sqlInitialCatalogParamName As String = "SQL_INITIAL_CATALOG"
        Dim sqlUserIdParamName As String = "SQL_USER_ID"
        Dim sqlPwdParamName As String = "SQL_PASSWORD"

        'Connection string Details
        Dim sqlConFmtStr As String

sqlConn = "Data Source={0};Initial Catalog={1};Provider=SQLNCLI.1;Integrated Security=SSPI;User Id= {2};Password={3};Auto Translate=False;"
        dataSource = Dts.Variables(sqlDataSourceParamName).Value.ToString()
        catalog = Dts.Variables(sqlInitialCatalogParamName).Value.ToString()
        userId = Dts.Variables(sqlUserIdParamName).Value.ToString()
        password = Dts.Variables(sqlPwdParamName).Value.ToString()
        Dts.Connections(dataSourceName).ConnectionString = String.Format(sqlConFmtStr, dataSource, catalog, userId, password)

Thanks,

Eshwar.


Please don't forget to Marked as Answer if my post solved your problem and use Vote As Helpful if a post was useful. It will helpful to other users.


Sql Server 2012 Job on 64 Bit Environment fails to find 32 Bit ODBC connection when executing SSIS 32 Bit package .

$
0
0

Hi All,

My SSIS 2012 (64bit, Windows 64 bit ) package runs fine from BIDS . It is a SSIS Import / Export package that pics data from old Mainframes Server into Sql Server . I am using a 32 Bit ODBC to connect to Mainframes .

Howeever when i try to run the same package as a Sql Server Agent JOB it fails with message :

Data Flow Task 1:Error: ADO NET Source has failed to acquire the connection {010532E9-BC30-42BD-8A7E-D9E2E7412989} with the following error message: "ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified".

I have read the various blogs on this and have already to deploy the package after setting "Run64BitRunTime" = "False".

I changed the Sql Server Agen Job Advance Setting Property to "32-bit machine" . Job Step Type is "Sql Server Integration Services Package" It runs as "Sql Server Agent Account"

Still no success .

Any pointers ?

Thanks


shuchi


SCD task and Sequence generator (Next Value) dependancy

$
0
0

We have Sequence generator (Next Value) enabled for surrogate keys (SQL Server 2012). When we use the new SCD task, we get the following error:

[Insert Destination [42]] Error: SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x80004005.

An OLE DB record is available.  Source: "Microsoft SQL Server Native Client 11.0"  Hresult: 0x80004005  Description: "NEXT VALUE FOR function cannot be used if ROWCOUNT option has been set, or the query contains TOP or OFFSET. ".

Is there any know issue that these two features [SCD task and Next Value] cannot be used together?


Bose

Mysql query changes when I execute it from ssis

$
0
0

Hi All !

I have a simple MySql Select Query with a filter on column updated_at (datetime). when I execute my query directly on HEIDI SQL I got 33 lignes. BUT when I put it in Expression for SQLCommande in my Package (so that I can use a Variable in my Filter) the query retrives All data from source Table (99 000 lines)...

any ideas please ?

Thanks


Multicast Lookup No Match output

$
0
0

I have a requirement where I have to send email if the new record found from lookup and add that new record in the table as well.

I'm not sure how to send the email under dataflow task. I know we can do that under control flow task.

For example: source has 11 records and the target has 10, after lookup we got 1 new record. I need to send this record (id, code column from the table) through an email and insert that in the target too. 

Thanks in advance.

 

ZK

Passing same GUID to table in ssis

$
0
0

Hi,

I have 2 flat file A,B which loads data into table and contain 2 columns Id and Name. My table contain 3 columns GUID,Id and name respectively. Consider my flat file A has 2 records in it.

My requirement is like this----

When I will load data from the flat file A, I need to insert value for GUID. The value of GUID will remain same for these 2 records.

Now My flat file B has 3 records, So when I load these 3 records in table, I should have same GUID for these 3 record but this GUID should be different from the one which we have loaded for file A.

So after loading files A and B. My table will look like below.

GUID     ID     Name

Guid1     1     AB

Guid1     2     CD

Guid2     3     EF

Guid2     4     FG

Guid2     5     FR

How to achieve this using SSIS package.

Thanks You.


Adding Teradata source component programmatically in SSIS

$
0
0
Need help to add a Teradata source component programmatically in SSIS . I am able to add the component but the column info and other metadata is not available for subsequent components. Any documentations or suggestion is needed .

Need To Create a table in Sql Server and do some culculation into the table from Oracle and Sql

$
0
0

Hello All,

I'm moving a data from Oracle to Sql Server with ETL (80 tables with data) and i want to track the number of records that i moving on the daily basis , so i need to create a table in SQL Server, wilth 4 columns , Table name, OracleRowsCount, SqlRowCount, and Diff(OracleRowsCount - SqlRowCount) that will tell me the each table how many rows i have in Oracle, how many rows i have in SQL after ETL load, and different between them, something like that:

Table Name  OracleRowsCount   SqlRowCount  Diff

Customer                150                 150             0

Sales                      2000                1998           2

Devisions                 5                       5              0

(I can add alot of SQL Tasks and variables per each table but it not seems logicly to do that, i tryid to find a way to deal with that in vb but i didn't find)

What the simplest way to do it ?

Thank you

Best Regards

Daniel

how to move data from a staging table to three entity tables

$
0
0

Environment: win7, SQL Server 2008 R2
Application: Microsoft SQL Management  Studio 2008 R2, Business Intelligence 2008 - SSIS
SSIS competency level: Novice

ETL Process ( it works fine - no issues): The following flowcharts illustrate basic ETL process, where the data is being transformed to a staging table [destination table]. The staging table consist of the following fields

(id, ssn, Fname, Lname, Subject_cd, Test_dt, Score, comments, ind_response)



After running ETL package in SSIS, the data were loaded to the Staging table (destination table)The following code shows the data being created in the staging table to use it later for another data transaction

Code:

CREATE TABLE Staging_Table (
	id CHAR(9)
	,ssn  CHAR(9) NOT NULL
	,Fname VARCHAR(50) NOT NULL
	,Lname VARCHAR(50) NOT NULL
	,Subject_cd char (2)
	,Test_dt   datetime 
	,Score char(2), comments nvarchar(250),ind_response nvarchar(250)
	);

INSERT INTO Staging_Table (
	id
	,ssn
	,Fname
	,Lname
	,Test_dt
	,Score
	,Subject_cd, comments ,ind_response 
	)
VALUES (
	'123456781','123549874'
	,'Sally', 'Johnson','20111125',
	'3','QB', 'N/A', '1243212221144121321411123332411121'
	);

INSERT INTO Staging_Table (
	id
	,ssn
	,Fname
	,Lname
	,Test_dt
	,Subject_cd
	,Score,comments ,ind_response 
	)
VALUES (
	'123456792','003549874'
	,'Will', 'Smith','20101025',
	'AD','3','Test was good','1231121223334121334121412'
	);


INSERT INTO Staging_Table (
	id
	,ssn
	,Fname
	,Lname
	,Test_dt
	,Score
	,Subject_cd, comments ,ind_response 
	)
VALUES (
	'120056783','993549800'
	,'William', 'Wahab','20090110',
	'1', 'FR','no comments', '111111111111222224121312144412' 
	);


INSERT INTO Staging_Table (
	id
	,ssn
	,Fname
	,Lname
	,Test_dt
	,Score
	,Subject_cd
	)
VALUES (
	'213450081','128749890'
	,'Douglas', 'Mike','20140214',
	'+2','CH'
	);


Requirement: Automate ETL process or data transaction and to schedule time to load the data in a monthly basis. Are any prerequisite to perform this task such enable certain system stored procedures. I want to eliminate manual work.  

Problem: How to load staging_table data into three entity tables, while there is referential integrity data constraints.

  1. If matched: Check whether SSN exists in the SSN table. Insert the records (id, Subject_cd, Score, test_dt,comments, ind_response) in the  [ind_subject_scores].
  2. If not matched: Insert the records to the following tables: SSN, Individual, then [ind_subject_scores].
  3. If matched in the [ind_subject_scores] then update the additional elements (comments, ind_response) in the table

Table #1:Parent

CREATE TABLE SSN (
	id CHAR(9)
	,ssn  CHAR(9) NOT NULL
	CONSTRAINT [FK_individual] FOREIGN KEY([id])
REFERENCES [individual] ([id])
	);

INSERT INTO ssn (
	id
	,ssn
	)
VALUES (
	'12001212','993549800'
		);


Table #2: child

CREATE TABLE individual 
( id CHAR(9) NOT NULL ,
Fname VARCHAR(50) NOT NULL 
,Lname VARCHAR(50) NOT NULL
, email VARCHAR(50) NULL ) 

INSERT INTO individual 
( id ,Fname ,Lname, email ) 
VALUES ( '12001212','William', 'Wahab', 'fake@yahoo.com' );	
Table #3.a
CREATE TABLE [dbo].[ind_subject_scores](
	[ind_scr_id] [int] IDENTITY(1,1) NOT NULL,
	[id] [char](9) NULL,
	[subject_cd] [char](2) NULL,
	[score] [varchar](2) NULL,
	[test_dt] datetime  
	)

INSERT INTO [dbo].[ind_subject_scores] (
	id
	,Test_dt
	,Score
	,Subject_cd
	)
VALUES (
	897841239, '20110101'
	,'2'
	,'FR'
	);


INSERT INTO [dbo].[ind_subject_scores] (
	id
	,Test_dt
	,Score
	,Subject_cd
	)
VALUES (
	80041239, '20110115'
	,'2'
	,'CH'
	);

Table #3.b - Insert new additional elements which was requested later. These data can be updated from the staging table if matched occurred

ALTER Table [dbo].[ind_subject_scores] add [comments] [nvarchar](250) NULL

ALTER Table dbo.ind_subject_scores add [ind_response] [nvarchar](250) NULL










Viewing all 24688 articles
Browse latest View live


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