How to only last 100 records from a flatfile?

Thru informatica how we can load only last 100 records.

Showing Answers 1 - 27 of 27 Answers

lakshmi

  • May 27th, 2012
 

its a easy process.first take source---->SQ----->Rank------>target.
In rank t/r set rank properties as below

top/bottom---------->bottom

number of ranks---->100

  Was this answer useful?  Yes

Naresh

  • May 28th, 2012
 

Use tail stage n set n=100

  Was this answer useful?  Yes

shanker

  • Mar 29th, 2013
 

Rank solves the problem based on the attribute you are ranking on. if the attribute is not the distinct, then this would not resolve. I also need right answer for this.

  Was this answer useful?  Yes

Saurav

  • Apr 3rd, 2013
 

You can use the following logic

FF-> SRT(in descending order)=>EXP=> FLT=>TGT
||
SEQ

filter the seq generated values from 1-100 this will load the last 100 values to the target

  Was this answer useful?  Yes

Sarita

  • Sep 3rd, 2013
 

Use flat file->src qualifier->rank-> target. In rank select top 100 and do rank index on NEXTVAL

|
seq gen


I tested it too but not getting an option to insert mapping image here.

Ankit

  • Feb 15th, 2014
 

SRC->SEQ->EXP->SRT ON SEQ(DESC)->SEQ2>FILTER(SEQ2 < 100)->TGT

  Was this answer useful?  Yes

kalpeshradadia

  • Jun 23rd, 2014
 

SQ---- Exp ---- Sorter----Exp --- Filter---Sorter --- Target.
Connect the source qualifier transformation to an expression transformation. In the expression
transformation, create the below ports:

v_cnt (variable port) = v_cnt+1 o_cnt (output_port) = v_cnt

Connect the expression transformation to the sorter transformation. Sort the rows on the o_cnt port in descending order.

Now connect the sorter transformation to the expression transformation (do not connect o_cnt port).

Again Connect to expression transformation create the ports mentioned above

v_cnt (variable port) = v_cnt+1 o_cnt (output_port) = v_cnt

Connect to a filter transformation and specify the filter condition as o_cnt<=N

Connect the expression transformation to the sorter transformation. Sort the rows on the o_cnt port in descending order.

Connect to the target

  Was this answer useful?  Yes

Naveen

  • Dec 11th, 2015
 

Use SQ --> EXP --> RANK --> TGT
In EXP initialize v_count=v_count+1
In Rank Txn, rank on v_count and select BOTTOM 100.
I think, this will work.

  Was this answer useful?  Yes

Prasad

  • Mar 8th, 2016
 

SQ->exp->filter->target
In expression we need to calculate sequence number then filter records in filter transformation as column>=50 and column<=100

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions