Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Hi I have a source (flat file) like



ID Name Attachments

101 abc [07012005072902]_CMM27-11-01 Page106
(2).pdf

102 bcd "[19012005124259]_Anfrage-Vendors.doc
[19012005124336]_Anfrage.xls"

103 def "[19012006092602]_IMG_0310.JPG
19012006092631]_IMG_0311.JPG [19012006092702]_IMG_0312.JPG
[19012006092727]_IMG_0313.JPG"



But I need to generate duplicate records based on
attachments column.



Target (Table) like



ID Name Attachments

101 abc [07012005072902]_CMM27-11-01 Page106
(2).pdf

102 bcd 19012005124259]_Anfrage-Vendors.doc

102 bcd [19012005124336]_Anfrage.xls

103 def [19012006092602]_IMG_0310.JPG

103 def [19012006092631]_IMG_0311.JPG

103 def [19012006092702]_IMG_0312.JPG

103 def [19012006092727]_IMG_0313.JPG

103 def [19012006092750]_IMG_0314.JPG

103 def [19012006092814]_IMG_0315.JPG





Here no. of Attachments we can't decide because it is
dynamic.



It will be great if somebody help me on this.





Thanks in Advance.
ganga

Answer Posted / zer0

As far a i understood ur scenario u need each attachment
with its ID and name.

For this you can have a simple mapping made in Informatica.

SQ ----> Expression ----> Target

In Expression create the following:

Input/Output Port: ID
Input/Output Port: Name
Variable Port: Attachments_var1 ---> CHR(32) || TO_CHAR(ID)
|| CHR(9) || Name || CHR(9)
Variable Port: Attachments_var2 ----> REPLACESTR
(0,Attachments,CHR(32),CHR(10) || Attachments_var1)
Output Port: Attachments_out -----> REPLACECHR
(0,Attachments_var2,CHR(32),'')

From expression output the fields to target (Flat File),
you might get your answer

Note: the first record has a space in the attachment name,
that needs to be looked into

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Mention some types of transformation?

1030


Explain the etl program with few examples.

1029


Explain what are the different versions of informatica?

1081


in staging we are merging the data and remove the inconsistants data that type of situation what u will done and type of functions u can use

2021


I have 100 records in source table, but I want to load 1, 5,10,15,20…..100 into target table. How can I do this? Explain in detailed mapping flow.

1677


What is decode in static cache?

1152


where to store informatica rejected data?

1079


What are the basic requirements to join two sources in a source qualifier transformation using default join?

1103


how tokens will generate?

2186


How does a rank transform differ from aggregator transform functions max and min?

1192


What is the difference between STOP and ABORT options in Workflow Monitor?

1237


How to go to the older version for a mapping?

1066


What are the different types of repositories created using informatica?

1101


How is union transformation utilized?

996


What are Dimensional table?

1044