SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


How to restrict to stop the package if one of the excel tab gives error


How to restrict to stop the package if one of the excel tab gives error

Author
Message
sqlstud
sqlstud
SSC-Enthusiastic
SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)

Group: General Forum Members
Points: 171 Visits: 237
Hi,

I have developed a SSIS package.

Source : XLSX File

Destination : SQL Server Table

The XLSX files contains 4 tabs. I am loading 4 tabs into 4 different tables by creating 4 data flows.

Steps:

inside For each loop container

1. Used Script Component

i have checked whether the given file is valid or not. if valid, it executes the step 2. if not valid, it send out an email

2. Used 4 Dataflows one for each tab. All are independent data flows

please find the strucure attached:




Ques:

If any one of the tabs get failed, it should not load the other three tabs.

Please advise how to proceed.


Regards

SqlStud
Attachments
error_Tabs.jpg (8 views, 33.00 KB)
Koen Verbeeck
Koen Verbeeck
One Orange Chip
One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)

Group: General Forum Members
Points: 27735 Visits: 13268
Enable transactions in your SSIS package. You can either use the built-in transaction mechanism which uses MSDTC, or you can create your own transaction by putting a SQL Task with "BEGIN TRANSACTION" at the start of your package and a SQL Task with "COMMIT" at the end of the package. Make sure you set RetainSameConnection to true for the connection manager.


How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?
My blog at SQLKover.

MCSE Business Intelligence - Microsoft Data Platform MVP
sqlstud
sqlstud
SSC-Enthusiastic
SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)

Group: General Forum Members
Points: 171 Visits: 237
Koen Verbeeck (12/20/2012)
Enable transactions in your SSIS package. You can either use the built-in transaction mechanism which uses MSDTC, or you can create your own transaction by putting a SQL Task with "BEGIN TRANSACTION" at the start of your package and a SQL Task with "COMMIT" at the end of the package. Make sure you set RetainSameConnection to true for the connection manager.


Thanks MCSA.

Can you please let me know how to do it?

Regards
SqlStud
rhythm.varshney
rhythm.varshney
SSC-Enthusiastic
SSC-Enthusiastic (140 reputation)SSC-Enthusiastic (140 reputation)SSC-Enthusiastic (140 reputation)SSC-Enthusiastic (140 reputation)SSC-Enthusiastic (140 reputation)SSC-Enthusiastic (140 reputation)SSC-Enthusiastic (140 reputation)SSC-Enthusiastic (140 reputation)

Group: General Forum Members
Points: 140 Visits: 195
sqlstud (12/20/2012)
Koen Verbeeck (12/20/2012)
Enable transactions in your SSIS package. You can either use the built-in transaction mechanism which uses MSDTC, or you can create your own transaction by putting a SQL Task with "BEGIN TRANSACTION" at the start of your package and a SQL Task with "COMMIT" at the end of the package. Make sure you set RetainSameConnection to true for the connection manager.


Thanks MCSA.

Can you please let me know how to do it?

Regards
SqlStud


One way of mainitaining explicit transaction Koen has already mentioned by putting Exec SQL Task.
For the first one please refer below URL

http://technet.microsoft.com/en-us/library/cc304421.aspx
sqlstud
sqlstud
SSC-Enthusiastic
SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)

Group: General Forum Members
Points: 171 Visits: 237
rhythm.varshney (12/20/2012)
sqlstud (12/20/2012)
Koen Verbeeck (12/20/2012)
Enable transactions in your SSIS package. You can either use the built-in transaction mechanism which uses MSDTC, or you can create your own transaction by putting a SQL Task with "BEGIN TRANSACTION" at the start of your package and a SQL Task with "COMMIT" at the end of the package. Make sure you set RetainSameConnection to true for the connection manager.


Thanks MCSA.

Can you please let me know how to do it?

Regards
SqlStud


One way of mainitaining explicit transaction Koen has already mentioned by putting Exec SQL Task.
For the first one please refer below URL

http://technet.microsoft.com/en-us/library/cc304421.aspx


Thanks....

But it didnt solved the problem.

it given the error as "
[Connection manager "src"] Error: The connection does not support enlisting in distributed transaction. "
Error: SSIS Error Code DTS_E_CANNOTACQUIRECONNECTIONFROMCONNECTIONMANAGER. The AcquireConnection method call to the connection manager "Src" failed with error code 0xC0202009. There may be error messages posted before this with more information on why the AcquireConnection method call failed.

Regards
SqlStud
Koen Verbeeck
Koen Verbeeck
One Orange Chip
One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)

Group: General Forum Members
Points: 27735 Visits: 13268
My guess is MSDTC isn't running.

You can always try with the Execute SQL Tasks as I mentioned earlier.


How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?
My blog at SQLKover.

MCSE Business Intelligence - Microsoft Data Platform MVP
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search