GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Data Warehousing  >  ETL
Go To First  |  Previous Question  |  Next Question 
 ETL  |  Question 15 of 65    Print  
How can we use mapping variables in Informatica? Where do we use them?

  
Total Answers and Comments: 2 Last Update: June 10, 2009   
  
 Sponsored Links

 
 Best Rated Answer
Submitted by: navaneethvr
 

In the Designer, you can create mapping variables in a mapping or mapplet. After you create a mapping variable, it appears in the Expression Editor. You can then use it in any expression in the mapping or mapplet. You can also use mapping variables in a source qualifier filter, user-defined join, or extract override, and in the Expression Editor of reusable transformations.

Unlike mapping parameters, mapping variables are values that can change between sessions. The Integration Service saves the latest value of a mapping variable to the repository at the end of each successful session. During the next session run, it evaluates all references to the mapping variable to the saved value. You can override a saved value with the parameter file. You can also clear all saved values for the session in the Workflow Manager.

You might use a mapping variable to perform an incremental read of the source. For example, you have a source table containing timestamped transactions and you want to evaluate the transactions on a daily basis. Instead of manually entering a session override to filter source data each time you run the session, you can create a mapping variable, $$IncludeDateTime. In the source qualifier, create a filter to read only rows whose transaction date equals $$IncludeDateTime, such as:

TIMESTAMP = $$IncludeDateTime

In the mapping, use a variable function to set the variable value to increment one day each time the session runs. If you set the initial value of $$IncludeDateTime to 8/1/2004, the first time the Integration Service runs the session, it reads only rows dated 8/1/2004. During the session, the Integration Service sets $$IncludeDateTime to 8/2/2004. It saves 8/2/2004 to the repository at the end of the session. The next time it runs the session, it reads only rows from August 2, 2004.



Above answer was rated as good by the following members:
butair
August 14, 2005 06:56:23   #1  
Praveen        

RE: How can we use mapping variables in Informatica? Where do we use them?


After creating a variable we can use it in any expression in a mapping or a mapplet. Als they can be used in source qualifier filter user defined joins or extract overrides and in expression editor of reusable transformations.
Their values can change automatically between sessions.

 
Is this answer useful? Yes | No
June 09, 2009 12:08:15   #2  
navaneethvr Member Since: June 2009   Contribution: 1    

RE: How can we use mapping variables in Informatica? Where do we use them?

In the Designer you can create mapping variables in a mapping or mapplet. After you create a mapping variable it appears in the Expression Editor. You can then use it in any expression in the mapping or mapplet. You can also use mapping variables in a source qualifier filter user-defined join or extract override and in the Expression Editor of reusable transformations.

Unlike mapping parameters mapping variables are values that can change between sessions. The Integration Service saves the latest value of a mapping variable to the repository at the end of each successful session. During the next session run it evaluates all references to the mapping variable to the saved value. You can override a saved value with the parameter file. You can also clear all saved values for the session in the Workflow Manager.

You might use a mapping variable to perform an incremental read of the source. For example you have a source table containing timestamped transactions and you want to evaluate the transactions on a daily basis. Instead of manually entering a session override to filter source data each time you run the session you can create a mapping variable $$IncludeDateTime. In the source qualifier create a filter to read only rows whose transaction date equals $$IncludeDateTime such as:

TIMESTAMP $$IncludeDateTime

In the mapping use a variable function to set the variable value to increment one day each time the session runs. If you set the initial value of $$IncludeDateTime to 8/1/2004 the first time the Integration Service runs the session it reads only rows dated 8/1/2004. During the session the Integration Service sets $$IncludeDateTime to 8/2/2004. It saves 8/2/2004 to the repository at the end of the session. The next time it runs the session it reads only rows from August 2 2004.


 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    

 Related Questions

Latest Answer : Hi!Lookups are two types: 1) Connected 2) Unconnected Connected is further two types 1) Static 2) Dynamic connected lookup is used while returning single or multiple returning values, but unconnected can return only single return value. static and dynamic ...

Latest Answer : yes it supports 6.1.3 on words ...

Answer posted by Staline on 2005-05-27 00:42:44: You can use a Command task to call the shell scripts, in the following ways:  1. Standalone Command task. You can use a Command task anywhere in the 
Latest Answer : Hi,There are two ways to do this,they are as follows:1)we can use a command task anywhere  in the workflow or worklet to run the shell commands.2)In the session task,we can call reusable command task  in the pre-session post_session property ...

