You are on page 1of 12

These are the questions that i might ask: 1) What is the control flow 2) what is a data flow 3) how

do you do error handling in SSIS 4) how do you do logging in ssis ) how do you de!loy ssis !ackages" #) how do you schedule ssis !ackages to run on the fly $) how do you run stored !rocedure and get data %) gi&e a scenario: Want to insert a tect file into data'ase ta'le( 'ut during the u!load want to change a column called as months ) *anuary( +e'( etc to a code( ) 1(2(3"" "This code can 'e read from another data'ase ta'le called months" ,fter the con&ersion of the data ( u!load the file" If there are any errors( write to error ta'le" Then for all errors( read errors from data'ase( create a file( and mail it to the su!er&isor" -ow would you accom!lish this task in SSIS. /)what are &aria'les and what is &aria'le sco!e .
,nswers +or 0 1 and 2: In SSIS a workflow is called a control)flow" , control)flow links together our modular data)flows as a series of o!erations in order to achie&e a desired result" , control flow consists of one or more tasks and containers that e1ecute when the !ackage runs" To control order or define the conditions for running the ne1t task or container in the !ackage control flow( you use !recedence constraints to connect the tasks and containers in a !ackage" , su'set of tasks and containers can also 'e grou!ed and run re!eatedly as a unit within the !ackage control flow" S02 Ser&er 233 Integration Ser&ices 4SSIS) !ro&ides three different ty!es of control flow elements: containers that !ro&ide structures in !ackages( tasks that !ro&ide functionality( and !recedence constraints that connect the e1ecuta'les( containers( and tasks into an ordered control flow" , data flow consists of the sources and destinations that e1tract and load data( the transformations that modify and e1tend data( and the !aths that link sources( transformations( and destinations" 5efore you can add a data flow to a !ackage( the !ackage control flow must include a 6ata +low task" The 6ata +low task is the e1ecuta'le within the SSIS !ackage that creates( orders( and runs the data flow" , se!arate instance of the data flow engine is o!ened for each 6ata +low task in a !ackage" S02 Ser&er 233 Integration Ser&ices 4SSIS) !ro&ides three different ty!es of data flow com!onents: sources( transformations( and destinations" Sources e1tract data from data stores such as ta'les and &iews in relational data'ases( files( and ,nalysis Ser&ices data'ases" Transformations modify( summari7e( and clean data" 6estinations load data into data stores or create in)memory datasets" 03: When a data flow com!onent a!!lies a transformation to column data( e1tracts data from sources( or loads data into destinations( errors can occur" 8rrors frequently occur 'ecause of une1!ected data &alues" +or e1am!le( a data con&ersion fails 'ecause a column contains a string instead of a num'er( an insertion into a data'ase column fails 'ecause the data is a date and the column has a numeric data ty!e( or an e1!ression fails to e&aluate 'ecause a column &alue is 7ero( resulting in a mathematical o!eration that is not &alid" 8rrors ty!ically fall into one the following categories: )6ata con&ersion errors( which occur if a con&ersion results in loss of significant digits( the loss of insignificant digits( and the truncation of strings" 6ata con&ersion errors also occur if the requested con&ersion is not su!!orted" )81!ression e&aluation errors( which occur if e1!ressions that are e&aluated at run time !erform in&alid o!erations or 'ecome syntactically incorrect 'ecause of missing or incorrect data &alues" )2ooku! errors( which occur if a looku! o!eration fails to locate a match in the looku! ta'le"

9any data flow com!onents su!!ort error out!uts( which let you control how the com!onent handles row)le&el errors in 'oth incoming and outgoing data" :ou s!ecify how the com!onent 'eha&es when truncation or an error occurs 'y setting o!tions on indi&idual columns in the in!ut or out!ut" +or e1am!le( you can s!ecify that the com!onent should fail if customer name data is truncated( 'ut ignore errors on another column that contains less im!ortant data" 0 4: SSIS includes logging features that write log entries when run)time e&ents occur and can also write custom messages" Integration Ser&ices su!!orts a di&erse set of log !ro&iders( and gi&es you the a'ility to create custom log !ro&iders" The Integration Ser&ices log !ro&iders can write log entries to te1t files( S02 Ser&er ;rofiler( S02 Ser&er( Windows 8&ent 2og( or <92 files" 2ogs are associated with !ackages and are configured at the !ackage le&el" 8ach task or container in a !ackage can log information to any !ackage log" The tasks and containers in a !ackage can 'e ena'led for logging e&en if the !ackage itself is not" To customi7e the logging of an e&ent or custom message( Integration Ser&ices !ro&ides a schema of commonly logged information to include in log entries" The Integration Ser&ices log schema defines the information that you can log" :ou can select elements from the log schema for each log entry" To ena'le logging in a !ackage 1" In 5usiness Intelligence 6e&elo!ment Studio( o!en the Integration Ser&ices !ro=ect that contains the !ackage you want" 2" >n the SSIS menu( click 2ogging" 3" Select a log !ro&ider in the ;ro&ider ty!e list( and then click ,dd" 0 : S02 Ser&er 233 Integration Ser&ices 4SSIS) makes it sim!le to de!loy !ackages to any com!uter" There are two ste!s in the !ackage de!loyment !rocess: )The first ste! is to 'uild the Integration Ser&ices !ro=ect to create a !ackage de!loyment utility" )The second ste! is to co!y the de!loyment folder that was created when you 'uilt the Integration Ser&ices !ro=ect to the target com!uter( and then run the ;ackage Installation Wi7ard to install the !ackages" 0/: ?aria'les store &alues that a SSIS !ackage and its containers( tasks( and e&ent handlers can use at run time" The scri!ts in the Scri!t task and the Scri!t com!onent can also use &aria'les" The !recedence constraints that sequence tasks and containers into a workflow can use &aria'les when their constraint definitions include e1!ressions" Integration Ser&ices su!!orts two ty!es of &aria'les: user)defined &aria'les and system &aria'les" @ser)defined &aria'les are defined 'y !ackage de&elo!ers( and system &aria'les are defined 'y Integration Ser&ices" :ou can create as many user)defined &aria'les as a !ackage requires( 'ut you cannot create additional system &aria'les" Sco!e : , &aria'le is created within the sco!e of a !ackage or within the sco!e of a container( task( or e&ent handler in the !ackage" 5ecause the !ackage container is at the to! of the container hierarchy( &aria'les with !ackage sco!e function like glo'al &aria'les and can 'e used 'y all containers in the !ackage" Similarly( &aria'les defined within the sco!e of a container such as a +or 2oo! container can 'e used 'y all tasks or containers within the +or 2oo! container"
Tell me about your experience with SSIS

I think some e1!erience that may stand out from the rest may include 4, 'it more ad&anced):

6e'ugging ;ackages: Setting 'reak !oints( using data&iews( running S02 !rofiler Areating custom configurations: <92 and 65 6e!loyment Strategies Austom 2ogging Bunning control flow and data flow in Transactions 9ulticast transformation ) The 9ulticast transformation distri'utes its in!ut to one or more out!uts" This transformation is similar to the Aonditional S!lit transformation" 5oth transformations direct an in!ut to multi!le out!uts" The difference 'etween the two is that the 9ulticast transformation directs e&ery row to e&ery out!ut( and the Aonditional S!lit directs a row to a single out!ut

0uestion 1 ) True or +alse ) @sing a check!oint file in SSIS is =ust like issuing the A-8AC;>IDT command against the relational engine" It commits all of the data to the data'ase" +alse" SSIS !ro&ides a Aheck!oint ca!a'ility which allows a !ackage to restart at the !oint of failure" 0uestion 2 ) Aan you e1!lain the what the Im!ortE81!ort tool does and the 'asic ste!s in the wi7ard. The Im!ortE81!ort tool is accessi'le &ia 5I6S or e1ecuting the dtswi7ard command" The tool identifies a data source and a destination to mo&e data either within 1 data'ase( 'etween instances or e&en from a data'ase to a file 4or &ice &ersa)" 0uestion 3 ) What are the command line tools to e1ecute S02 Ser&er Integration Ser&ices !ackages. 6TS8<8A@I ) When this command line tool is run a user interface is loaded in order to configure each of the a!!lica'le !arameters to e1ecute an SSIS !ackage" 6T8<8A ) This is a !ure command line tool where all of the needed switches must 'e !assed into the command for successful e1ecution of the SSIS !ackage" 0uestion 4 ) Aan you e1!lain the S02 Ser&er Integration Ser&ices functionality in 9anagement Studio. :ou ha&e the a'ility to do the following: 2ogin to the S02 Ser&er Integration Ser&ices instance ?iew the SSIS log ?iew the !ackages that are currently running on that instance 5rowse the !ackages stored in 9S65 or the file system Im!ort or e1!ort !ackages 6elete !ackages Bun !ackages 0uestion ) Aan you name some of the core SSIS com!onents in the 5usiness Intelligence 6e&elo!ment Studio you work with on a regular 'asis when 'uilding an SSIS !ackage. Aonnection 9anagers Aontrol +low 6ata +low 8&ent -andlers ?aria'les window Tool'o1 window >ut!ut window

2ogging ;ackage Aonfigurations 0uestion 6ifficulty F 9oderate 0uestion 1 ) True or +alse: SSIS has a default means to log all records u!dated( deleted or inserted on a !er ta'le 'asis" +alse( 'ut a custom solution can 'e 'uilt to meet these needs" 0uestion 2 ) What is a 'reak!oint in SSIS. -ow is it setu!. -ow do you disa'le it. , 'reak!oint is a sto!!ing !oint in the code" The 'reak!oint can gi&e the 6e&elo!erE65, an o!!ortunity to re&iew the status of the data( &aria'les and the o&erall status of the SSIS !ackage" 13 unique conditions e1ist for each 'reak!oint" 5reak!oints are setu! in 5I6S" In 5I6S( na&igate to the control flow interface" Bight click on the o'=ect where you want to set the 'reak!oint and select the G8dit 5reak!oints"""G o!tion" 0uestion 3 ) Aan you name or more of the nati&e SSIS connection managers. >2865 connection ) @sed to connect to any data source requiring an >2865 connection 4i"e"( S02 Ser&er 2333) +lat file connection ) @sed to make a connection to a single file in the +ile System" Bequired for reading information from a +ile System flat file ,6>"Det connection ) @ses the "Det ;ro&ider to make a connection to S02 Ser&er 233 or other connection e1!osed through managed code 4like AH) in a custom task ,nalysis Ser&ices connection ) @sed to make a connection to an ,nalysis Ser&ices data'ase or !ro=ect" Bequired for the ,nalysis Ser&ices 662 Task and ,nalysis Ser&ices ;rocessing Task +ile connection ) @sed to reference a file or folder" The o!tions are to either use or create a file or folder 81cel +T; -TT; 9S90 S9> S9T; S029o'ile W9I 0uestion 4 ) -ow do you eliminate quotes from 'eing u!loaded from a flat file to S02 Ser&er. In the SSIS !ackage on the +lat +ile Aonnection 9anager 8ditor( enter quotes into the Te1t qualifier field then !re&iew the data to ensure the quotes are not included" ,dditional information: -ow to stri! out dou'le quotes from an im!ort file in S02 Ser&er Integration Ser&ices 0uestion ) Aan you name or more of the main SSIS tool 'o1 widgets and their functionality. +or 2oo! Aontainer +oreach 2oo! Aontainer Sequence Aontainer ,cti&e< Scri!t Task ,nalysis Ser&ices 81ecute 662 Task ,nalysis Ser&ices ;rocessing Task 5ulk Insert Task 6ata +low Task 6ata 9ining 0uery Task 81ecute 6TS 2333 ;ackage Task 81ecute ;ackage Task 81ecute ;rocess Task

