how can we load first and last record from a flat file
source to target?
Answers were Sorted based on User's Feedback
I have an IDEA,
After sql Trans,go with AGG,RANK transformation,
in RankTrans Properties set the rank 1 only---1 row returns,
In AggTrans Dont 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,,,
i think it wii help u,,,,,,srinu,,,,,,,,,
| Is This Answer Correct ? | 13 Yes | 4 No |
Answer / hardeep
We can use below configurations to achieve desired output. We need 1 SQ, 1 SGen, 2 Rank and 2 Trgt Defn(same Trt). I think it will be cheaper.
Src-SQualifier-->
|
Rank1(Top 1st) -->Trgt1
--->
Rank2(Bottom 1st) -->Trgt2
|
SGen(NEXTVAL)-->
| Is This Answer Correct ? | 14 Yes | 5 No |
Answer / hina
Below transformation would work: Add the Nextval port of the sequence generator to both the Rank Transformations. In rank transformation select Top and Bottom resp.
------ Rank Transformation (Top)----Tgt(Ins1)
|
SQ---Sequence Generator-----
|
-------Rank Transformation(Bottom)-Tgt(Ins2)
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / vinod saini
After sql Trans use AGG,JOINER transformation,and use FIRST
& LAST function in AGG transformation without any group.
FIRST & LAST return the first & Last record values. give
JOINER condition based on first & last.
| Is This Answer Correct ? | 4 Yes | 5 No |
Answer / sudhar
Alternatively we can use the unix pre session command to
read the 1st and last record from the file and place it in
another file and use that new file as source to load the
target table.
| Is This Answer Correct ? | 1 Yes | 6 No |
SRC QF -> SEQ -> EXP -> AGR -> RTR -> TGT
create a port in expression t/r and generate a value for
each row using SEQ genrator, then in Agr take count of all
th record.create 2 condition in in router one with SEQ = 1
and another with SEQ = count of rows (this will give last
row).connect both to target.dont forget to give reset
option in SEQ generator.
| Is This Answer Correct ? | 1 Yes | 9 No |
How is union transformation utilized?
major difference between normal loading and bulk loading?
How to extract sap data using informatica?
Hi can any one tell me the difference between persistence and dynamic caches? On which conditions we are using these caches?
What is the different lookup cache(s)?
Hello , I am unable to work with SQL transformation at least. Where do i need to give connection for sql transformaton ? At session level there is no property . I have created a SQL Transformation and chosen query mode. But do i need to pass connection information to it ? I don't know where do i need to write a query ? I have written a query in file and that file path i gave in the properties of SQL Transformation. But it is not working. Could any one of you please let know how can i work with SQL Transformation? Advance Thanks.
Can we combine a flatfile and a database table using an UNION transformation?
wat s mapping parameter and mapping variable? how do you set that in a mapping?
What type of sorting algorithm does the Sorter Transformation use, to do its sorting Operation? 1. Bubble sort 2. Insertion sort 3. Shell sort 4. Merge sort 5. Heapsort 6. Quicksort 7. Bucket sort
what is the significance of newlookup port in dynamic look up
I have scenario, i have 10 worklflows and i want run the 1st workflow first and immediately i want to run 10th workflow has to run and am not bothering of 2 to 9 workflows? can any one help me how to do this? Thanks in advance.....
What do you mean by DTM and Load manager and what is difference between load manager and load balancer?