Answered by kiran on 2005-05-08 09:20:30: Informatica Metadata contains all the information about the source tables, target tables, the transformations, so that it will be useful and easy to perform transformations 
Latest Answer : Metadata is simply documentation for a digital geospatial dataset. It is a text document that describes the who, what, when, where, why and how questions about the data, so that a potential data user can decide whether or not the data is appropriate for ...
Tags : Metadata

Latest Answer : with out knowing these what can u do? ...

Latest Answer : In the Designer, you can create mapping variables in a mapping or mapplet. After you create a mapping variable, it appears in the Expression Editor. You can then use it in any expression in the mapping or mapplet. You can also use mapping variables in ...

Latest Answer : With the help of a source Qualifier and Lookup we can overide SQL Query. ...

Can we use procedural logic inside Infromatica? If yes how , if now how can we use external procedural logic in informatica?

Latest Answer : You cannot use Informatica to extract data from SAP via ABAP.  Only the SAP/Business Objects Data Integrator product can do this.Informatica uses a data dictionary interface, with clear SQL instructions, example...select BUKRS, BELNR, GJAHR, BUZEI ...

How do you implement the concept of reusability in Microstrategy?( As in Informatica it is done by creating mapplets.)


 Sponsored Links

 
Related Articles

Breaking up XML into Relational Data

Breaking up XML into Relational Data While the preceding example shows how to construct an XML representation over relational data the example in this section illustrates how you can shred XML data back into relational data This reverse operation can be useful if your application works with relation
 

Querying Data with Oracle XQuery

Querying Data with Oracle XQuery Starting with Oracle Database 10g Release 2 you can take advantage of a full featured native XQuery engine integrated with the database With Oracle XQuery you can accomplish various tasks involved in developing PHP Oracle XML applications operating on any kind of dat
 

Retrieving XML Data

Retrieving XML DataTo retrieve XML data from an XMLType table you can use a SELECT SQL statement just as you would if you had to query a relational table For example to select the employee with the id set to 100 from the employees XMLType table discussed in the preceding section you might issue the
 

Using XMLType for Handling XML Data in the Database

Using XMLType for Handling XML Data in the Database Being an object type XMLType can not only be used to store XML data in the database but also to operate on that data via its built in methods Regardless of the storage model you choose XMLType provides a set of XML specific methods to operate on XM
 

Using Oracle Database for Storing, Modifying, and Retrieving XML Data

Using Oracle Database for Storing Modifying and Retrieving XML Data With Oracle XML DB you have various XML storage and XML processing options allowing you to achieve the required level of performance and scalability One of the most interesting things about Oracle XML DB is that it allows you to per
 

ODP.NET - Techniques to Improve Performance while Retrieving Data

ODP NET Techniques to Improve Performance while Retrieving Data Performance tuning is a great subject in Oracle Volumes of books would not be enough to cover every aspect of performance tuning in Oracle However in this section we will only discuss the fundamental performance techniques while working
 

ODP.NET - Working with Bind Variables together with OracleParameter

ODP NET Working with Bind Variables together with OracleParameter With the help of OracleParameter you can include bind variables within any SQL statement These bind variables are nothing but run time query parameters The values in the SQL statement are bound at run time when we use bind variables m
 

ODP.NET - Populating a Dataset with a Single Data Table

ODP NET Populating a Dataset with a Single Data Table A dataset is simply a group of data tables These data tables can be identified with their own unique names within a dataset You can also add relations between data tables available in a dataset mosgoogle The following code gives you the details o
 

ODP.NET - Retrieving Typed Data

ODP NET Retrieving Typed Data While retrieving values from OracleDataReader we can extract information available in individual columns of a particular row either by using column ordinal position values or column names mosgoogle Retrieving Typed Data Using Ordinals ODP NET provides data specific enum
 

ODP.NET - Retrieving Data Using OracleDataReader

ODP NET Retrieving Data Using OracleDataReader OracleDataReader is simply a read only and forward only result set It works only if the database connection is open and it makes sure that the connection is open while you are retrieving data As the data that it retrieves is read only it is a bit faster
 

About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape