Click here to Skip to main content
15,899,679 members
Home / Discussions / Database
   

Database

 
AnswerRe: Data Base administrator vs software developer Pin
PIEBALDconsult2-Jun-13 9:48
mvePIEBALDconsult2-Jun-13 9:48 
AnswerRe: Data Base administrator vs software developer Pin
Mycroft Holmes2-Jun-13 11:16
professionalMycroft Holmes2-Jun-13 11:16 
AnswerRe: Data Base administrator vs software developer Pin
Richard MacCutchan2-Jun-13 20:56
mveRichard MacCutchan2-Jun-13 20:56 
GeneralRe: Data Base administrator vs software developer Pin
saurabhspk4-Jul-13 9:57
saurabhspk4-Jul-13 9:57 
GeneralRe: Data Base administrator vs software developer Pin
Richard MacCutchan4-Jul-13 20:49
mveRichard MacCutchan4-Jul-13 20:49 
AnswerRe: Data Base administrator vs software developer Pin
Bernhard Hiller2-Jun-13 22:47
Bernhard Hiller2-Jun-13 22:47 
AnswerRe: Data Base administrator vs software developer Pin
jschell3-Jun-13 9:07
jschell3-Jun-13 9:07 
GeneralRe: Data Base administrator vs software developer Pin
SudhirKankal4-Jun-13 23:56
SudhirKankal4-Jun-13 23:56 
AnswerRe: Data Base administrator vs software developer Pin
Saranya-from-Tamil-Nadu-India6-Jun-13 23:58
Saranya-from-Tamil-Nadu-India6-Jun-13 23:58 
QuestionInserting Master and DEtail Tables Pin
indian14331-May-13 14:53
indian14331-May-13 14:53 
AnswerRe: Inserting Master and DEtail Tables Pin
Mycroft Holmes1-Jun-13 2:35
professionalMycroft Holmes1-Jun-13 2:35 
GeneralRe: Inserting Master and DEtail Tables Pin
indian1431-Jun-13 17:38
indian1431-Jun-13 17:38 
GeneralRe: Inserting Master and DEtail Tables Pin
Mycroft Holmes1-Jun-13 17:59
professionalMycroft Holmes1-Jun-13 17:59 
GeneralRe: Inserting Master and DEtail Tables Pin
indian1432-Jun-13 12:18
indian1432-Jun-13 12:18 
GeneralRe: Inserting Master and DEtail Tables Pin
Mycroft Holmes2-Jun-13 12:35
professionalMycroft Holmes2-Jun-13 12:35 
GeneralRe: Inserting Master and DEtail Tables Pin
indian1432-Jun-13 13:54
indian1432-Jun-13 13:54 
GeneralRe: Inserting Master and DEtail Tables Pin
Mycroft Holmes2-Jun-13 14:29
professionalMycroft Holmes2-Jun-13 14:29 
GeneralRe: Inserting Master and DEtail Tables Pin
indian1432-Jun-13 19:15
indian1432-Jun-13 19:15 
GeneralRe: Inserting Master and DEtail Tables Pin
Mycroft Holmes2-Jun-13 20:02
professionalMycroft Holmes2-Jun-13 20:02 
GeneralRe: Inserting Master and DEtail Tables Pin
indian1433-Jun-13 7:12
indian1433-Jun-13 7:12 
GeneralRe: Inserting Master and DEtail Tables Pin
indian14311-Jun-13 7:59
indian14311-Jun-13 7:59 
GeneralRe: Inserting Master and DEtail Tables Pin
Ralph D. Wilson II10-Jul-13 9:42
Ralph D. Wilson II10-Jul-13 9:42 
Abdul,

My questions here are:
1. Can I write logic in SSIS to update if the record already exists and certains columns are same, if so how can I do that.
2. If I incorporate logic into SSIS, can the performance be same as simple import process. Because the simple import process in SSIS uses the bulk insert mechanism with batch inserts of records.



The answer to your question isn't as simple as you may think. In the first place, your use of the phrase "can I" adds to the problem because it seems that you are very much an SSIS novice. so let me approach this in anothe way.

1. An SSIS package can be created that would handle your problem. The trick is to use the MERGE statement that is available in T-SQL. You can also use a pair of SQL statements such as those that you provided in your most recent post. Howver, your SQL code may be impacting our performance somewhat because you are using the IN (SELECT....) instead of using the INNER JOIN approach to determining which rows to update.

2. A straight forward bulk load is always going to be the fastest choice; however, since you need to UPDATE some rows and INSERT others, that option isn't available to you,so there's no point in worrying about that. Wink | ;-)

That being said, though, if this is your first SSIS package, I would suggest that you create a temp table into which you the INSERT both updated versions of the existing rows and then the new rows (with the IDENTITY INSERT ON, so that you can keep the IDs of the existing rows), and then truncate the existing table and reload it from the temp table. Wink | ;-)
Questionquery error Pin
Bhairava Prasad30-May-13 2:03
Bhairava Prasad30-May-13 2:03 
AnswerRe: query error Pin
Anurag Sinha V30-May-13 2:25
Anurag Sinha V30-May-13 2:25 
AnswerRe: query error Pin
Mycroft Holmes30-May-13 12:03
professionalMycroft Holmes30-May-13 12:03 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.