Answers 4
Answers 4
1) How can you recognise whether or not the newly added rows in the source are
gets insert in the target?
Ans) 1.checking target success rows in the workflow monitor
2.through scd type2 flag version
2) What is the difference between Informatica 7.0 and 8.0 ?
Ans)
Informatica 7.0 Informatica 8.1.1
Architectur
e
Informatica 7.0 is a client
server architecture where
8.0 is service oriented
architecture
PC8 is service-oriented for modularity, scalability
and flexibility.
Service The Repository Service and Integration Service (as
replacement for Rep Server and Informatica
Server) can be run on different
computers in a network (so called nodes), even
redundantly.
Manageme
nt
Management is centralized, that means services
can be started and stopped on nodes via a central
web interface.
Tools Client Tools access the repository via that
centralized machine, resources are distributed
dynamically.
Portability Running all services on one machine is still
possible, of course.
Supports . It has a support for unstructured data which
includes spreadsheets, email, Microsoft Word files,
presentations and .PDF documents. It provides
high availability, seamless fail over, eliminating
single points of failure.
Performanc
e
grid and pushdown
optimization is not there in
7.0 but in 8.0 these are
available
It has added performance improvements (To bump
up systems performance, Informatica has added
"push down optimization" which moves data
transformation processing to the native relational
database I/O engine whenever its is most
appropriate.)
Capabilities Through 7.0 migration is
critical where as with 8.0
migration is possible and
easy
Informatica has now added more tightly
integrated data profiling, cleansing, and matching
capabilities.
web Informatica has added a new web based
administrative console.
Additional
Transforma
tions
Ability to write a Custom Transformation in C++ or
Java. Midstream SQL transformation has been
added in 8.1.1, not in 8.1.
encryption and description User defined functions
35
Reject file: This file contains the rows of data that the writer does notwrite to
targets.
Control file: Informatica server creates control file and a target file when you
run a session
that uses the external loader.The control file contains the information about the
target flat file such as data format and loading instructios for the external
loader.
Post session email: Post session email allows you to automatically communicate
information
about a session run to designated recipents.You can create two different
messages.One if the session completed sucessfully the other if the session fails.
Indicator file: If you use the flat file as a target,You can configure the
informatica server to
create indicator file.For each target row,the indicator file contains a number to
indicate
whether the row was marked for insert,update,delete or reject.
output file: If session writes to a target file,the informatica server creates the
target file
based on file prpoerties entered in the session property sheet.
Cache files: When the informatica server creates memory cache it also creates cache
files.
For the following circumstances informatica server creates index and datacache
files:-
Aggreagtor transformation
Joiner transformation
Rank transformation
Lookup transformation
18) How many types of dimensions are available in Informatica?
Ans) The types of dimensions available are:
1. Junk dimension
2. Degenerative Dimension
3. Conformed Dimension
19) Define informatica repository?
Ans) Infromatica Repository:The informatica repository is at the center of the
informatica
suite. You create a set of metadata tables within the repository database that the
informatica application and tools access. The informatica client and server access
the
repository to save and retrieve metadata.
20) How do you configure mapping in informatica
Ans) You should configure the mapping with the least number of transformations and
expressions to do the most amount of work possible. You should minimize the amount
of
data moved by deleting unnecessary links between transformations.
For transformations that use data cache (such as Aggregator, Joiner, Rank, and
Lookup
transformations), limit connected input/output or output ports. Limiting the number
of
connected input/output or output ports reduces the amount of data the
transformations
store in the data cache.
You can also perform the following tasks to optimize the mapping:
Configure single-pass reading.
Optimize datatype conversions.
Eliminate transformation errors.
Optimize transformations.
Optimize expressions.
21) How can you create or import flat file definition in to the warehouse designer?
Ans) You can not create or import flat file defintion in to warehouse designer
directly.Instead you must analyze the file in source analyzer,then drag it into the
warehouse
35
designer.
When you drag the flat file source defintion into warehouse desginer workspace,the
warehouse designer creates a relational target defintion not a file defintion.If
you want to
load to a file,configure the session to write to a flat file.When the informatica
server runs
the session,it creates and loads the flat file.
22) When we create a target as flat file and source as oracle.. how can i specify
first rows as column names in flat files...
Ans) use a pre sql statement....but this is a hardcoding method...if you change the
column
names or put in extra columns in the flat file, you will have to change the insert
statement.
You can also achive this by changing the setting in the Informatica Repository
manager to
display the columns heading. The only disadvantage of this is that it will be
applied on all
the files that will be generated by This server
When importing a flat file into target designer a flat file import wizard appears.
In this there
is an option as 'import field names from first line'. Just check this option so
integration
server treats first row values as column names.
23) Discuss the advantages & Disadvantages of star & snowflake schema?
Ans) In a STAR schema there is no relation between any two dimension tables,
whereas in
a SNOWFLAKE schema there is a possible relation between the dimension tables.In
star
schema there is no relationship between two relational tables. All dimensions are
denormalized
and query performence is degrades. In this snow flake schema dimensions are
normalized. In this SF schema table space is increased.Maintenence cost is
high.Query
performence is increaced.
24) Difference between Rank and Dense Rank?
Ans) Rank:
1
2<--2nd position
2<--3rd position
4
5
Same Rank is assigned to same totals/numbers. Rank is followed by the Position.
Golf game
ususally Ranks this way. This is usually a Gold Ranking.
Dense Rank:
1
2<--2nd position
2<--3rd position
3
4
Same ranks are assigned to same totals/numbers/names. the next rank follows the
serial
number.
25) Can anyone explain error handling in Informatica with examples so that it will
be easy to explain the same in the interview.
Ans) Go to the session log file there we will find the information regarding to the
session initiation process,
errors encountered.
load summary.
so by seeing the errors encountered during the session running, we can resolve the
errors.
35
There is one file called the bad file which generally has the format as *.bad and
it contains
the records rejected by informatica server. There are two parameters one fort the
types of
row and other for the types of columns. The row indicators signifies what operation
is going
to take place ( i.e. insertion, deletion, updation etc.). The column indicators
contain
information regarding why the column has been rejected.( such as violation of not
null
constraint, value error, overflow etc.) If one rectifies the error in the data
preesent in the
bad file and then reloads the data in the target,then the table will contain only
valid data.
26) What is the difference between connected and unconnected stored
procedures.
Ans) Unconnected:
The unconnected Stored Procedure transformation is not connected directly to the
flow of
the mapping. It either runs before or after the session, or is called by an
expression in
another transformation in the mapping.
connected:
The flow of data through a mapping in connected mode also passes through the Stored
Procedure transformation. All data entering the transformation through the input
ports
affects the stored procedure. You should use a connected Stored Procedure
transformation
when you need data from an input port sent as an input parameter to the stored
procedure,
or the results of a stored procedure sent as an output parameter to another
transformation.
by using unconnected stored procedure
reusability is possible
in connected only one time is possible
27) Which tasks can be performed on port level(using one specific port)?
Ans) I think unconnected Lookup or expression transformation can be used for single
port
for a row.
28) What are main advantages and purpose of using Normalizer Transformation in
Informatica?
Ans) Narmalizer Transformation is used mainly with COBOL sources where most of the
time
data is stored in de-normalized format. Also, Normalizer transformation can be used
to
create multiple rows from a single row of data
29) What is the difference between constraind base load ordering and target load
plan
Ans) Constraint based load ordering
example:
Table 1---Master
Table 2---Detail
If the data in table1 is dependent on the data in table2 then table2 should be
loaded first.In
such cases to control the load order of the tables we need some conditional loading
which is
nothing but constraint based load
In Informatica this feature is implemented by just one check box at the session
level.
35
A CBl specifies the order in which data loads into the targets based on key
constraints
A target load plan defines the order in which data being extracted from the source
qualifier
30) What is difference between IIF and DECODE function
Ans) You can use nested IIF statements to test multiple conditions. The following
example
tests for various conditions and returns 0 if sales is zero or negative:
IIF( SALES > 0, IIF( SALES < 50, SALARY1, IIF( SALES < 100, SALARY2, IIF( SALES <
200,
SALARY3, BONUS))), 0 )
You can use DECODE instead of IIF in many cases. DECODE may improve readability.
The
following shows how you can use DECODE instead of IIF :
SALES > 0 and SALES < 50, SALARY1,
SALES > 49 AND SALES < 100, SALARY2,
SALES > 99 AND SALES < 200, SALARY3,
SALES > 199, BONUS)
Decode function can used in sql statement. where as if statment cant use with SQL
statement.
31) How can u work with remote database in informatica?did u work directly by
using remote connections?
Ans) To work with remote datasource u need to connect it with remote
connections.But it is
not preferable to work with that remote source directly by using remote connections
.Instead u bring that source into U r local machine where informatica server
resides.If u
work directly with remote source the session performance will decreases by passing
less
amount of data across the network in a particular time.
32) How to import oracle sequence into Informatica.
Ans) CREATE ONE PROCEDURE AND DECLARE THE SEQUENCE INSIDE THE
PROCEDURE,FINALLY CALL THE PROCEDURE IN INFORMATICA WITH THE HELP OF STORED
PROCEDURE TRANSFORMATION.
33) Identifying bottlenecks in various components of Informatica and resolving
them.
Ans) The best way to find out bottlenecks is writing to flat file and see where the
bottle
neck is .
34) What is parameter file?
Ans) For UNIX shell users, enclose the parameter file name in single quotes:
-paramfile '$PMRootDir/myfile.txt'
For Windows command prompt users, the parameter file name cannot have beginning or
trailing spaces. If the name includes spaces, enclose the file name in double
quotes:
-paramfile ?$PMRootDirmy file.txt?
Note: When you write a pmcmd command that includes a parameter file located on
another
machine, use the backslash () with the dollar sign ($). This ensures that the
machine where
35
you have to select Treat Source Rows : Data Driven. If we do not select this
Informatica
server will ignore updates and it only Inserts rows.
3) If we have mappings loading multiple target tables we have to provide the Target
Load
Plan
in the sequence we want them to get loaded.
4) Error:Snapshot too old is a very common error when using Oracle tables. We get
this
error
while using too large tables. Idealy we should schelude these loads when server is
not very
busy (meaning when no other loads are running).
5) We might get some poor performance issues while reading from large tables. All
the
source tables
should be indexed and updated regularly.
41) What is difference between maplet and reusable transformation?
Ans) mapplet:-
--contains input and output transformations.
--designed in mapplet designer.
--reusable.
--contains multiple transformations.
--we use it to reuse multiple tr for a task to be done.
Reusable transformation:-
--no input and output transformation is needed.
--designed in mapping designer.
--reusable.
--It is a singl transformation
--we create it to reuse a single transformation in future
42) How many types of facts and what are they?
Ans) There are
Factless Facts:Facts without any measures.
Additive Facts:Fact data that can be additive/aggregative.
Non-Additive facts: Facts that are result of non-additon
Semi-Additive Facts: Only few colums data can be added.
Periodic Facts: That stores only one row per transaction that happend over a period
of time.
Accumulating Fact: stores row for entire lifetime of event.
43) what are load types in informatica and what is delta load
Ans) There are two types of load i) Normal Load ii) Bulk Load
Normal Load-
The integration service writes to the database log then it enters into target.
a)performance of loading to target decreases but session recovery occurs.
b)Rollback and commit possible
Bulk Load:
The integration service bypasses the database log without writing into it and
directly loaded
into target.
a)Performance increases but session recovery doesnot occur.
b) Rollback and commit also not possible.
In bulk loading we need to consider the following:
1)Without creating any primary and foreign key at database level but however in
target
definition.
2)drop index before loading into target and create index after loading.
3)disable enable parallel mode option
35
47) Where to store informatica rejected data? How to extract the informatica
rejected data ?
Ans) The reject rows say for example due to unique key constrain is all pushed by
session
into the $PMBadFileDir (default relative path is
<INFA_HOME/PowerCenter/server/infa_shared/BadFiles) which is configured with path
at
Integration Service level. Every Target will have property saying Reject filename
which
gives the file in which rejects rows are stored.
48)How to use the unconnected lookup i.e., from where the input has to be taken
and the output is linked? What condition is to be given?
Ans) The unconnected lookup is used just like a function call. in an expression
output/variable port or any place where an expression is accepted(like condition in
update
strategy etc..), call the unconnected lookup...something like
:LKP.lkp_abc(input_port).......
(lkp_abc is the name of the unconnected lookup...(plz check the exact
syntax)).....give the
input value just like we pass parameters to functions, and it'll return the output
after
looking up.
49) What is the Rankindex in Ranktransformation?
Ans) The Designer automatically creates a RANKINDEX port for each Rank
transformation.
The Informatica Server uses the Rank Index port to store the ranking position
for<br>each
record in a group. For example, if you create a Ranktransformation that ranks the
top 5
salespersons for each quarter, the rank index numbers the salespeople from 1<br>to
5.
50) What is difference between partioning of relatonal target and partitioning of
file targets?
Ans) Partition's can be done on both relational and flat files.
Informatica supports following partitions
1.Database partitioning
2.RoundRobin
3.Pass-through
4.Hash-Key partitioning
5.Key Range partitioning
All these are applicable for relational targets.For flat file only database
partitioning is not
applicable.
Informatica supports Nway partitioning.U can just specify the name of the target
file and
create the partitions, rest will be taken care by informatica session.
51) Why did u use update stategy in your application?
Ans) Update Strategy is used to drive the data to be Inert, Update and Delete
depending
upon some condition. You can do this on session level tooo but there you cannot
define any
condition.For eg: If you want to do update and insert in one mapping...you will
create two
flows and will make one as insert and one as update depending upon some
condition.Refer :
Update Strategy in Transformation Guide for more information
52) What is IQD file?
Ans) IQD file is nothing but Impromptu Query Definetion,This file is maily used in
Cognos
Impromptu tool after creating a imr( report) we save the imr as IQD file which is
used while
creating a cube in power play transformer.In data source type we selectImpromptu
Query
Definetion.
53) What r the mapings that we use for slowly changing dimension table?
35
Ans) We can use the following Mapping for slowly Changing dimension table.
? Expression
? Lookup
? Filter
? Sequence Generator
? Update Strategy
54) How do I import VSAM files from source to target. Do I need a special plugin
Ans) As far my knowledge by using power exchange tool convert vsam file to oracle
tables
then do mapping as usual to the target table.
55) What is meant by aggregate fact table and where is it used?
Ans) Basically fact tables are two kinds 1. Aggregated factable and Factless fact
table.
Agregated factable has aggregarted columns. for eg. Total-Sal, Dep-Sal. where as in
factless factable will not have aggregated colums and it only has FK to the
Dimension
tables.
56) What are Target Types on the Server?
Ans) Target Types are File, Relational and ERP.
57) What are mapping parameters and varibles in which situation we can use it
Ans) If we need to change certain attributes of a mapping after every time the
session is
run, it will be very difficult to edit the mapping and then change the attribute.
So we use
mapping parameters and variables and define the values in a parameter file. Then we
could
edit the parameter file to change the attribute values. This makes the process
simple.
Mapping parameter values remain constant. If we need to change the parameter value
then
we need to edit the parameter file .
But value of mapping variables can be changed by using variable function. If we
need to
increment the attribute value by 1 after every session run then we can usemapping
variables .
In a mapping parameter we need to manually edit the attribute value in the
parameter file
after every session run.
58) How do you create single lookup transformation using multiple tables?
Ans) Write a override sql query. Adjust the ports as per the sql query.
59) Why is meant by direct and indirect loading options in sessions?
Ans) when we use multiple source files, we create a file containing the names and
directories of each source file we want the PowerCenter Server to use. This file is
referred to
as a file list.
when configuring the session properties,choose Indirect in the Source Filetype
field,enter
the file name of the file list in the Source Filename field and enter the location
of the file list
in the Source File Directory field. When the session starts, thePowerCenter Server
reads the
file list, then locates and reads the first file source in the list. After the
PowerCenter Server
reads the first file, it locates and reads the next file in the list.
60) What are Target Options on the Servers?
Ans) Target Options for File Target type are FTP File, Loader and MQ.
There are no target options for ERP target type.
Target Options for Relational are Insert, Update (as Update), Update (as Insert),
Update
(else Insert), Delete, and Truncate Table.
35
61) what are the difference between view and materialized view?
Ans) Materialized views are schema objects that can be used to summarize,
precompute,
replicate, and distribute data. E.g. to construct a data warehouse.
A materialized view provides indirect access to table data by storing the results
of a query in
a separate schema object. Unlike an ordinary view, which does not take up any
storage
space or contain any data
62) To achieve the session partition what are the necessary tasks you have to do?
Ans) Configure the session to partition source data.
Install the informatica server on a machine with multiple CPU?s.
63) On a day, I load 10 rows in my target and on next day if I get 10 more rows to
be added to my target out of which 5 are updated rows how can I send them to
target? How can I insert and update the record?
Ans) We can achieve this task by SCD(slowly changing dimensions) type 1.
1. have a lookup on target and check for the primary key values, if the record is
new, insert
the record and if the record has changed, then update the record.
2. for this u have to create a update strategy transformation inside the mapping.
64) Can you generate reports in Informatcia?
Ans) Yes. By using Metadata reporter we can generate reports in
informatica.Informatica is
tool to support data extracting ,transforming and loading.i am not sure informatica
support
for reporting.my experience is concern informatica doesn't support reporting.
65) Explain use of update strategy transformation
Ans) This is the important transformation,is used to maintain the history data or
just most
recent changes into the target table.
We can set or flag the records by using these two levels.
1) Within a session:
When you configure the session,you can instruct the informatica server to either
treat all
the records in the same way.
2) Within a mapping:
within a mapping we use update strategy transformation to flag the records like
insert,update,delete or reject.
66) The designer includes a "Find" search tool as part of the standard tool bar.
What can it be used to find?
Ans) Search for two things:
1. Transformations
2. Ports in the Transformation
67) If you have four lookup tables in the workflow. How do you troubleshoot to
improve performance?
Ans) There r many ways to improve the mapping which has multiple lookups.
1) we can create an index for the lookup table if we have permissions(staging
area).
2) divide the lookup mapping into two (a) dedicate one for insert means: source -
target,,
these r new rows . only the new rows will come to mapping and the process will be
fast . (b)
35
dedicate the second one to update : source=target,, these r existing rows. only the
rows
which exists allready will come into the mapping.
3)we can increase the chache size of the lookup.
68) How to recover sessions in concurrent batches?
Ans) If multiple sessions in a concurrent batch fail, you might want to truncate
all targets
and run the batch again. However, if a session in a concurrent batch fails and the
rest of
the sessions complete successfully, you can recover the session as a standalone
session.
To recover a session in a concurrent batch:
1.Copy the failed session using Operations-Copy Session.
2.Drag the copied session outside the batch to be a standalone session.
3.Follow the steps to recover a standalone session.
4.Delete the standalone copy.
69) Briefly explian the Versioning Concept in Power Center 7.1.
Ans) When you create a version of a folder referenced by shortcuts, all shortcuts
continue
to reference their original object in the original version. They do not
automatically update to
the current folder version.
For example, if you have a shortcut to a source definition in the Marketing folder,
version
1.0.0, then you create a new folder version, 1.5.0, the shortcut continues to point
to the
source definition in version 1.0.0.
Maintaining versions of shared folders can result in shortcuts pointing to
different versions
of the folder. Though shortcuts to different versions do not affect the server,
they might
prove more difficult to maintain. To avoid this, you can recreate shortcuts
pointing to earlier
versions, but this solution is not practical for much-used objects. Therefore, when
possible,
do not version folders referenced by shortcuts.
70) Why we use lookup transformations?
Ans) Get a related value-Get the Employee Name from Employee table based on the
Employee IDPerform Calculation.
Update slowly changing dimension tables - We can use unconnected lookup
transformation
to determine whether the records already exist in the target or not.
71) What is Datadriven?
Ans) The informatica server follows instructions coded into update strategy
transformations
with in the session maping determine how to flag records for insert, update, delete
or
reject. If you do not choose data driven option setting,the informatica server
ignores all
update strategy transformations in the mapping.If the data driven option is
selected in the
session properties,it follows the instructions in the update strategy
transformation in the mapping o.w it follows instuctions specified in the session.
72) What is batch and describe about types of batches?
Ans) Batch--- is a group of any thing
Different batches ----Different groups of different things.
There are two types of batches
1. Concurrent
2. Sequential
73) Can Informatica be used as a Cleansing Tool? If Yes, give example of
transformations that can implement a data cleansing routine.
35
Ans) Yes, we can use Informatica for cleansing data. some time we use stages to
cleansing
the data. It depends upon performance again else we can use expression to cleasing
data.
For example an feild X have some values and other with Null values and assigned to
target
feild where target feild is notnull column, inside an expression we can assign
space or some
constant value to avoid session failure.
The input data is in one format and target is in another format, we can change the
format in
expression.
we can assign some default values to the target to represent complete set of data
in the
target.
74) Differences between connected and unconnected lookup?
Ans) Connected lookup:-
1> Receives input values diectly from the pipe line.
2> You can use a dynamic or static cache.
3> Cache includes all lookup columns used in the maping.
4> Support user defined default values.
Unconnected lookup:-
1> Receives input values from the result of a lkp expression in a another
transformation.
2> You can use a static cache.
3> Cache includes all lookup out put ports in the lookup condition and the
lookup/return
port.
4> Does not support user defiend default values.
75) How to read rejected data or bad data from bad file and reload it to target?
Ans) Correction the rejected data and send to target relational tables using
loadorder
utility. Find out the rejected data by using column indicatior and row indicator.
76) What are the various test procedures used to check whether the data is loaded
in the backend, performance of the mapping, and quality of the data loaded in
INFORMATICA. 2) What are the common problems developers face while ETL
development
Ans) If you want to know the performance of a mapping at transformation level, then
select
the option in the session properties-> collect performance data. At the run time in
the
monitor you can see it in the?performance tab or you can get it from a file.
The PowerCenter Server names the file session_name.perf, and stores it in the same
directory as the session log. If there is no session-specific directory for the
session log,
thePowerCenter Server saves the file in the default log files directory.
Quality of the data loaded depends on the quality of data in the source. If
cleansing is
required then have to perform some data cleansing operations in informatica. Final
data will
always be clean if followed.
77) What are the types of data that passes between informatica server and stored
procedure?
Ans) Three types of data:-
Input/Out put parameters
35
Return Values
Status code.
78) What are the types of metadata that stores in repository?
Ans) Following are the types of metadata that stores in the repository:-
Database connections
Global objects
Mappings
Mapplets
Multidimensional metadata
Reusable transformations
Sessions and batches
Short cuts
Source definitions
Target defintions
Transformations.
79) How to move the mapping from one database to another?
Ans) 1.? Open the mapping you want to migrate.? Go to File Menu - Select 'Export
Objects'
and give a name - an XML file will be generated.? Connect to the repository where
you want
to migrate and then select File Menu - 'Import Objects' and select theXML file
name.
2.? Connect to both the repositories.??Go to the source folder and select mapping
name
from the?object navigator and select?'copy' from 'Edit' menu.? Now, go to the
target folder
and select 'Paste' from 'Edit' menu.? Be sure you open the target folder.
80) What is the target load order?
Ans) The Integration Service reads sources in a target load order group
concurrently, and it
processes target load order groups sequentially.
To specify the order in which the Integration Service sends data to targets, create
one
source qualifier for each target within a mapping. To set the target load order,
you then
determine in which order the Integration Service reads each source in the mapping.
To set the target load order:
1.Create a mapping that contains multiple target load order groups.
2.Click Mappings > Target Load Plan.
The Target Load Plan dialog box lists all Source Qualifier transformations in the
mapping
and the targets that receive data from each source qualifier.
3.Select a source qualifier from the list.
4.Click the Up and Down buttons to move the source qualifier within the load order.
5.Repeat steps 3 to 4 for other source qualifiers you want to reorder.
6.Click OK.
81) Can we eliminate duplicate rows by using filter and router transformation ?if
so explain me in detail .
Ans) U can use SQL query for uniqness if the source is Relational
But if the source is Flat file then u should use Shorter or Aggregatot
transformation
82) What is parameter file?
Ans) Parameter file is to define the values for parameters and variables used in a
session.A
parameter
35
Ans) Joiner Transformation can be used to join tables from hetrogenious (different
sources), but we still need a common key from both tables. If we join two tables
without a
common key we will end up in a Cartesian Join. Joiner can be used to join tables
from
difference source systems where as Source qualifier can be used to join tables in
the same
database.
We definitely need a common key to join two tables no mater they are in same
database or
difference databases.
97) With out using Updatestretagy and sessons options, how we can do the
update our target table?
Ans) n the target definition there is an option to write the update override query,
here we
can specify the update query and this will update the rows.
98) What are the types of maping in Getting Started Wizard?
Ans) Simple Pass through maping :
Loads a static fact or dimension table by inserting all rows. Use this mapping when
you
want to drop all existing data from your table before loading new data.
Slowly Growing target :
Loads a slowly growing fact or dimension table by inserting new rows. Use this
mapping to
load new data when existing data does not require updates.
99) in the concept of mapping parameters and variables, the variable value will be
saved to the repository after the completion of the session and the next time when
u run the session, the server takes the saved variable value in the repository and
starts assigning the next value of the saved value. for example i ran a session and
in the end it stored a value of 50 to the repository.next time when i run the
session, it should start with the value of 70. not with the value of 51. how to do
this.
Ans) u can do one thing after running the mapping,, in workflow manager
start-------->session.
right clickon the session u will get a menu, in that go for persistant values,
there u will find
the last value stored in the repository regarding to mapping variable. then remove
it and
put ur desired one, run the session... i hope ur task will be done
100) What are the joiner caches?
Ans)
master rows.
After building the caches, the Joiner transformation reads records from the detail
source
and perform joins.
101) What transformation you can use inplace of lookup?
Ans) Look-up transformation can serve in so many situations.
So, if you can a bit particular about the scenarioo that you are talking about, it
will be easy
to interpret.
102) How to define Informatica server?
Ans) Informatica server is the main server component in informatica product
family..Which
is resonsible for reads the data from various source system and tranforms the data
according to business rule and loads the data into the target table
103) How can u complete unrcoverable sessions?
35
Ans) Under certain circumstances, when a session does not complete, you need to
truncate
the target tables and run the session from the beginning. Run the session from the
beginning when the Informatica Server cannot run recovery or when running recovery
might result in inconsistent data.
104) How to lookup the data on multiple tabels.
Ans) if the two tables are relational, then u can use the SQL lookup over ride
option to join
the two tables in the lookup properties.u cannot join a flat file and a relatioanl
table.
eg: lookup default query will be select lookup table column_names from
lookup_table. u can
now continue this query. add column_names of the 2nd table with the qualifier, and
a where
clause. if u want to use a order by then use -- at the end of the order by.
105) What is the default source option for update stratgey transformation?
Ans) default option for update stratgey t/r is dd_insert or we can put '0'.
in session level data driven
106)What is pushdown optimizations in pc 8.x with example?
Ans) Use pushdown optimization to push transformation logic to the source or target
database. The Integration Service analyzes the transformation logic, mapping, and
session
configuration to determine the transformation logic it can push to the database. At
run time,
the IntegrationService executes any SQL statement generated against the source or
target
tables, and it processes any transformation logic that it cannot push to the
database.
Select one of the following values:
- None. The Integration Service does not push any transformation logic to the
database.
- To Source. The Integration Service pushes as much transformation logic as
possible to the
source database.
- To Target. The Integration Service pushes as much transformation logic as
possible to the
target database.
- Full. The Integration Service pushes as much transformation logic as possible to
both the
source database and target database.
- $$PushdownConfig. The $$PushdownConfig mapping parameter allows you to run the
same session with different pushdown optimization configurations at different
times. For
more information about configuring the $$PushdownConfig mapping parameter and
parameter file, see Using the $$PushdownConfig Mapping Parameter.
107) In a scenario I have col1, col2, col3, under that 1,x,y, and 2,a,b and I want
in
this form col1, col2 and 1,x and 1,y and 2,a and 2,b, what is the procedure?
Ans) Use Normalizer :
create two ports -
first port occurs = 1
second make occurs = 2
two output ports are created and
connect to target
108) If u had to split the source level key going into two seperate tables. One as
surrogate and other as primary. Since informatica does not gurantee keys are
loaded properly(order!) into those tables. What are the different ways you could
handle this type of situation?
35
Ans) In hash partitioning, the Informatica Server uses a hash function to group
rows of
data among partitions. The Informatica Server groups the data based on a partition
key.Use
hash partitioning when you want the Informatica Server to distribute rows to the
partitions
by group. For example, you need to sort items by item ID, but you do not know how
many
items have a particular ID number.
112) In a joiner transformation, you should specify the source with fewer rows as
the master source. Why?
Ans) Joiner transformation compares each row of the master source against the
detail
source. The fewer unique rows in the master, the fewer iterations of the join
comparison
occur, which speeds the join process.Joiner Transformation will cache Master
table's data
hence it is advised to define table with less #of rows as master.
113) what is difference between lookup cashe and unchashed lookup? Can i run
the mapping with out starting the informatica server?
Ans) The difference between cache and uncacheed lookup iswhen you configure the
lookup
transformation cache lookup it stores all the lookup table data in the cache when
the first
input record enter into the lookup transformation, in cache lookup the select
statement
executes only once and compares the values of the input record with the values in
the
cachebut in uncache lookup the the select statement executes for each input record
entering into the lookup transformation and it has to connect to database each time
entering the new record
114) What are the tasks that Loadmanger process will do?
Ans) Manages the session and batch scheduling: Whe you start the informatica server
the
load maneger launches and queries the repository for a list of sessions configured
to run
on the informatica server.When you configure the session the loadmanager maintains
list of
list of sessions and session start times.When you sart a session loadmanger fetches
the
session information from the repository to perform the validations and
verifications prior to
starting DTM process.
Locking and reading the session: When the informatica server starts a session
lodamaager
locks the session from the repository.Locking prevents you starting the session
again and
again.
Reading the parameter file: If the session uses a parameter files,loadmanager reads
the
parameter file and verifies that the session level parematers are declared in the
file
Verifies permission and privelleges: When the sesson starts load manger checks
whether or
not the user have privelleges to run the session.
Creating log files: Loadmanger creates logfile contains the status of session.
115) How can we join the tables if the tables have no primary and forien key
relation and no matchig port to join?
Ans) without common column or common data type we can join two sources using dummy
ports.
1.Add one dummy port in two sources.
2.In the expression trans assing '1' to each port.
2.Use Joiner transformation to join the sources using dummy port(use join
conditions).
116) In a sequential Batch how can we stop single session?
35
Ans) We can stop it using PMCMD command or in the monitor right click on that
perticular
session and select stop.this will stop the current session and the sessions next to
it.
117) How to create the staging area in your database
Ans) A Staging area in a DW is used as a temporary space to hold all the records
from the
source system. So more or less it should be exact replica of the source systems
except for
the laod startegy where we use truncate and reload options.
So create using the same layout as in your source tables or using the Generate SQL
option
in the Warehouse Designer tab.
118) What is the logic will you implement to laod the data in to one factv from 'n'
number of dimension tables.
Ans) Noramally evey one use
!)slowly changing diemnsions
2)slowly growing dimensions
119) What r the basic needs to join two sources in a source qualifier?
Ans) The both the table should have a common field with same data type.
Its not necessary both should follow primary and foreign relationship. If any
relation ship
exists that will help u in performance point of view.The two sources should be a
relational
and homogeneous
120) What are various types of Aggregation?
Ans) Various types of aggregation are SUM, AVG, COUNT, MAX, MIN, FIRST, LAST,
MEDIAN, PERCENTILE, STDDEV, and VARIANCE.
121) If you want to create indexes after the load process which transformation
you choose?
Ans) Its usually not done in the mapping(transformation) level. Its done in session
level.
Create a command task which will execute a shell script (if Unix) or any other
scripts which
contains the create index command. Use this command task in the workflow after the
session or else, You can create it with a post session command.
122) How the informatica server increases the session performance through
partitioning the source?
Ans) For a relational sources informatica server creates multiple connections for
each
parttion of a single source and extracts seperate range of data for each
connection.
Informatica server reads multiple partitions of a single source
concurently.Similarly for
loading also informatica server creates multiple connections to the target and
loads
partitions of data concurently.
For XML and file sources,informatica server reads multiple files concurently.For
loading the
data informatica server creates a seperate file for each partition(of a source
file). You can
choose to merge the targets.
123) How can you improve the performance of Aggregate transformation?
Ans) we can improve the agrregator performence in the following ways
1.send sorted input.
2.increase aggregator cache size.i.e Index cache and data cache.
35
3.Give input/output what you need in the transformation.i.e reduce number of input
and
output ports.
Use Sorter Transformation to sort input in aggregrator properties
filter the records before
124) What r the unsupported repository objects for a mapplet?
Ans) Source definitions. Definitions of database objects (tables, views, synonyms)
or files
that provide source data.
Target definitions. Definitions of database objects or files that contain the
target data.
Multi-dimensional metadata. Target definitions that are configured as cubes and
dimensions.
Mappings. A set of source and target definitions along with transformations
containing
business logic that you build into the transformation. These are the instructions
that the
Informatica Server uses to transform and move data.
Reusable transformations. Transformations that you can use in multiple mappings.
Mapplets. A set of transformations that you can use in multiple mappings.
Sessions and workflows. Sessions and workflows store information about how and when
the
Informatica Server moves data. A workflow is a set of instructions that describes
how and
when to run tasks related to extracting, transforming, and loading data. A session
is a type
of task that you can put in a workflow. Each session corresponds to a single
mapping.
125) What r the types of lookup caches?
Ans) 1)Static Cache
2)Dynamic Cache
3)Persistent Cache
4)Reusable Cache
5)Shared Cache
126) What r the tasks that source qualifier performs?
Ans) Join data originating from the same source database. You can join two or more
tables
with primary-foreign key relationships by linking the sources to one Source
Qualifier.
Filter records when the Informatica Server reads source data. If you include a
filter
condition, the Informatica Server adds a WHERE clause to the default query.
Specify an outer join rather than the default inner join. If you include a user-
defined join,
the Informatica Server replaces the join information specified by the metadata in
the SQL
query.
Specify sorted ports. If you specify a number for sorted ports, the Informatica
Server adds
an ORDER BY clause to the default SQL query.
Select only distinct values from the source. If you choose Select Distinct, the
Informatica
Server adds a SELECT DISTINCT statement to the default SQL query.
Create a custom query to issue a special SELECT statement for the Informatica
Server to
read source data. For example, you might use a custom query to perform aggregate
calculations or execute a stored procedure.
127) If a session fails after loading of 10,000 records in to the target.How can u
load the records from 10001 th record when u run the session next time in
informatica 6.1?
Ans) Running the session in recovery mode will work, but the target load type
should be
normal. If its bulk then recovery wont work as expected
128) Why dimenstion tables are denormalized in nature ?
35
my project, I felt that the primary reason for the surrogate keys was to record the
changing
context of the dimension attributes.(particulaly for scd )The reason for them being
integer and
integer joins are faster. Unlike other
134) Partitioning, Bitmap Indexing (when to use), how will the bitmap indexing
will effect the performance
Ans) Bitmap indexing a indexing technique to tune the performance of SQL queries.
The default type is B-Tree indexers which is of high cardinality (normalized data).
You can use bitmap indexers for de-normalized data or low cardinalities. The
condition is the amount of DISTINCT rows should be less than 4% of the total rows.
If it satisfies the given condition then bitmap indexers will optimize the
performance
for this kind of tables.
135) What is difference between dimention table and fact table and what are
different dimention tables and fact tables
Ans) In the fact table contain measurable data and less columns and meny rows,
It's contain primarykey
Diffrent types of fact tables:
additive,non additive, semi additive
In the dimensions table contain textual descrption of data and also contain meny
columns,less
rows
Its contain primary key
Both contains primary keys
Fact tables are which are measurable and have less columns and more rows
But in dimension which are not measurable
136) What are cost based and rule based approaches and the difference
Ans) Cost based and rule based approaches are the optimization techniques which
are used in related to databases, where we need to optimize a sql query.
Basically Oracle provides Two types of Optimizers (indeed 3 but we use only these
two techniques., bcz the third has some disadvantages.)
When ever you process any sql query in Oracle, what oracle engine internally does
is, it reads the query and decides which will the best possible way for executing
the
query. So in this process, Oracle follows these optimization techniques.
1. cost based Optimizer(CBO): If a sql query can be executed in 2 different ways
( like may have path 1 and path2 for same query),then What CBO does is, it
basically calculates the cost of each path and the analyses for which path the cost
of execution is less and then executes that path so that it can optimize the quey
execution.
35
2. Rule base optimizer(RBO): this basically follows the rules which are needed for
executing a query. So depending on the number of rules which are to be applied,
the optimzer runs the query.
Use:
If the table you are trying to query is already analysed, then oracle will go with
CBO.
If the table is not analysed , the Oracle follows RBO.
For the first time, if table is not analysed, Oracle will go with full table scan.
137) What will happen if you are using Update Strategy Transformation and your
session is configured for "insert"? What are the types of External Loader available
with Informatica? If you have rank index for top 10. However if you pass only 5
records, what will be the output of such a Rank Transformation?
Ans) if u r using a update strategy in any of ur mapping, then in session
properties u have to set
treat source rows as Data Driven. if u select insert or udate or delete, then the
info server will not
consider UPD for performing any DB operations.
ELSE
u can use the UPD session level options. instead of using a UPD in mapping just
select the
update in treat source rows and update else insert option. this will do the same
job as UPD. but
be sure to have a PK in the target table.
2) for oracle : SQL loader
for teradata:tpump,mload.
3) if u pass only 5 rows to rank, it will rank only the 5 records based on the rank
port.
138) What is aggregate cache in aggregator transforamtion?
Ans) When you run a workflow that uses an Aggregator transformation, the
Informatica Server creates index and data caches in memory to process the
transformation. If the Informatica Server requires more space, it stores overflow
values in cache files.
139) Which transformation should we use to normalize the COBOL and relational
sources?
Ans) The Normalizer transformation normalizes records from COBOL and relational
sources, allowing you to organize the data according to your own needs. A
Normalizer transformation can appear anywhere in a data flow when you normalize
a relational source. Use a Normalizer transformation instead of the Source
Qualifier
transformation when you normalize a COBOL source. When you drag a COBOL
source into the Mapping Designer workspace, the Normalizer transformation
automatically appears, creating input and output ports for every column in the
source
140) What are the measure objects
Ans) Aggregate calculation like sum,avg,max,min these are the measure objetcs.
141) What is DTM process?
Ans) After the loadmanger performs validations for session,it creates the DTM
process.DTM is to create and manage the threads that carry out the session tasks.I
creates the
35
master thread.Master thread creates and manges all the other threads.DTM means
data transformation manager.in informatica this is main back ground process.it run
after complition of load manager.in this process informatica server search source
and tgt connection in repository if it correct then informatica server fetch the
data
from source and load it to target.
142)What are the options in the target session of update strategy transformation?
Ans) Insert
Delete
Update
Update as update
Update as insert
Update esle insert
Truncate table
143) What are the designer tools for creating tranformations?
Ans) Mapping designer
Tansformation developer
Mapplet designer.
144) What is Code Page used for?
Ans) Code Page is used to identify characters that might be in different languages.
If you are importing Japanese data into mapping, you must select the Japanese code
page of source data.
145) Can i start and stop single session in concurent bstch?
Ans) Just right click on the particular session and going to recovery option or by
using event wait and event rise
146) What are the rank caches?
Ans) During the session ,the informatica server compares an inout row with rows in
the datacache.If the input row out-ranks a stored row,the informatica server
replaces the
stored row with the input row.The informatica server stores group information in an
index cache and row data in a data cache.
147) Why and where we are using factless fact table?
Ans) Factless Fact Tables are the fact tables with no facts or measures(numerical
data). It contains only the foriegn keys of corresponding Dimensions. Factless fact
is
used to track the events by using the key values
148) How can you delete duplicate rows with out using Dynamic Lookup? Tell me
any other ways using lookup delete the duplicate rows?
Ans) For example u have a table Emp_Name and it has two columns Fname, Lname
in the source table which has douplicate rows. In the mapping Create Aggregator
transformation. Edit the aggregator transformation select Ports tab select Fname
then click the check box on GroupBy and uncheck the (O) out port. select Lname
then uncheck the (O) out port and click the check box on GroupBy. Then create 2
new ports Uncheck the (I) import then click Expression on each port. In the first
new
35
port Expression type Fname. Then second Newport type Lname. Then close the
aggregator transformation link to the target table.
149) What are the different options used to configure the sequential batches?
Ans) Two options
Run the session only if previous session completes sucessfully. Always runs the
session.
150) How to Generate the Metadata Reports in Informatica?
Ans) You can generate PowerCenter Metadata Reporter from a browser on any
workstation, even a workstation that does not have PowerCenter tools installed.
151) How do we estimate the number of partitons that a mapping really requires?
Is it dependent on the machine configuration?
Ans) It depends upon the informatica version we r using. suppose if we r using
informatica 6 it supports only 32 partitions where as informatica 7 supports 64
partitions.
152) How the informatica server sorts the string values in Ranktransformation?
Ans) When the informatica server runs in the ASCII data movement mode it sorts
session data using Binary sortorder.If you configure the seeion to use a binary
sort
order,the
informatica server caluculates the binary value of each string and returns the
specified number of rows with the higest binary values for the string.
153) How can U create or import flat file definition in to the warehouse designer?
Ans) U can create flat file definition in warehouse designer.in the warehouse
designer,u can create new target: select the type as flat file. save it and u can
enter
various columns for that created target by editing its properties.Once the target
is
created, save it. u can import it from the mapping designer.
154) To provide support for Mainframes source data,which files r used as a source
definitions?
Ans) COBOL Copy-book files
155) Can u copy the session to a different folder or repository?
Ans) In addition, you can copy the workflow from the Repository manager. This will
automatically copy the mapping, associated source,targets and session to the
target folder.Yes it is possible. For copying a session to a folder in the same
repository or to another in a different repository, we can use the repository
manager ( which is client sid etool).Simply by just dragging the session to the
target
destination, the session will be copied.
156) How to get two targets T1 containing distinct values and T2 containing
duplicate values from one source S1.
Ans) Use filter transformation for loading the target with no duplicates. and for
the
other transformation load it directly from source.The above requirement can be
achived
using Lookup transformation in Dynamic mode
157) What is worklet and what use of worklet and in which situation we can use it
35
mapping
session
system
174) Identifying bottlenecks in various components of Informatica and resolving
them.
Ans) The best way to find out bottlenecks is writing to flat file and see where the
bottle neck is .
175) Can we lookup a table from a source qualifer transformation-unconnected
lookup
Ans) No. we can't do.
I will explain you why.
1) Unless you assign the output of the source qualifier to another transformation
or
to target no way it will include the feild in the query.
2) source qualifier don't have any variables feilds to utalize as expression.
176) What r the tasks that Loadmanger process will do?
Ans) Manages the session and batch scheduling: Whe u start the informatica server
the load maneger launches and queries the repository for a list of sessions
configured to run on the informatica server.When u configure the session the
loadmanager maintains list of list of sessions and session start times.When u sart
a
session loadmanger fetches the session information from the repository to perform
the validations and verifications prior to starting DTM process.
Locking and reading the session: When the informatica server starts a session
lodamaager locks the session from the repository.Locking prevents U starting the
session again and again.
Reading the parameter file: If the session uses a parameter files,loadmanager reads
the parameter file and verifies that the session level parematers are declared in
the
file
Verifies permission and privelleges: When the sesson starts load manger checks
whether or not the user have privelleges to run the session.
Creating log files: Loadmanger creates logfile contains the status of session. The
LM
also sends the 'failure mails' in case of failure in execution of the Subsequent
DTM process.
177) How can you stop a batch?
Ans) By using server manager or pmcmd.
178) What is metadata reporter?
Ans) It is a web based application that enables you to run reports againist
repository metadata.
With a meta data reporter,You can access information about U?r repository with out
having knowledge of sql,transformation language or underlying tables in the
repository.
179) Suppose session is configured with commit interval of 10,000 rows and
source has 50,000 rows. Explain the commit points for Source based commit and
Target based commit. Assume appropriate value wherever required.
35
Ans) Source based commit will commit the data into target based on commit
interval.so,for every 10,000 rows it will commit into target.
Target based commit will commit the data into target based on buffer size of the
target.i.e., it commits the data into target when ever the buffer fills.Let us
assume
that the buffer size is 6,000.So,for every 6,000 rows it commits the data.
180) What is the default source option for update stratgey transformation?
Ans) Data driven.
181) Difference between summary filter and details filter?
Ans) Summary Filter --- we can apply records group by that contain common
values.
Detail Filter --- we can apply to each and every record in a database.
182) What are the reusable transforamtions?
Ans) Reusable transformations can be used in multiple mappings.When you need to
incorporate this transformation into maping,U add an instance of it to maping.Later
if you change the definition of the transformation ,all instances of it inherit the
changes.Since the instance of reusable transforamation is a pointer to that
transforamtion,You can change the transforamation in the transformation
developer,its instances automatically reflect these changes.This feature can save
you great deal of work.A reusable Transformation is a reusable metadata object ,
defined with
business logic using single Transformation.
183) What r the types of maping wizards that r to be provided in Informatica?
Ans) Simple Pass through
Slowly Growing Target
Slowly Changing the Dimension
Type1
Most recent values
Type2
Full History
Version
Flag
Date
Type3
Current and one previous
184) After draging the ports of three sources(sql server,oracle,informix) to a
single source qualifier, can u map these three ports directly to target?
Ans) if u drag three hetrogenous sources and populated to target without any join
means you are entertaining Carteisn product. If you don't use join means not only
diffrent sources but homegeous sources are show same error.
If you are not interested to use joins at source qualifier level u can add some
joins
sepratly. In Source qualifier we can join the tables from same database only.
185) What is difference between partioning of relatonal target and partitioning of
file targets?
35
the Target.
Source (100 rows) ---> Passive Transformation ---> Target (100 rows)
Union Transformation:Here Union Transformation acts like a UnionAll in SQl.i.e.,it
wil
also include duplicates while concatinating two tables.bt,we were provided with a
option to eliminate duplicates also..dats y it's become as an active transformation
191) How to get the first 100 rows from the flat file into the target?
Ans) 1. Use test download option if you want to use it for testing.
2. Put counter/sequence generator in mapping and perform it. Its simple.take a
filter
drag all ports from source qualifier to filter. in filter write the condition
columname<101 and
drag ports to the target
192) What is meant by complex mapping
Ans) Complex maping means involved in more logic and more business rules.
Actually in my project complex mapping is
In my bank project, I involved in construct a 1 dataware house
Meny customer is there in my bank project, They r after taking loans relocated in
to
another place
that time i feel to diffcult maintain both prvious and current adresses
in the sense i am using scd2
This is an simple example of complex mapping
193) Can you start a session inside a batch idividually?
Ans) We can start our required session only in case of sequential batch.in case of
concurrent batch we cant do like this.
194) Can we use aggregator/active transformation after update strategy
transformation
Ans) You can use aggregator after update strategy. The problem will be, once you
perform the update strategy, say you had flagged some rows to be deleted and you
had performed aggregator transformation for all rows, say you are using SUM
function, then the deleted rows will be subtracted from this aggregator
transformation.
195) Can you copy the batches?
Ans) NO.
196) Explain the informatica Architecture in detail
Ans) informatica server connects source data and target data using native
odbc drivers
again it connect to the repository for running sessions and retriveing metadata
information
source------>informatica server--------->target
REPOSITORY
The PowerCenter Server is a repository client application. It connects to the
Repository Server and Repository Agent to retrieve workflow and mapping
metadata from the repository database. When the PowerCenter Server requests a
repository connection from the Repository Server, the Repository Server starts and
35
manages the Repository Agent. The Repository Server then re-directs the
PowerCenter Server to connect directly to the Repository Agent.
197) What is Load Manager?
Ans) The load Manager is the Primary Informatica Server Process. It performs the
following tasks:-
Manages session and batch scheduling.
Locks the session and read session properties.
Reads the parameter file.
Expand the server and session variables and parameters.
Verify permissions and privileges.
Validate source and target code pages.
Create the session log file.
Create the Data Transformation Manager which execute the session.
198) In which circumstances that informatica server creates Reject files?
Ans) When it encounters the DD_Reject in update strategy transformation.
Violates database constraint
Filed in the rows was truncated or overflowed.
199) Describe two levels in which update strategy transformation sets?
Ans) Within a session: When you configure a session, yoYou can instruct the
Informatica Server to either treat all records in the same way (for example, treat
all
records as inserts), or use instructions coded into the session mapping to flag
records for different database operations.
Within a mapping: Within a mapping, you use the Update Strategy transformation to
flag records for insert, delete, update, or reject.
200) Can U use the maping parameters or variables created in one maping into
another maping?
Ans) NO. You might want to use a workflow parameter/variable if you want it to be
visible with other mappings/sessions
201) What is Partitioning ? where we can use Partition? wht is advantages?Is it
nessisary?
Ans) Partitions are used to optimize the session performance
we can select in sesstion propetys for partiotions
types
default----passthrough partition
key range partion
round robin partion
hash partiotion
202) In realtime which one is better star schema or snowflake star schema the
surrogate will be linked to which columns in the dimension table.
Ans) In real time only star schema will implement because it will take less time
and
surrogate key will there in each and every dimension table in star schema and this
surrogate key will assign as foreign key in fact table.
203) What is the exact meaning of domain?
35
Ans) Itz possible to join the two or more tables by using source qualifier.But
provided the tables should have relationship.
When u drag n drop the tables u will getting the source qualifier for each
table.Delete all the source qualifiers.Add a common source qualifier for all.Right
click on the source qualifier u will find EDIT click on it.Click on the properties
tab,u
will find sql query in that u can write ur sqls. You can also do it using
Session --- mapping---source--- there you have an option called User Defined Join
there you can
write your SQL
228) When we create a target as flat file and source as oracle.. how can i specify
first rows as column names in flat files...
Ans) Use a pre sql statement....but this is a hardcoding method...if you change the
column names or put in extra columns in the flat file, you will have to change the
insert statement
229) What happens if you try to create a shortcut to a non-shared folder?
Ans) It only creates a copy of it..
230) Explain about Recovering sessions?
Ans) If you stop a session or if an error causes a session to stop, refer to the
session
and error logs to determine the cause of failure. Correct the errors, and then
complete the
session. The method you use to complete the session depends on the properties of
the mapping, session, and Informatica Server configuration.
Use one of the following methods to complete the session:
? Run the session again if the Informatica Server has not issued a commit.
? Truncate the target tables and run the session again if the session is not
recoverable.
? Consider performing recovery if the Informatica Server has issued at least one
commit.
231) Can Informatica load heterogeneous targets from heterogeneous sources?
Ans) Yes it can. For example...Flat File and Relations sources are joined in the
mapping, and later, Flat File and relational targets are loaded.
232) While running multiple session in parallel which loads data in the same table,
throughput of each session becomes very less and almost same for each session.
How can we improve the performance (throughput) in such cases?
Ans) I think this will be handled by the database we use.
When the operations/loading on the table is in progress the table will be locked.
If we are trying to load the same table with different partitions then we run into
rowID erros if the database is 9i and we can apply a patch to reslove this issue
233) What is data merging, data cleansing, sampling?
Ans) Cleansing:---TO identify and remove the retundacy and inconsistency
sampling: just smaple the data throug send the data from source to target
Data merging: It is a process of combining the data with similar structures in to a
single output.
Data Cleansing: It is a process of identifying and rectifying the inconsistent and
inaccurate data
35
240) Can any one tell me how to run scd1 bec it create two target tables in
mapping window and there are only one table in warehouse designer(means
target).. so if we create one new table in target it gives error..
Ans) If so, create the target with the name u have given in wizard for
target(table).
No't create the target again for the second instance. It is just the virtual copy
of the
same target. i.e in warehouse designer create and execute the target definitions
and run the session containing the mapping again.define the source& target
locations in general properties of sessiontreat rows as: Data DrivenCheck this once
and let me know
241) i have source like 1;2:3.4 its flatfile. now i want in my target table as 1 2
3 4
plz can any one explain me the procedure how to get output like dat
Ans) No answer available currently. Be the first one to reply to this question by
submitting your answer from the form below.
242) In a sequential batch can you run the session if previous session fails?
Ans) Yes.By setting the option always runs the session.
243) In a filter expression we want to compare one date field with a db2 system
field CURRENT DATE. Our Syntax: datefield = CURRENT DATE (we didn't define it
by ports, its a system field ), but this is not valid (PMParser: Missing
Operator)..
Ans) The db2 date formate is "yyyymmdd" where as sysdate in oracle will give "ddmm-
yy" so conversion of db2 date formate to local database date formate is
compulsary. other wise u will get that type of error
244) How do you transfert the data from data warehouse to flatfile?
Ans) You can write a mapping with the flat file as a target using a
DUMMY_CONNECTION. A flat file target is built by pulling a source into target space
using Warehouse Designer tool.
245) What is the Rank index in Rank transformation?
Ans) Based on which port you want generate Rank is known as rank port, the
generated values are known as rank index.
246) Define Informatica Repository?
Ans) The Informatica repository is a relational database that stores information,
or
metadata, used by the Informatica Server and Client tools. Metadata can include
information
such as mappings describing how to transform source data, sessions indicating
when you want the Informatica Server to perform the transformations, and connect
strings
for sources and targets.
The repository also stores administrative information such as usernames and
passwords, permissions and privileges, and product version.
Use repository manager to create the repository.The Repository Manager connects
to the repository database and runs the code needed to create the repository
tables.Thsea tables
stores metadata in specific format the informatica server,client tools use.
247) What is change data capture?
35
Ans) Change data capture (CDC) is a set of software design patterns used to
determine the data that has changed in a database so that action can be taken
using the changed data.
248) Can any body write a session parameter file which will change the source
and targets for every session. i.e different source and targets for each session
run.
Ans) You are supposed to define a parameter file. And then in the Parameter file,
you can define two parameters, one for source and one for target.
Give like this for example:
$Src_file = c:program filesinformaticaserverinabc_source.txt
$tgt_file = c: argetsabc_targets.txt
Then go and define the parameter file:
[folder_name.WF:workflow_name.ST:s_session_name]
$Src_file =c:program filesinformaticaserverinabc_source.txt
$tgt_file = c: argetsabc_targets.txt
If its a relational db, you can even give an overridden sql at the session
level...as a
parameter. Make sure the sql is in a single line.
249) What is meant by Junk Attribute in Informatica?
Ans) Junk Dimension A Dimension is called junk dimension if it contains attribute
which are rarely changed ormodified. example In Banking Domain , we can fetch
four attributes accounting to a junk dimensions like from the
Overall_Transaction_master table tput flag tcmp flag del flag advance flag all
these
attributes can be a part of a junk dimensions.Grouping of random flags and text
attributes
in a dimension and moving them to a separate dimension is called as junk dimension
250) What are partition points?
Ans) Partition points mark the thread boundaries in a source pipeline and divide
the pipeline into stages.Partition points mark the thread boundaries in a pipeline
and
divide the pipeline into stages. The Informatica Server sets partition points at
several
transformations in a pipeline by default. If you use PowerCenter, you can define
other partition
points. When you add partition points, you increase the number of transformation
threads,
which can improve session performance. The Informatica Server can redistribute
rows of data at partition points, which can also improve session performance.
251) Where should U place the flat file to import the flat file defintion to the
designer?
Ans) There is no such restrication to place the source file. In performance point
of
view its better to place the file in server local src folder. if you need path
please
check the server properties availble at workflow manager.
It doesn't mean we should not place in any other folder, if we place in server src
folder by default src will be selected at time session creation.
252) I have flatfile it contains 'n' number of records. i need to load half of the
records to one target table another half to another target table. plz any one can
explain me the procedure.
35
Start value = Current value ( when the session starts the execution of the
undelying
mapping)
Start value <> Current value ( while the session is in progress and the variable
value changes in one ore more occasions)
Current value at the end of the session is nothing but the start value for the
subsequent run of the same session.
257) In certain mapping there are four targets tg1,tg2,tg3 and tg4. tg1 has a
primary key,tg2 foreign key referencing the tg1's primary key,tg3 has primary key
that tg2 and tg4 refers as foreign key,tg2 has foreign key referencing primary key
of tg4 ,the order in which the informatica will load the target? 2]How can I detect
aggregate tranformation causing low performance?
Ans) To optimize the aggregator transformation, you can use the following options.
Use incremental aggregation
Sort the ports before you perform aggregation
Avoid using aggregator transformation after update strategy, since it might be
confusing.
Answer for the second query:
To get performance details for any aggregator transformation, we have to check some
parameters
in the .perf file named as Transformationname_writetodisk and
Transformationname_readfromdisk. If these two counters provide values which are not
zero then
we have to tune the aggregator transformation. The ways in which the aggregator
transformation
can be tuned:
1. Using incremental aggregation
2. By increasing the DATA cache and index cache sizes
3. Using a sorter transformation before the aggregator transformation
258) How many number of sessions that You can create in a batch?
Ans) Any number of sessions.It depends on the config settings of informatica
server. The
parameters for the maximum connections cant be exceeded. It depends on the overall
sessions
running per the server at a time. For eg, if the number of connxns rt now is 300
and if u have
batches running with 290+ sessions at a time, adding 15 more sessions to the time
frame will
cause the loads to fail
259) Compare Data Warehousing Top-Down approach with Bottom-up approach
Ans) Top down
ODS-->ETL-->Datawarehouse-->Datamart-->OLAP
Bottom up
ODS-->ETL-->Datamart-->Datawarehouse-->OLAP
260) What r the methods for creating reusable transforamtions?
Ans) You can design using 2 methods
using transformation developer
create normal one and promote it to reusable
261) How to export mappings to the production environment?
Ans) In the designer go to the main menu and one can see the export/import
options.
Import the exported mapping in to the production repository with replace
35
options.You will have to export as xml format using export option and then import
in
production environment.
262) where do we use MQ series source qualifier, application multi group source
qualifier. just give an example for a better understanding
Ans) We can use a MQSeries SQ when we have a MQ messaging system as
source(queue).
When there is need to extract data from a Queue, which will basically have
messages in XML format, we will use a JMS or a MQ SQ depending on the messaging
system. If you have a TIBCO EMS Queue, use a JMS source and JMS SQ and an XML
Parser, or if you have a MQ series queue, then use a MQ SQ which will be associated
with a Flat file or a Cobal file.
263) How do we estimate the depth of the session scheduling queue? Where do
we set the number of maximum concurrent sessions that Informatica can run at a
given time?
Ans) u set the max no of concurrent sessions in the info server.by default its 10.
u
can set to any no.
264) Discuss which is better among incremental load, Normal Load and Bulk load
Ans) It depends on the requirement. Otherwise Incremental load which can be
better as it takes onle that data which is not available previously on the target.
According to performence bulk is better than normal.
But bolh having some conditions in source data
Conditions are like
1)does not containn any constraint in data.
2)dont use the double datatype if neccesory to use then use it as last row of the
table.
3)it does not support the CHECK CONSTRAINT.
265) what is the best way to show metadata(number of rows at source, target and
each transformation level, error related data) in a report format
Ans) You can select these details from the repository table. you can use the view
REP_SESS_LOG to get these data
266) When the informatica server marks that a batch is failed?
Ans) If one of session is configured to "run if previous completes" and that
previous
session fails.
267) Which tool you use to create and manage sessions and batches and to
monitor and stop the informatica server?
Ans) Informatica Server Manager.Its the Integration Service in 8.x
268) What is the hierarchies in DWH
Ans) Data sources ---> Data acquisition ---> Warehouse ---> Front end tools --->
Metadata management ---> Data warehouse operation management
269) How can we store previous session logs
Ans) Just run the session in time stamp mode then automatically session log will
not
overwrite current session log.
35
270) my source is having 1000 rows. i have brought 300 records into my ODS. so
next time i want to load the remaining records. so i need to load from 301 th
record. when ever i start the work flow again it will load from the begining. how
do we solve this problem.
Ans) By using Sequence GeneratorTransformation u can do it
ie by chaging the RESET option in the properties tab of your
SequenceGeneratorTransformation.
then it will workwe can also use recover task so that ,when data is extracting
because of any problem while loading data if it's stop's loading at middle using
recover task we can get the records from where it's stoped previously.....
271) What is Dimension table Exactly?
Ans) Dimension tables gives description about something.
for eg. If we take Student as a dimention table, we have various attributes like
college name, age, gender,etc which gives some description about a student.
272) What are the different threads in DTM process?
Ans) Master thread: Creates and manages all other threads
Maping thread: One maping thread will be creates for each session.Fectchs session
and maping information.
Pre and post session threads: This will be created to perform pre and post session
operations.
Reader thread: One thread will be created for each partition of a source.It reads
data from source.
Writer thread: It will be created to load data to the target.
Transformation thread: It will be created to tranform data.
273) What is a junk dimension
Ans) A "junk" dimension is a collection of random transactional codes, flags and/or
text attributes that are unrelated to any particular dimension. The junk dimension
is
simply a structure that provides a convenient place to store the junk attributes. A
good example would be a trade fact in a company that brokers equity trades.
274) What r the circumstances that infromatica server results an unreciverable
session?
Ans) The source qualifier transformation does not use sorted ports.
If u change the partition information after the initial session fails.
Perform recovery is disabled in the informatica server configuration.
If the sources or targets changes after initial session fails.
If the maping consists of sequence generator or normalizer transformation.
If a concuurent batche contains multiple failed sessions.
275) How does the server recognise the source and target databases?
Ans) By using ODBC connection.if it is relational.if is flat file FTP
connection..see we
can make sure with connection in the properties of session both sources && targets.
276) Whats the diff between Informatica powercenter server, repositoryserver
and repository?
Ans) By using ODBC connection.if it is relational.if is flat file FTP
connection..see we
can make sure with connection in the properties of session both sources && targets.
35
277) About Informatica Power center 7: 1) I want to Know which mapping
properties can be overridden on a Session Task level. 2)Know what types of
permissions are needed to run and schedule Work flows.
Ans) 1.(Ans) You can override any properties other than the source and targets.
Make sure the source and targets exists in ur db if it is a relational db. If it is
a flat
file, you can override its properties. You can override sql if its a relational db,
session log, DTM buffer size, cache sizes etc.
2.(Ans) You need execute permissions on the folder to run/schedule a workflow. You
may have read and write. But u need execute permissions as well.
278) Two relational tables are connected to SQ Trans,what are the possible errors
it will be thrown?
Ans) The only two possibilities as of I know is
Both the table should have primary key/foreign key relation ship
Both the table should be available in the same schema or same database
279) What r the options in the target session of update strategy transsformatioin?
Ans) Update as Insert:
This option specified all the update records from source to be flagged as inserts
in
the target. In other words, instead of updating the records in the target they are
inserted as new records.
Update else Insert:
This option enables informatica to flag the records either for update if they are
old
or insert, if they are new records from source.
insert,update,delete,insert as update,update else insert.update as update.
280) Why we use partitioning the session in informatica?
Ans) Performance can be improved by processing data in parallel in a single session
by creating multiple partitions of the pipeline.
Informatica server can achieve high performance by partitioning the pipleline and
performing the extract , transformation, and load for each partition in parallel.
281) I have a source column data with names like ravi kumar.i want to insert the
ravi in one column and kumar in another coliumn of target table.how do u
implement in informatica?
Ans) i can able to give solution for this Question , in Exp Transformation using
syntax of "substr" and "instr". use the syntax of this to identity the string when
source is having multiple string. i have given that Syntax below:
SUBSTR(char as char, m as numeric, [n as numeric])
//Returns n characters of char, beginning at character m.
INSTR(char1 as char, char2 as char, [n as integer, [m as integer, [comparisonType
as integer]]])
//Searches char1 beginning with its nth character for the mth occurance of char2
and returns the position of the character in char1 that is the first character of
this
occurrence. Linguistic comparison is done when comparisonType is 0 and binary
comparison is done when comparisonType is any non-zero value. By default
comparisonType is 0 i.e.linguistic comparison
and use the link to get how achieved that Q in the below Link which contain
Source,Target code,mapping.
35
282) DOubts regarding rank transformation: CAn we do ranking using two ports?
can we rank all the rows coming from source, how?
Ans) Rank port. Use to designate the column for which you want to rank values. You
can designate only one Rank port in a Rank transformation. The Rank port is an
input/output port. You must link the Rank port to another transformation.
So you can not use two ports for ranking in the rank transformation.
Note:you can achieve this question using Aggregate and Expression transformation.
283) what is the diff b/w rowid and row? 2.diff b/w rowid and row number?
Ans) Every row is identified by a rowid. ROWID is pseudo column in every table. The
physical address of the rows is use to for the ROWID.IN HEXADECIMAL
representation, ROWID is shown as 18 character string of the following format
BBBBBBBBB.RRRR.FFFF (block,row,file)
And row is a piece of record or simple a record.
----------------------------------------------------
248036211-129775529-Informatica-Scenario-Based-Interview-Questions-With-Answers-
1.pdf
-----------------------------------------------------------
143365737-Informatica-Scenarios.pdf
Q1) I have a flat file, want to reverse the contents of the flat file which means
the first record should come as last record and last record should come as first
record and load into the target file. As an example consider the source flat file
data as Informatica Enterprise Solution Informatica Power center Informatica Power
exchange Informatica Data quality
The target flat file data should look as Informatica Data quality Informatica Power
exchange Informatica Power center Informatica Enterprise Solution
Solution: Follow the below steps for creating the mapping logic
Create a new mapping.
Drag the flat file source into the mapping.
Create an expression transformation and drag the ports of source qualifier
transformation into the expression transformation.
Create the below additional ports in the expression transformation and assign the
corresponding expressions
Variable port: v_count = v_count+1 Output port o_count = v_count
Now create a sorter transformation and drag the ports of expression
transformation into it.
In the sorter transformation specify the sort key as o_count and sort order as
DESCENDING.
Drag the target definition into the mapping and connect the ports of sorter
transformation to the target.
Q2) Load the header record of the flat file into first target, footer record into
second target and the remaining records into the third target. The solution to this
problem I have already posted by using aggregator and joiner. Now we will see how
to implement this by reversing the contents of the file. Solution:
Connect the source qualifier transformation to the expression transformation. In
the expression transformation create the additional ports as mentioned above.
Connect the expression transformation to a router. In the router transformation
create an output group and specify the group condition as o_count=1. Connect this
output group to a target and the default group to sorter transformation.
Sort the data in descending order on o_count port.
Connect the output of sorter transformation to expression transformation (don’t
connect o_count port).
Again in the expression transformation create the same additional ports mentioned
above.
Connect this expression transformation to router and create an output group. In
the output group specify the condition as o_count=1 and connect this group to
second target. Connect the default group to the third group.
*********
INFORMATICA SCENARIO BASED INTERVIEW QUESTIONS WITH ANSWERS - PART 1
1. How to generate sequence numbers using expression transformation? Solution: In
the expression transformation, create a variable port and increment it by 1. Then
assign the variable port to an output port. In the expression transformation, the
ports are: V_count=V_count+1 O_count=V_count 2. Design a mapping to load the first
3 rows from a flat file into a target? Solution: You have to assign row numbers to
each record. Generate the row numbers either using the expression transformation as
mentioned above or use sequence generator transformation. Then pass the output to
filter transformation and specify the filter condition as O_count <=3 3. Design a
mapping to load the last 3 rows from a flat file into a target? Solution: Consider
the source has the following data. col a b c d e Step1: You have to assign row
numbers to each record. Generate the row numbers using the expression
transformation as mentioned above and call the row number generated port as
O_count.
Create a DUMMY output port in the same expression transformation and assign 1 to
that port. So that, the DUMMY output port always return 1 for each row. In the
expression transformation, the ports are V_count=V_count+1 O_count=V_count
O_dummy=1 The output of expression transformation will be col, o_count, o_dummy a,
1, 1 b, 2, 1 c, 3, 1 d, 4, 1 e, 5, 1 Step2: Pass the output of expression
transformation to aggregator and do not specify any group by condition. Create an
output port O_total_records in the aggregator and assign O_count port to it. The
aggregator will return the last row by default. The output of aggregator contains
the DUMMY port which has value 1 and O_total_records port which has the value of
total number of records in the source. In the aggregator transformation, the ports
are O_dummy O_count O_total_records=O_count The output of aggregator transformation
will be O_total_records, O_dummy 5, 1 Step3: Pass the output of expression
transformation, aggregator transformation to joiner transformation and join on the
DUMMY port. In the joiner transformation check the property sorted input, then only
you can connect both expression and aggregator to joiner transformation. In the
joiner transformation, the join condition will be O_dummy (port from aggregator
transformation) = O_dummy (port from expression transformation) The output of
joiner transformation will be col, o_count, o_total_records a, 1, 5 b, 2, 5 c, 3, 5
d, 4, 5 e, 5, 5 Step4: Now pass the ouput of joiner transformation to filter
transformation and specify the filter condition as O_total_records (port from
aggregator)-O_count(port from expression) <=2 In the filter transformation, the
filter condition will be O_total_records - O_count <=2 The output of filter
transformation will be
col o_count, o_total_records c, 3, 5 d, 4, 5 e, 5, 5
INFORMATICA SCENARIO BASED INTERVIEW QUESTIONS WITH ANSWERS - PART 1
1. How to generate sequence numbers using expression transformation? Solution: In
the expression transformation, create a variable port and increment it by 1. Then
assign the variable port to an output port. In the expression transformation, the
ports are: V_count=V_count+1 O_count=V_count 2. Design a mapping to load the first
3 rows from a flat file into a target? Solution: You have to assign row numbers to
each record. Generate the row numbers either using the expression transformation as
mentioned above or use sequence generator transformation. Then pass the output to
filter transformation and specify the filter condition as O_count <=3 3. Design a
mapping to load the last 3 rows from a flat file into a target? Solution: Consider
the source has the following data. col a b c d e Step1: You have to assign row
numbers to each record. Generate the row numbers using the expression
transformation as mentioned above and call the row number generated port as
O_count. Create a DUMMY output port in the same expression transformation and
assign 1 to that port. So that, the DUMMY output port always return 1 for each row.
In the expression transformation, the ports are V_count=V_count+1 O_count=V_count
O_dummy=1 The output of expression transformation will be col, o_count, o_dummy a,
1, 1 b, 2, 1 c, 3, 1 d, 4, 1 e, 5, 1 Step2: Pass the output of expression
transformation to aggregator and do not specify any group by condition. Create an
output port O_total_records in the aggregator and assign O_count port to it. The
aggregator will return the last row by default. The output of aggregator contains
the DUMMY
port which has value 1 and O_total_records port which has the value of total number
of records in the source. In the aggregator transformation, the ports are O_dummy
O_count O_total_records=O_count The output of aggregator transformation will be
O_total_records, O_dummy 5, 1 Step3: Pass the output of expression transformation,
aggregator transformation to joiner transformation and join on the DUMMY port. In
the joiner transformation check the property sorted input, then only you can
connect both expression and aggregator to joiner transformation. In the joiner
transformation, the join condition will be O_dummy (port from aggregator
transformation) = O_dummy (port from expression transformation) The output of
joiner transformation will be col, o_count, o_total_records a, 1, 5 b, 2, 5 c, 3, 5
d, 4, 5 e, 5, 5 Step4: Now pass the ouput of joiner transformation to filter
transformation and specify the filter condition as O_total_records (port from
aggregator)-O_count(port from expression) <=2 In the filter transformation, the
filter condition will be O_total_records - O_count <=2 The output of filter
transformation will be col o_count, o_total_records c, 3, 5 d, 4, 5 e, 5, 5 4.
Design a mapping to load the first record from a flat file into one table A, the
last record from a flat file into table B and the remaining records into table C?
Solution: This is similar to the above problem; the first 3 steps are same. In the
last step instead of using the filter transformation, you have to use router
transformation. In the router transformation create two output groups. In the first
group, the condition should be O_count=1 and connect the corresponding output group
to table A. In the second group, the condition should be O_count=O_total_records
and connect the corresponding output group to table B. The output of default group
should be connected to table C. 5. Consider the following products data which
contain duplicate rows. A
B C C B D B Q1. Design a mapping to load all unique products in one table and the
duplicate rows in another table. The first table should contain the following
output A D The second target should contain the following output B B B C C
Solution: Use sorter transformation and sort the products data. Pass the output to
an expression transformation and create a dummy port O_dummy and assign 1 to that
port. So that, the DUMMY output port always return 1 for each row. The output of
expression transformation will be Product, O_dummy A, 1 B, 1 B, 1 B, 1 C, 1 C, 1 D,
1 Pass the output of expression transformation to an aggregator transformation.
Check the group by on product port. In the aggreagtor, create an output port
O_count_of_each_product and write an expression count(product). The output of
aggregator will be Product, O_count_of_each_product A, 1 B, 3 C, 2 D, 1 Now pass
the output of expression transformation, aggregator transformation to joiner
transformation and join on the products port. In the joiner transformation check
the property sorted input, then only you can connect both expression and aggregator
to joiner transformation. The output of joiner will be product, O_dummy,
O_count_of_each_product A, 1, 1
B, 1, 3 B, 1, 3 B, 1, 3 C, 1, 2 C, 1, 2 D, 1, 1 Now pass the output of joiner to a
router transformation, create one group and specify the group condition as
O_dummy=O_count_of_each_product. Then connect this group to one table. Connect the
output of default group to another table. Q2. Design a mapping to load each product
once into one table and the remaining products which are duplicated into another
table. The first table should contain the following output A B C D The second table
should contain the following output B B C Solution: Use sorter transformation and
sort the products data. Pass the output to an expression transformation and create
a variable port,V_curr_product, and assign product port to it. Then create a
V_count port and in the expression editor write IIF(V_curr_product=V_prev_product,
V_count+1,1). Create one more variable port V_prev_port and assign product port to
it. Now create an output port O_count port and assign V_count port to it. In the
expression transformation, the ports are Product V_curr_product=product
V_count=IIF(V_curr_product=V_prev_product,V_count+1,1) V_prev_product=product
O_count=V_count The output of expression transformation will be Product, O_count A,
1 B, 1 B, 2 B, 3 C, 1 C, 2 D, 1 Now Pass the output of expression transformation to
a router transformation, create one group and specify the condition as O_count=1.
Then connect this group to one table. Connect the output of default group to
another table.
1. Consider the following employees data as source employee_id, salary 10, 1000 20,
2000 30, 3000 40, 5000 Q1. Design a mapping to load the cumulative sum of salaries
of employees into target table? The target table data should look like as
employee_id, salary, cumulative_sum 10, 1000, 1000 20, 2000, 3000 30, 3000, 6000
40, 5000, 11000 Solution: Connect the source Qualifier to expression
transformation. In the expression transformation, create a variable port V_cum_sal
and in the expression editor write V_cum_sal+salary. Create an output port
O_cum_sal and assign V_cum_sal to it. Q2. Design a mapping to get the pervious row
salary for the current row. If there is no pervious row exists for the current row,
then the pervious row salary should be displayed as null. The output should look
like as employee_id, salary, pre_row_salary 10, 1000, Null 20, 2000, 1000 30, 3000,
2000 40, 5000, 3000 Solution: Connect the source Qualifier to expression
transformation. In the expression transformation, create a variable port V_count
and increment it by one for each row entering the expression transformation. Also
create V_salary variable port and assign the expression
IIF(V_count=1,NULL,V_prev_salary) to it . Then create one more variable port
V_prev_salary and assign Salary to it. Now create output port O_prev_salary and
assign V_salary to it. Connect the expression transformation to the target ports.
In the expression transformation, the ports will be employee_id
salary V_count=V_count+1 V_salary=IIF(V_count=1,NULL,V_prev_salary)
V_prev_salary=salary O_prev_salary=V_salary Q3. Design a mapping to get the next
row salary for the current row. If there is no next row for the current row, then
the next row salary should be displayed as null. The output should look like as
employee_id, salary, next_row_salary 10, 1000, 2000 20, 2000, 3000 30, 3000, 5000
40, 5000, Null Solution: Step1: Connect the source qualifier to two expression
transformation. In each expression transformation, create a variable port V_count
and in the expression editor write V_count+1. Now create an output port O_count in
each expression transformation. In the first expression transformation, assign
V_count to O_count. In the second expression transformation assign V_count-1 to
O_count. In the first expression transformation, the ports will be employee_id
salary V_count=V_count+1 O_count=V_count In the second expression transformation,
the ports will be employee_id salary V_count=V_count+1 O_count=V_count-1 Step2:
Connect both the expression transformations to joiner transformation and join them
on the port O_count. Consider the first expression transformation as Master and
second one as detail. In the joiner specify the join type as Detail Outer Join. In
the joiner transformation check the property sorted input, then only you can
connect both expression transformations to joiner transformation. Step3: Pass the
output of joiner transformation to a target table. From the joiner, connect the
employee_id, salary which are obtained from the first expression transformation to
the employee_id,
salary ports in target table. Then from the joiner, connect the salary which is
obtained from the second expression transformaiton to the next_row_salary port in
the target table. Q4. Design a mapping to find the sum of salaries of all employees
and this sum should repeat for all the rows. The output should look like as
employee_id, salary, salary_sum 10, 1000, 11000 20, 2000, 11000 30, 3000, 11000 40,
5000, 11000 Solution: Step1: Connect the source qualifier to the expression
transformation. In the expression transformation, create a dummy port and assign
value 1 to it. In the expression transformation, the ports will be employee_id
salary O_dummy=1 Step2: Pass the output of expression transformation to aggregator.
Create a new port O_sum_salary and in the expression editor write SUM(salary). Do
not specify group by on any port. In the aggregator transformation, the ports will
be salary O_dummy O_sum_salary=SUM(salary) Step3: Pass the output of expression
transformation, aggregator transformation to joiner transformation and join on the
DUMMY port. In the joiner transformation check the property sorted input, then only
you can connect both expression and aggregator to joiner transformation. Step4:
Pass the output of joiner to the target table. 2. Consider the following employees
table as source department_no, employee_name 20, R 10, A
10, D 20, P 10, B 10, C 20, Q 20, S Q1. Design a mapping to load a target table
with the following values from the above source? department_no, employee_list 10, A
10, A,B 10, A,B,C 10, A,B,C,D 20, A,B,C,D,P 20, A,B,C,D,P,Q 20, A,B,C,D,P,Q,R 20,
A,B,C,D,P,Q,R,S Solution: Step1: Use a sorter transformation and sort the data
using the sort key as department_no and then pass the output to the expression
transformation. In the expression transformation, the ports will be department_no
employee_name V_employee_list =
IIF(ISNULL(V_employee_list),employee_name,V_employee_list||','||employee_name)
O_employee_list = V_employee_list Step2: Now connect the expression transformation
to a target table. Q2. Design a mapping to load a target table with the following
values from the above source? department_no, employee_list 10, A 10, A,B 10, A,B,C
10, A,B,C,D 20, P 20, P,Q 20, P,Q,R 20, P,Q,R,S
Solution: Step1: Use a sorter transformation and sort the data using the sort key
as department_no and then pass the output to the expression transformation. In the
expression transformation, the ports will be department_no employee_name
V_curr_deptno=department_no V_employee_list = IIF(V_curr_deptno! =
V_prev_deptno,employee_name,V_employee_list||','||employee_name)
V_prev_deptno=department_no O_employee_list = V_employee_list Step2: Now connect
the expression transformation to a target table. Q3. Design a mapping to load a
target table with the following values from the above source? department_no,
employee_names 10, A,B,C,D 20, P,Q,R,S Solution: The first step is same as the
above problem. Pass the output of expression to an aggregator transformation and
specify the group by as department_no. Now connect the aggregator transformation to
a target table.
-----------------------------------------------------------
51975127-Excelent-scenarios-and-faq-s-of-informatica.pdf
-------------------------------------------------------------------------
37597739-28531326-Informatica-Senarios-1.pdf
A:-In expression transformation use an output port ...in expression window write
emp_id||empname
2. How to join a Flat and Relational Source without using (Joiner, Update, Lookup)
transformations... is it possible? If yes i would like to know how?
A:- not possible
3. I have a source which relational, I am trying to populate to target flat file
with one
column for daily date which is sysdate, I want to populate the sysdate coulmn with
DD/MM/YYYY format. Kindly provide a solution for this. My clear that my target is
flat
file.
A: - In expression transformation create one out put port, and write like:
TO_DATE ('SYSDATE'.'DD/MM/YYYY').Connect this port to target.
4. If the source has duplicate records as id and name columns, values: 1 a, 1 b, 1
c,
2 a, 2 b, the target should be loaded as 1 a+b+c or 1 a||b||c, what transformations
should be used for this?
A: - We need to use sorter, Expression and aggregator transformations to do this…..
1. Sort by ID
2.Take 2 variable ports one for id and one for name and store the values of id and
keep
on comparing with current id i.e. variable is having previous id so if previous
id=current id
then (variable name)||name otherwise only name. Assign the variable name to output
port
3. Use aggregator and use last or max (len (name)) to get the result.
5. How many repositories can you create in informatica?
A-In Informatica 8.6.0 multiple repositories can be created under node. The domain
can
have multiple nodes.
6. Router T/R is active but some people are saying some times passive what is
Reason behind that?
A: - First of all Every Active transformation is a Passive transformation, But
every passive
not
Active.
In Router Transformation there is a special feature with Default group. Because of
Default
Group its passive. We can avoid this Default group by some transformation Settings,
Now
It’s Active.
7. I want to run an informatica workflow after completion of oracle procedure. That
Procedure is not running through informatica and can be run at any Time in
Database. Informatica is in windows environment. Is it possible? If yes please
Explain?
A: - This can be possible with UNIX. Create a shell scripts which first has to
Execute the
Stored procedure or Package and we have command to check the completion or
procedure
After that use Pmcmd command in the same UNIX to start the workflow.
Informatica Senarios-2
8. in a single mapping, more than 500 sources (legacy, VSAM, relational) will be
loading into only one target. Whenever I retrieve the data (any record) from
target, I
need to find the details that the record belongs to which source?
A: - After every Source qualifier transformation just keep an Expression with
flag.Dont go
Single Source qualifier transformation. Keep 1 source qualifier Trans for one
table.
9. Diff b/w Shortcut and reusable Object?
A: - A shortcut is created by assigning 'Shared' status to a folder within the
Repository
Manager and then dragging objects from this folder into another open folder
10. What is 'Power Center Pushdown Optimization Option' in INFORMATICA?(IMP)
A: - Pushdown optimization is used to push the complex logic to the database level.
This
will
Reduce the complexity of the Power center mappings and increases the performance.
11. If no. of source columns is changing every time (First time it is 10 next time
it is
20 so on). How to deal with it without changing mapping?
A: - If I understand this question properly, it says that the no. of "Source"
columns are
changing. I do not agree with this scenario. Probably in Data warehousing, you
won't find
such a design. As far as DWH is concerned, it takes the data from the OLTP systems
&
after performing some operations (E-extract, T- transform) it finally loads the
data in some
targets. Here, as per the question, the question itself arises for the OLTP design.
No any
OLTP (or database design principal) system suggests a varying number of columns.
So,
please do not get confused by such trivial kind of questions.DWH is a much
disciplined
subject & it follows a very good standards. Please go through the concepts first.
You will
get a clear picture of DWH then.
12. "Change cache" in Informatica?
A: - dynamic cache
`
13. Can we create index and drop index in existing table while using informatica?
A: - I know 4 ways in INFORMATICA
1) Source Analyzer window- (source table, Using key ports (enable, disable)).
2) Source qualifier Trans-(Sql override)
3) Target override
4) Pre sql, Post sql
14. If we are using an aggregator but forget to mention the group by port .what
will
be the Output?
A: - If we miss to enable any of the port as GROUP BY, the aggregator will write
the lat
row of
the table to the next transformation.
15. There are n numbers of flat file of exactly same format are placed in a folder.
Can we load these flat file’s data one by one to a single relational table by a
Single session?
A: - Use source type as Indirect File Type and source file name as a file having
the
names of
All the n flat files to be read.
Informatica Senarios-3
15. Why do we go for update strategy TR in SCD rather using the session
Properties?
A: - Session Properties like pre Source Rows INSERT, UPDATE, REJECT, DELETE,
Using
Session Properties we can do single flow only .SCD applicable for Insert, Update at
a
Time using Update Strategy Trans only. Using Update Trans we can create SCD
mapping
16. How many mapplets u have created? And what is the logic used?
A: - We can create any No of Mapplets for 1 mapping. There is no limit for
Mapplets.
Every mapplet can have a Logic or logics,,,,,, There is no limit for logics.
17. LOOKUP Condition is nothing but a Join condition? What type of join condition
it,
By Default? Using the Lookup Condition How many types of relational
conditions
We can make?
A: - as per my understanding. Lkp is always behave like left outer join. It will
give you all
Matched records as well as unmatched records which are not present in base
table...and
Those unmatched records are will be null in case of unconnected lkp trn.....
18. What is Target Update Override? What is the Use?
A: - When we don't have primary keys defined on database level. And still we need
update on
This target from Informatica. We need to define keys at informatica level and use
update
Override in target property. This way we can update the table.
19. Why sequence generator should not directly connected to joiner
transformation?
A:-Mainly sequence generator is used to generate a unique id dynamically. We can
not
join this number against any column in other tables...So. We can not connect
sequence
generator with joiner. And also, Main reason is joiner is an Active transformation.
Means it
can alter the number of rows. So, if u connect sequence generator with joiner the
outcome sequence will not be proper.
20. from Source 100 rows are coming, on target there are 5 m rows which options
is better to match data 1. Joiner 2 No cache 3. Static 4. Dynamic?
A: - Here we will use joiner for better performance. We will join the two sources
making
source table as master source. So only 100 comparisons will be done. So it will be
very
faster.
Whereas in static and dynamic we have to look up on the target which is very large
5m
rows. So caching will take more time.
21. How to create a mapping?
id date
101 2/4/2008
101 4/4/2008
102 6/4/2008
102 4/4/2008
103 4/4/2008
104 8/4/2008 O/P - should have only one id with the min (date) How to create a
mapping for this?
A: - I think its Simple, with Agg Transformation, First Group by ID, Then go with
min (date)
in
Same Agg Transformation.
Informatica Senarios-4
22. What are set operators in Oracle?
A: - UNION, UNION ALL, MINUS and INTERSECT
23. How I can Schedule the Informatica job in "Unix Corn scheduling tool”?
A: - we can do this by using crontab file in UNIX, for this we need to schedule the
Power
centre job. or we can use "at" command in UNIX to schedule the job.
24. How can I generate Sequence Numbers to Target Table (with out using
Sequence Gen Trans, Rank Trans).
A: - Use database Sequence generator call this from stored procedure or dummy
lookup
Query Or You can also use expression transformation. Create two ports one is
variable
And assign it to 0 and another one is output port and Write the logic to increment
it
(o_seq=v_Seq+1)
25. Can any one explain me step by step how scd will work?
Selects all rows. Caches the existing target as a lookup table. Compares logical
key
columns in the source against corresponding columns in the target lookup table.
Compares source columns against corresponding target columns if key columns match.
Flags new rows and changed rows. Creates two data flows: one for new rows, one for
changed rows. Generates a primary key for new rows. Inserts new rows to the target.
Updates changed rows in the target, overwriting existing rows.
26. When we load flat files into target tables how do we identify duplicates? And
where do load the duplicate records for further reference? How do we do chage
data capture? Is this slowly changing Dimension technique?
A: - I have an idea after sql transformation go thruogh 2 Agg Trans, 2 Router Trans
Agg1-gorup by col count=1 to router Trans
Agg2-group by col count<>1 to router Trans (I think “it will help u”)
From 2nd router Transformation we have a Separate Target Table.
Is this slowly changing Dimension technique?
Change data capture (CDC) Mean newly Inserts, Updates Based on Data loading
time,
This Inserts, Updates only slowly changing Dimension technique.
27.I have table name called Team and I have name and DOJ in that table in oracle,
when I retrieve the table in Informatica DOJ shows with date and time , I want want
to know is it possible to get only date(MMDDYYYY) in the date data type,
A: - TO_CHAR (DOJ_port, 'MMDDYYYY')
28. How Union Transformation is an Active Trans?
A: - The simple logic of Union is that, It capture all the unique records from both
the
source.
Suppose if you have 10 records in table A and 10 records in table B, in which 3
records
Are same in both the tables. Then after using the Union transformation you will get
17
Records, as the records which are getting duplicated will not be in the output.
29. How can we load first and last record from a flat file source to target?
A: - After sql Trans, go with AGG, RANK transformation, in RankTrans Properties set
the
rank
1 only---1 row returns, In AggTrans Don’t do any column for Group--Last row
returns,
We need 2 Target tables. 1 for 1st record,2 for last record, if u using the
UNIONtrans
one
Target table is enough,,,
Informatica Senarios-5
30. Diff B/W MAP Parameter, SESSION Parameter, Database connection session
parameters? It’s possible to create 3parameters at a time? If Possible which one
will fire FIRST?
A: - we can pass all these three types of parameters by using Perameterfile.we can
declare all in one parameter file.
A mapping parameter is set at the mapping level for values that do not change from
session to session for example tax rates.
Session parameter is set at the session level for values that can change from
sesion to
session, such as database connections for DEV, QA and PRD environments.
The database connection session parameters can be created for all input fields to
connection objects. For example, username, password, etc.
It is possible to have multiple parameters at a time?
The order of execution is wf/s/m.
31. How to run two workflow (not a sessions) sequentially, what is the process?
A: - The best way is obviously to run WF1 and then call WF2 using PMCMD command in
the last session of WF1 (as a post session task).If you absolutely want to ensure
that the
second wf starts only after graceful completion of wf1 then simply add a command
task
for the pmcmd and use the piple to validate that the previous task is completed
properly.
Or
We can run the workflow sequentially .for that we need to write a ksh shell scripts
or
batch command and use cmd command
32. Which is costliest transformation? Costly means occupying more memory?
A:-Look up Transformation only, its going to maintain existing data also in cache
memory
33. Which gives the more performance when compare to fixed width and delimited
file? And why?
A: - fixed width, because there are no delimiters to check so the performance will
increase.
34. How to list Top 10 salary, without using Rank Transmission?
A: - use sorter--> expression-->filter
1) Sorter descend 2) use sequence generator connected expression to generator
Sequence, 3) filter the value sequence number greater than 10
35. How to extract original records at one target & Duplicate records at one
target?
A:- Source -> SQ -> Sorter ->Expression ->Router(or 2 filters) ->Targets
36. Is it possible to have "5 source & 5 Target" in single mapping?
A:-single mapping we can have 5 sources and 5 target and we need to arrange target
load
Plan if dependency exists.
37. without using Lookup & Sequence Generator, How to generate Sequence?
A:-using set count variable in expression transformation.
38. How to join 2 tables, without using any condition?
A:-Add dummy column in expression or Source Qul. For both source and use that
column
in
Join condition.
Informatica Senarios-6
39. Without source how to insert record to target?
A: - Without source you can not create mapping...
39. How will you remove the duplicate records from flat file without using sorter?
A: - Use aggregator transformation and group by all ports and create one port for
checking
Count...and pass the results accordingly to target tables.
40. How to join the two flat files using the joiner t/r if there is no matching
port?
A:-Connect the source Qualifier of two different flat files to two different Exp
Trans. Create
a
Dummy output port in both the exp trans. then using that port connects the joiner
Tran.
41. What is the difference between Oracle performance and Informatica
Performance? Which performance is better?
A:-oracle performance deals with the source &targets. Informatica performance deals
with
the
Transformations. For efficiency result both are impotent...
42. How to run the batch using pmcmd command?
A:-Using Command task in the workflow
43. Suppose you have 2000 records in one table and 12000 in another which one
you will consider as master and detail?
A:-We will consider the one with lesser number of records as master as with this
approach the
Data to be cached would have to be less and hence the performance can be improved.
44 .What is the target load order?
A:-You specify the target load order based on source qualifiers in a maping.If you
have
the multiple source qualifiers connected to the multiple targets, you can designate
the
order in which informatica server loads data into the targets.
45. Explain use of update strategy transformation?
A:-To flag source records as INSERT, DELETE, UPDATE or REJECT for target
database. Default flag is Inserting. This is must for Incremental Data Loading.
Or
This is the important transformation, is used to maintain the history data or just
most
recent changes into the target table.
We can set or flag the records by using these two levels.
1) Within a session:-When you configure the session, you can instruct the
informatica
server to either treat all the records in the same way.
2) Within a mapping:-within a mapping we use update strategy transformation to flag
the records like insert, update, delete or reject.
46. This is a scenario in which the source has 2 cols -10 A ,10 A,20 C,30 D,40 E,20
C
And there should be 2 targets one to show the duplicate values and another
target for distinct rows.
T1 T2
10 A 10 A
20 C 20 C
30 D 40 E which transformation can be used to load data into target?
Informatica Senarios-7
A:- 1.Sorce - Source qualifier – Target Check- Select distinct option
2.Source --Source qualifier- aggregator – Target group by-empno
3.Source --Source qualifier- sorter – Target Check- Select distinct option
4.Source -Source qualifier -Expression –Target -Source qualifier: check sorted by
empno
Expression:- port expression
in_empno
var-empno=var_duplicate
var_duplicate=in_emp
flag= IIF(var_duplicate=var_emp,'Y','N')
5.Source -Source qualifier -Rank-Expression -Target
47. What is parameter file?
A:-When you start a workflow, you can optionally enter the directory and name of
a parameter file. The Informatica Server runs the workflow using the parameters in
the file
you specify. For UNIX shell users, enclose the parameter file name in single
quotes:
-paramfile '$PMRootDir/myfile.txt
48. Difference between Rank and Dense Rank?
Rank:
12
<--2nd position
2<--3rd position
45
Same Rank is assigned to same totals/numbers. Rank is followed by the Position.
Golf
game ususally Ranks this way. This is usually a Gold Ranking.
Dense Rank:
12
<--2nd position
2<--3rd position
34
Same ranks are assigned to same totals/numbers/names. the next rank follows the
serial
number.
49. What is the method of loading 5 flat files of having same structure to a single
target and which transformations I can use?
Two Methods.
1.write all files in one directory then use file repository concept(dont forget to
type source
file type as indirect in the session).
2.use union t/r to combine multiple input files into a single target.
50. Suppose session is configured with commit interval of 10,000 rows and source
has 50,000 rows. Explain the commit points for Source based commit and Target
based commit. Assume appropriate value wherever required.
Source based commit will commit the data into target based on commit
interval.so,for
every 10,000 rows it will commit into target.
Target based commit will commit the data into target based on buffer size of the
target.i.e., it commits the data into target when ever the buffer fills.Let us
assume that the
buffer size is 6,000.So,for every 6,000 rows it commits the data.
----------------------------------------------------------------
186656005-Informatica-Interview-Questions-Scenario-Based.pdf
INFORMATICA INTERVIEW
QUESTIONS, 25 Scenarios/Solutions
Informatica Interview Questions [ Version 1.1 ]
Compiled by - mahender, uma
2/1/2013
ETL Labs
Informatica Scenarios
Scenario1:
We have a target source table containing 3 columns: Col1, Col2 and Col3. There is
only 1 row in the table as follows:
Col1 Col2 Col3
-----------------
a b c
There is target table contain only 1 column Col. Design a mapping so that the
target table contains 3 rows as follows:
Col
-----
a
b
c
Solution:
Not using a Normalizer transformation:
Create 3 expression transformations exp_1,exp_2 and exp_3 with 1 port each. Connect
col1 from Source Qualifier to port in
exp_1.Connect col2 from Source Qualifier to port in exp_2.Connect col3 from source
qualifier to port in exp_3. Make 3
instances of the target. Connect port from exp_1 to target_1. Connect port from
exp_2 to target_2 and connect port from
exp_3 to target_3.
Scenario 2:
There is a source table that contains duplicate rows. Designs a mapping to load all
the unique rows in 1 target while
all the duplicate rows (only 1 occurrence) in another target.
Solution:
Bring all the columns from source qualifier to an Aggregator transformation. Check
group by on the key column. Create a new
output port COUNT_COL in aggregator transformation and write an expression COUNT
(KEY_COLUMN). Make a router
transformation with 2 GROUPS: Dup and Non-Dup. Check the router conditions
COUNT_COL>1 in Dup group while
COUNT_COL=1 in Non-dup group. Load these 2 groups in different targets.
Scenario 3:
There is a source table containing 2 columns Col1 and Col2 with data as follows:
Col1 Col2
------ ------
a l
b p
a m
a n
b q
ETL Labs
x y
Design a mapping to load a target table with following values from the above
mentioned source:
Col1 Col2
------ ------
a l, m, n
b p, q
x y
Solution:
Use a sorter transformation after the source qualifier to sort the values with col1
as key. Build an expression transformation
with following ports (order of ports should also be the same):
1. COL1_PREV: It will be a variable type port. Expression should contain a variable
example: VAL
2. COL1: It will be Input/output port from Sorter transformation
3. COL2: It will be input port from sorter transformation
4. VAL: It will be a variable type port. Expression should contain Col1
5. CONCATENATED_VALUE: It will be a variable type port. Expression should be decode
(Col1,Col1_prev,Concatenated_value||','||Col2,Col1)
6. CONCATENATED_FINAL: It will be an output port connecting the value of
CONCATENATED_VALUE.
After expression, build a Aggregator Transformation. Bring ports Col1 and
CONCATENATED_FINAL into aggregator. Group
by Col1. Don't give any expression. This effectively will return the last row from
each group.
Connect the ports Col1 and CONCATENATED_FINAL from aggregator to the target table.
<UMA> this can be achieved by using a database stored procedure also, but it might
end up parsing the statement every time.
So it would be always good to go with the above mentioned solution.
Scenario 4:
Design an Informatica mapping to load first half records to 1 target while other
half records to a separate target.
Solution:
You will have to assign a row number with each record. To achieve this, either use
Oracle's PSUDO column ROWNUM in
Source Qualifier query or use NEXTVAL port of a Sequence generator. Let’s name this
column as ROWNUMBER.
From Source Qualifier, create 2 pipelines:
First Pipeline:
Carry first port Col1 from SQ transformation into an aggregator transformation.
Create a new output port "tot_rec" and give the
expression as COUNT(Col1). Do not group by any port. This will give us the total
number of records in Source Table. Carry
this port tot_rec to an Expression Transformation. Add another port DUMMY in
expression transformation with default value 1.
Second Pipeline:
from SQ transformation, carry all the ports(including an additional port rownumber
generated by rownum or sequence
generator) to an Expression Transformation. Add another port DUMMY in expression
transformation with default value 1.
Join these 2 pipelines with a Joiner Transformation on common port DUMMY. carry all
the source table ports and 2 additional
ports tot_rec and rownumber to a router transformation. Add 2 groups in Router :
FIRST_HALF and SECOND_HALF. Give
condition rownumber<=tot_rec/2 in FIRST_HALF. Give condition rownumber>tot_rec/2 in
SECOND_HALF. Connect the 2
groups to 2 different targets.
ETL Labs
Scenario 5:
A source table contains emp_name and salary columns. Develop an Informatica mapping
to load all records with 5th
highest salary into the target table.
Solution:
The mapping will contain following transformations after the Source Qualifier
Transformation:
1. Sorter : It will contain 2 ports - emp_name and salary. The property 'Direction'
will be selected as 'Descending' on key
'Salary'
2. Expression transformation: It will 6 ports as follows -
a> emp_name : It will be an I/O port directly connected from previous sorter
transformation
b> salary_prev : It will be a variable type port. Give any vriable name e.g val in
its Expression column
c> salary : It will be an I/O port directly connected from previous transformation
d> val : It will be a variable port. The expression column of this port will
contain 'salary'
e> rank: It will be a variable type port. The expression column will contain decode
(salary,salary_prev,rank,rank+1)
f> rank_o : It will be an output port containg the value of 'rank'.
3. Filter Transformation : It will have 2 I/O ports emp_name and salary with a
filter condition rank_o = 5
The ports emp_name and salary from Filter Transformation will be connected to
target
Scenario 6:
Let’s say I have more than have record in source table and I have 3 destination
table A,B,C. I have to insert first 1 to 10
records in A then 11 to 20 in B and 21 to 30 in C.
Then again from 31 to 40 in A, 41 to 50 in B and 51 to 60 in C……So on up to last
record.
Solution:
Generate sequence number using informatica, add filter or router transformations
and define the conditions accordingly…
Define group condition as follows under router groups….
Group1 = mod(seq_number,30) >= 1 and mod(seq_number,30) <= 10
Group2 = mod(seq_number,30) >= 11 and mod(seq_number,30) <= 20
Group3 = (mod(seq_number,30) >=21 and mod(seq_number,30) <= 29 ) or
mod(seq_number,30) = 0
Connect Group1 to A, Group2 to B and Group3 to C
ETL Labs
Scenario 7:
Validation rules for connecting transformations in Informatica?
Solution:
Some validation rules:
1-You can only link ports with compatible datatypes.
2-You cannot connect an active transformation and a passive transformation to the
same downstream transformation.
3-You cannot connect more than one active transformation to the same downstream
transformation or transformation input
group.only way to do it using joiner with sorted ports.
Scenario 8:
Source is a flat file and want to load unique and duplicate records separately into
two separate targets; right??
Solutions:
Here comes the solution -
SRC - SQ_SRC - SRT - EXP - RTR - TGT
Try with the above and add logic of Sorter to identify duplicates, Use expression
to mark the duplicates and finally Router to
route to different targets.
Scenario 9:
Input file
---------
10
10
10
20
20
30
output file
------------
1
2
3
1
2
1
scenario-it will count the no of records for example in this above case first 10 is
there so it will count 1,den again 10 is there so
it will be 2, when 20 comes it will be 1 again.
ETL Labs
Solution:
First import source, then use a sorter transformation. sort it by your column, then
use an expression.
In expression make this column, like this
1. column_num(coming from sorter)
2. current_num= check if column_num=previous_num,then add (first_value +1),else 1
3. first_value=current_num.
4. previous_num(new column)= column_num
Pass current_num to target.
Scenario 10:
Input file
---------
10
10
10
20
20
30
output file
----------
1
2
3
4
5
6
Solution:
<UMA> Sequence Generator can be used
Scenario 11:
input file
---------
10
10
10
ETL Labs
20
20
30
output file
---------->
1
1
1
2
2
3
Solution:
Sort => Expr (%10)=>Target
Scenario 12:
There are 2 tables(input table)
table aa table bb
-------- ---------
id name id name
-- ----- -- ----
101 ramesh 106 harish
102 shyam 103 hari
103 ---- 104 ram
104 ----
output file
----------
id name
-- ----
101 ramesh
102 shyam
103 hari
104 ram
Solution:
One SQ => Exclude NULL value trx => Filter 106
Table bb is master and aa is detail table; If I do Master outer join, It will give
common records from Master and additional
records from detail – So output will be 101, 102, 103, 104
Use sorter and direct to target
SQL: SELECT * FROM BB LEFT OUTER JOIN AA ON (BB.ID = AA.ID)
ETL Labs
Scenario 13:
table aa(input file)
------------------
id name
-- ----
10 aa
10 bb
10 cc
20 aa
20 bb
30 aa
Output
-----
id name1 name2 name3
-- ------ ------ -----
10 aa bb cc
20 aa bb --
30 aa -- --
Solution:
Use Sorter => EXPR (val=in_name; out=if (out=val
Scenario 14:
table aa(input file)
------------------
id name
-- ----
10 a
10 b
10 c
20 d
20 e
output
-------
id name
-- ----
10 abc
20 de
ETL Labs
Scenario 15:
In the below scenario how can I split the row into multiple depending on date
range?
The source rows are as
ID Value from_date(mm/dd) To_date(mm/dd)
1 $10 1/2 1/3
2 $5 1/5 1/8
3 $20 1/9 1/11
The target should be
ID Value Date
1 $10 1/2
1 $10 1/3
2 $5 1/5
2 $5 1/6
2 $5 1/7
2 $5 1/8
3 $20 1/9
3 $20 1/10
3 $20 1/11
What is the informatica solution?
Solution:
Use a Normalizer transformation with 3 ports ID, Value, Date. Set the 'Occurs'
property of Normalizer to 2 for Date port and 1
for ID and Value ports. Now normalizer will be created with 4 input ports ID,
Value, Date1 and Date2 and there will be 3 output
ports ID, Value, Date. Connect from_date to Date1 and To_Date to Date2, and connect
the rest of the matching ports.
Connect the normalizer to your target.
Use datediff function to calculate no of days between dates.
Use that difference as the number of iteration .than use add_to_date function to
increment date till number of iteration and load
it to target.
Scenario 16:
How can the following be achieved in 1 single Informatica Mapping.
* If the Header table record has error value(NULL) then
those records and the corresponding child records in the
SUBHEAD and DETAIL tables should also not be loaded into
the target(TARGET1,TARGET 2 or TARGET3).
* If the HEADER table record is valid, but the SUBHEAD or
DETAIL table record has an error value (NULL) then the no
data should be loaded into the target TARGET1,TARGET 2 or
TARGET3.
* If the HEADER table record is valid and the SUBHEAD or
DETAIL table record also has valid records only then the
ETL Labs
data should be loaded into the target TARGET1,TARGET 2 and
TARGET3.
===================================================
HEADER
COL1 COL2 COL3 COL5 COL6
1 ABC NULL NULL CITY1
2 XYZ 456 TUBE CITY2
3 GTD 564 PIN CITY3
SUBHEAD
COL1 COL2 COL3 COL5 COL6
1 1001 VAL3 748 543
1 1002 VAL4 33 22
1 1003 VAL6 23 11
2 2001 AAP1 334 443
2 2002 AAP2 44 22
3 3001 RAD2 NULL 33
3 3002 RAD3 NULL 234
3 3003 RAD4 83 31
DETAIL
COL1 COL2 COL3 COL5 COL6
1 D001 TXX2 748 543
1 D002 TXX3 33 22
1 D003 TXX4 23 11
2 D001 PXX2 56 224
2 D002 PXX3 666 332
========================================================
TARGET1
2 XYZ 456 TUBE CITY2
TARGET2
2 2001 AAP1 334 443
2 2002 AAP2 44 22
TARGET3
2 D001 PXX2 56 224
2 D002 PXX3 666 332
Solution:
I don’t know. Let us know if you know this.
Scenario 17:
If i had source like unique & duplicate records like 1,1,2,3,3,4 then i want load
unique records in one target like 2,4
and i want load duplicate records like 1,1,3,3
Solution:
Source => SQ => Aggregator => Joiner => Router => Target1,2
ETL Labs
Scenario 18:
I Have 100 Records in a relational table and i want to load the record in 3 targets
, first records goes to target 1 and
second to target 2 and third to target 3 and so on ,what are the tx used in this.
Solution:
1) From source qualifier get the records to the Expression.
2) Use one Sequence generator in which set the max value as 3, enable cycle option.
Connect it to the expression.
3) Then use router & create 2 groups, 1st group condition as Next value = 1 another
as next value = 2 and default.
4) These should be connected to the 3 target tables.
Scenario 19:
There are three columns empid, salmonth, sal contains the values 101,jan,1000
101 feb 1000 …
like twelve rows are there then my required out put is like contains 13 columns
empid jan feb march ....... dec and the
values are 101 1000, 1000, 1000 etc
Make 13 columns and add expression transformation and as out and put the conditions
like MAX(if(month='jan',sal)), same for
other months.
Scenario 20:
I have a source either file or db table
Eno ename sal dept
101 sri 100 1
102 seeta 200 2
103 lax 300 3
104 ravam 76 1
105 soorp 120 2
Want to run a session 3 times.
First time: it should populate dept 1
Second time: dept 2 only
Third time: dept 3 only
How can we do this?
Solution:
Not sure how to do it.
ETL Labs
Scenario 21:
If I have a source as below:
Employeed, FamilyId, Contribution
1,A,10000
2,A,20000
3,A,10000
4,B,20
5,B,20
________________________________
And my desired target is as below:
EmployeeId,Contribution(In Percent)
1,25%
2,50%
3,25%
4,50%
5,50%
____________________________________________________________________________
Explanation: The contribution field in target is the individual Employee's share in
a family's contribution.Say if total family
contribution is 40000 then if A has contributed 10000 then target should have a
value of 25%.
____________________________________________________________________________
Can you please suggest me an approach to solve the specified problem?
Solution:
Here goes the sql override
SELECT A.empid(B.contribution/A.BB)*100 AS CONTRIBUT FROM (SELECT empid
SUM(contribution) OVER (PARTITION BY familyid) AS BB
FROM table1) A (SELECT empid contribution FROM table1) B WHERE A.empid B.Empid
Scenario 22:
Is it more Advantageous to use the Pre and Post SQL properties in the Workflow
Designer task properties or in the Mapping
Designer's? I am copying data from production to a staging table. As part of the
process, I need to drop the indexes and
triggers before the move, and recreate them after the move. What is the benefit (if
any) of using the pre and post sql property
in the WorkFlow rather than the Mapping?
Solution:
It’s good to go with Pre-SQL, Session, & Post SQL options with some modifications:
(Never validated)
ETL Labs
Scenario 23:
I have a session which has a truncate target table option enabled. When the session
fails for some reason the data in
truncated in the table. How can I avoid truncating a target table in case of
session failure?
Solution:
Step - 1:
In the Pre-SQL:
Statement sequence would be --
1. Write savepoint statement like "SAVEPOINT STARTLOAD"
2. DELETE STATEMENT like "DELETE FROM TABLE TABLE_NAME" .......
Step - 2:
At session level:
1. Uncheck the "Truncate table option"
2. Increase the commit interval to max value that informatica allows i.e,
2,147,483647 as the commit interval considering that
during that load you will have source records coming less than 2,147,483647 record
count.
3. Enable the option "Rollback Transactions on Errors" This will help to rollback
the operations till the savepoint set in
the Pre-SQL section.
Step -3:
In Post-SQL: Target Definition -
Write a Comit statement. "COMMIT". : This will help to commit the operations done
on the target table after savepoint set in
the Pre-SQL.
Scenario 24:
How to pass one mapping variable / parameter to another with in the same workflow?
Solution:
To pass a mapping variable or parameter value from one session to another in a
workflow, do the following:
Create two consecutive sessions (session1 and session2) in a Workflow.
Create Workflow variable(s) in the Workflow.
In Session1, go to Edit >Components > Post-Session On Success Variable Assignment,
assign values from mapping
variables/parameter to workflow variables.
In Session2 Edit > Components > Pre-session Variable Assignment, assign values from
workflow variables to mapping
variables/parameter.
OR
from PowerCenter 8.6, there is an option to share the mapping variable to multiple
sessions in the same workflow using the
presession_variable_assignment option and then create a workflow variable.
ETL Labs
Scenario 25:
In Informatica, what is the benefit apart from Performance of using more than one
INTEGRATION SERVICES in a
Domain
Solution:
Load balancing and failover