81ecute S02 Task etc" 0uestion 6ifficulty F 6ifficult 0uestion 1 ) Aan you e1!lain one a!!roach to de!loy an SSIS !ackage. >ne o!tion is to 'uild a de!loyment manifest file in 5I6S( then co!y the directory to the a!!lica'le S02 Ser&er then work through the ste!s of the !ackage installation wi7ard , second o!tion is using the dtutil utility to co!y( !aste( rename( delete an SSIS ;ackage , third o!tion is to login to S02 Ser&er Integration Ser&ices &ia S02 Ser&er 9anagement Studio then na&igate to the GStored ;ackagesG folder then right click on the one of the children folders or an SSIS !ackage to access the GIm!ort ;ackages"""G or G81!ort ;ackages"""Go!tion" , fourth o!tion in 5I6S is to na&igate to +ile I Sa&e Ao!y of ;ackage and com!lete the interface"

0uestion 2 ) Aan you e1!lain how to setu! a check!oint file in SSIS. The following items need to 'e configured on the !ro!erties ta' for SSIS !ackage: Aheck!oint+ileDame ) S!ecify the full !ath to the Aheck!oint file that the !ackage uses to sa&e the &alue of !ackage &aria'les and log com!leted tasks" Bather than using a hard)coded !ath as shown a'o&e( itGs a good idea to use an e1!ression that concatenates a !ath defined in a !ackage &aria'le and the !ackage name" Aheck!oint@sage ) 6etermines ifJhow check!oints are used" Ahoose from these o!tions: De&er 4default)( If81ists( or ,lways" De&er indicates that you are not using Aheck!oints" If81ists is the ty!ical setting and im!lements the restart at the !oint of failure 'eha&ior" If a Aheck!oint file is found it is used to restore !ackage &aria'le &alues and restart at the !oint of failure" If a Aheck!oint file is not found the !ackage starts e1ecution with the first task" The ,lways choice raises an error if the Aheck!oint file does not e1ist" Sa&eAheck!oints ) Ahoose from these o!tions: True or +alse 4default)" :ou must select True to im!lement the Aheck!oint 'eha&ior" 0uestion 3 ) Aan you e1!lain different o!tions for dynamic configurations in SSIS. @se an <92 file @se custom &aria'les @se a data'ase !er en&ironment with the &aria'les @se a centrali7ed data'ase with all &aria'les 0uestion 4 ) -ow do you u!grade an SSIS ;ackage. 6e!ending on the com!le1ity of the !ackage( one or two techniques are ty!ically used: Becode the !ackage 'ased on the functionality in S02 Ser&er 6TS @se the 9igrate 6TS 2333 ;ackage wi7ard in 5I6S then recode any !ortion of the !ackage that is not accurate 0uestion ) Aan you name fi&e of the ;erfmon counters for SSIS and the &alue they !ro&ide. S02Ser&er:SSIS Ser&ice SSIS ;ackage Instances ) Total num'er of simultaneous SSIS ;ackages running S02Ser&er:SSIS ;i!eline 52>5 'ytes read ) Total 'ytes read from 'inary large o'=ects during the monitoring !eriod" 52>5 'ytes written ) Total 'ytes written to 'inary large o'=ects during the monitoring !eriod" 52>5 files in use ) Dum'er of 'inary large o'=ects files used during the data flow task during the monitoring !eriod" 5uffer memory ) The amount of !hysical or &irtual memory used 'y the data flow task during the monitoring !eriod" 5uffers in use ) The num'er of 'uffers in use during the data flow task during the monitoring !eriod"

5uffers s!ooled ) The num'er of 'uffers written to disk during the data flow task during the monitoring !eriod" +lat 'uffer memory ) The total num'er of 'locks of memory in use 'y the data flow task during the monitoring !eriod" +lat 'uffers in use ) The num'er of 'locks of memory in use 'y the data flow task at a !oint in time" ;ri&ate 'uffer memory ) The total amount of !hysical or &irtual memory used 'y data transformation tasks in the data flow engine during the monitoring !eriod" ;ri&ate 'uffers in use ) The num'er of 'locks of memory in use 'y the transformations in the data flow task at a !oint in time" Bows read ) Total num'er of in!ut rows in use 'y the data flow task at a !oint in time" Bows written ) Total num'er of out!ut rows in use 'y the data flow task at a !oint in time"

1. What does a control flow do? 2. Generically explain what happens inside a data flow task? 3. Explain what ETL is? 4. Which task would you use to copy !o"e or delete files? #. Which transfor! would you use to split your data $ased on conditions you define? %. Explain the pros and cons of deployin& to a file syste! "s !sd$?
01 81!lain architecture of SSIS. http://technet.microsoft.com/en-us/library/ms14170 !S"#. 0$.aspx 02 6ifference 'etween Aontrol +low and 6ata +low. %ery easy. 03 -ow would you do 2ogging in SSIS. #o& usin& the lo&&in& confi&uration inbuilt in SSIS or use 'ustom lo&&in& throu&h ()ent han*lers. http://ms*n.microsoft.com/en-us/library/ms1417+7.aspx 04 -ow would you do 8rror -andling. its for you. 0 -ow to !ass !ro!erty &alue at Bun time. -ow do you im!lement ;ackage Aonfiguration. http://ms*n.microsoft.com/en-us/library/ms141,-+.aspx 0# -ow would you de!loy a SSIS ;ackage on !roduction. 1. 'reate *eployment utility by settin& its propery as true . +. It will be create* in the bin fol*er of the solution as soon as pac.a&e is buil*. /. 'opy all the files in the utility an* use manifest file to *eply it on the 0ro*. 0$ 6ifference 'etween 6TS and SSIS. ()ery thin& except both are pro*uct of 1icrosoft :-$ 0% What are new features in SSIS 233%. http://s2lser)ersolutions.blo&spot.com/+00 /01/new-impro)ementfeatures-in-ssis-+00-.html 0/ -ow would you !ass a &aria'le &alue to Ahild ;ackage.

http://s2lser)ersolutions.blo&spot.com/+00 /0+/passin&-)ariable-to-chil*-pac.a&e-from.html http://technet.microsoft.com/en-us/library/ms/4317 !S"#. 0$.aspx 013 What is 81ecution Tree. http://technet.microsoft.com/en-us/library/cc ,,3+ .aspx 011 What are the !oints to kee! in mind for !erformance im!ro&ement of the !ackage. http://technet.microsoft.com/en-us/library/cc ,,3+ .aspx 012 :ou may get a question stating a scenario and then asking you how would you create a !ackage for that e"g" -ow would you configure a data flow task so that it can transfer data to different ta'le 'ased on the city name in a source ta'le column. 013 6ifference 'etween @nionall and 9erge *oin. http://s2lser)ersolutions.blo&spot.com/+00 /01/*ifference-between-mer&e-an*-union-all.html 014 9ay get question regarding what < transformation do.2ooku!( fu77y looku!( fu77y grou!ing transformation are my fa&orites" 4or you. 01 -ow would you restart !ackage from !re&ious failure !oint.What are Aheck!oints and how can we im!lement in SSIS. http://ms*n.microsoft.com/en-us/library/ms140++,.aspx 01# Where are SSIS !ackage stored in the S02 Ser&er. 9S65"sys*tspac.a&es 0 stores the actual content an* ssy*tscate&ories5 sys*tslo& 05 sys*tspac.a&efol*ers 05 sys*tspac.a&elo&5 sys*tssteplo&5 an* sys*tstas.lo& *o the supportin& roles. 01$ -ow would you schedule a SSIS !ackages. @sing S02 Ser&er ,gent" Bead a'out Scheduling a =o' on Sql ser&er ,gent 01% 6ifference 'etween asynchronous and synchronos transformations. ,synchronous transformation ha&e different In!ut and >ut!ut 'uffers and it is u! to the com!onent designer in an ,sync com!onent to !ro&ide a column structure to the out!ut 'uffer and hook u! the data from the in!ut" "1 6ow to achie)e multiple threa*in& in SSIS7

Passing variable to Child package from Parent package in SSIS


0oste* by 8ahul 9umar at :e*nes*ay5 4ebruary +35 +00

%ery fre2uent "uestion which loo.s so complicate* to pro&rammers. ;ctually passin& a )ariable )alue to a chil* pac.a&e is )ery tri)ial tas.. :e can pass on the )alue by confi&urin& parent )ariable in pac.a&e confi&uration but there is an easy way of achie)e this an* the fact lies beneath the fun*amental principle of %ariable Scope. If you call a 'hil* pac.a&e then it is li.e a container itself an* all the )ariables *efine* in abo)e hierarchy will be accessible in the 'hil* pac.a&e. #et me show this with an example in which I will *eclare a )ariable <0arent%ar< in my parent pac.a&e an* call a 'hil* pac.a&e which will access <0arent%ar< an* *isplay in a ms&box. 1$ 0arent: 'reate 0arent 0ac.a&e an* *eclare a )ariable <0arent%ar<

+$ 'hil*: 'reate a 'hil* pac.a&e an* use a script tas. an* *efine rea*only )ariable as 0arent%ar

/$ 'hil*: =ow in Script you can use 0arent%ar li.e any other )ariable.e& I am usin& to *isplay it in a ms&box. I woul* su&&est to create another chil* pac.a&e )ariable an* assi&n 0arent pac.a&e )ariable )alue to it an* use it in the chil* pac.a&e )ariable throu&h out the pac.a&e.

4$ 'hil*: :hole 'hil* pac.a&e will loo. li.e

3$ 0arent: =ow in parent pac.a&e call the chil* pac.a&e throu&h (xecute 0ac.a&e tas.. The 0arent pac.a&e will loo. li.e

,$ 8esult: (xecute 0arent pac.a&e.it will in turn call chil* pac.a&e an* it will *isplay ms&box

6ere was a simple metho* to use parent pac.a&e )ariable in 'hil* pac.a&e.

Readers who read this topic also read : SSIS

>ettin& ?aily 4ee* in SSIS

0assin& )ariable to 'hil* pac.a&e from 0arent pac.a&e in SSIS SSIS Inter)iew "uestions 'opy/8ename a file usin& 4ile System Tas. in SSIS 'olumn len&th in (xcel source

8elate* 0osts :i*&et @7A

Copy/Rename a file using File System ask in SSIS


0oste* by 8ahul 9umar at Tues*ay5 ;pril +15 +00

This is a reference answer to a post on 1S?= forum but is )ery useful

Question: :hile copyin& an* renamin& a file to a *ynamic location throu&h 4ile System
Tas. usin& )ariable throws an error

Error' (ailed to lock "aria$le )c'*test*test+2,,-,42,2,,-.txt) for read access with error ,x.,,1,,,1 )The "aria$le cannot $e found. This occurs when an atte!pt is !ade to retrie"e a "aria$le fro! the /aria$les collection on a container durin& execution of the packa&e and the "aria$le is not there. The "aria$le na!e !ay ha"e chan&ed or the "aria$le is not $ein& created.). OR
6ow to copy an* rename a file to a *ynamic location usin& SSIS7

Solution:
I will mo)e an* rename a file <test.txt< from c:B to c:Bbac.up with new name appen*e* with *ate.

1)

'reate three )ariables

0rc+(ile 1 c'*test.txt 2est+(ile 1 test 2est+2ir 1 c'*$ackup

2) In connection Manager create a File Connection with name as DestinationConn

3) In Expression property of DestinationConn use ConnectionString and


provide following expression @[Dest_Dir] + "\\" + @[Dest_File] + "_" + (DT_WSTR,4)DatePart("yyyy", GetDate()) + RIGHT(" " + (DT_WSTR,!)DatePart("""", GetDate()), !) + RIGHT(" " + (DT_WSTR,!)DatePart("##", GetDate()), !) + RIGHT(" " + (DT_WSTR,!)DatePart("$$", GetDate()), !) + RIGHT(" " + (DT_WSTR,!)DatePart(""i", GetDate()), !) + "%t&t"

this will set the destination path and new name for the file

4) Create a File System task and configure like :

5) Execute the package

You might also like