Pages

Sunday, March 17, 2013

Informatica Real time interview questions with answers


Qn1 What is the difference in Connected and Unconnected Lookup?

Ans:
Unconnected lookup
Connected lookup
Returns only 1 column
Can return more then one column
Only Static Cache
Static as well as dynamic
Not connected with any transformation
Connected
When lookup not found returns null
Default
Can be called
No


Qn2 :Why Unconnected lookup is used or In which scenario unconnected lookup is used
Ans

Ans
1. When Lookup is used more than one time in mapping

2. The benefit of an unconnected lookup is that you can do conditional lookups (using IIF,DECODE, etc.). In other words, you can control when the lookup is used with in unconnected lookup.
Example iif(isnull(prod_type),’x’, lkp.p_name(:ptypecode))
3. It provides reusability

For the example

Source:EDW
Code NP
Type:Customer type
Code Description: Nurse practitioner

Source:EDW
Code NJ
Type:State code
Code Description: New Jersy

Suppose in the mapping expression you need to get the description for different ports from code table

When it is getting  the description for Customer type system it is used like lkp.get_code_val(‘EDW’,'CUST_TYPE',’NP’)
When it is getting  the description from IMS system it is used like lkp.get_code_val(‘EDW’,'STATE_CODE',’NJ’)

4. It is used is slowly changing dimensions
    Checking the record exists or not then decide insert or update

Q3:Using indirect method we can load files with same structure. How to load file name in the database.
 Input files
 File1.txt
Andrew|PRES|Addline1|NJ|USA
Samy|NPRS|Addline1|NY|USA
 File2.txt
Bharti|PRES|Addline1|KAR|INDIA
Ajay|PRES|Addline1|RAJ|INDIA
Bhawna|NPRS|Addline1|TN|INDIA
 In database want to load the file name
File Name
Name
Type
Address Line
State
Country
File1.txt
Andrew
PRES
Addline1
NJ
USA
File1.txt
Samy
NPRS
Addline1
NY
USA
File2.txt
Bharti
PRES
Addline1
KAR
INDIA
File2.txt
Ajay
PRES
Addline1
RAJ
INDIA
File2.txt
Bhawna
NPRS
Addline1
TN
INDIA
 Ans:
This can be done by enabling CurrentlyProcessedRow
Do this in the source analyzer while create the source definition
 Then this Currently ProcessedRows column will be enabled
 
 Qn4:Sequence Generator or Update Strategy transformation can not be used in upstream from a Union transformation.Any reason behind this

Ans:
We can not use Sequence generator before Union transformation because, union transformation used to combined two sets of same attributes data into one set. If you use Sequence transformation for two sets of data before Union then the output of union will give duplicate values and if you are trying load this attribute values in target as primary key it will reject data.  Update Strategy:  Union transformation used to change row type. If any update Strategy transformation used before Union and any record flagged as Update or Reject, that record type may change in Union transformation.     

Qn5 What are the row and Column Indicator
Ans:
Bad files have the row and columns indicator RowIndicator Meaning Rejected By 
IndicatorDescription
0Insert Writer or target 
1Update Writer or target
2Delete Writer or target 
3Reject Write
4Rolled-back insert Writer 
5Rolled-back update Writer 
6Rolled-back delete Writer
7Committed insert Writer
8Committed update Writer 
9Committed delete Writer
column indicators, are as below:
Column IndicatorDescription
DValid data. Good data. Writer passes it to the target
database. The target accepts it unless a database error occurs, such as finding a duplicate key. 
O Overflow Numeric data exceeded the specified precision or scale for the column. Bad data, if you configured the mapping target to reject overflow or truncated data. 
NNull The column contains a null value. Good data. Writer passes it to the target, which rejects it if the target database does not accept null values. 
TTruncated String data exceeded a specified precision for the column, so the PowerCenter Server truncated it. Bad data, if you configured the mapping target to reject overflow or truncated data

2 comments:

  1. thank you for your wonderful information on informatica keep sharing thank you
    visit our site to learn

    learn Advanced informatica!

    ReplyDelete