Output using stage variable concept of transformer only (remove reserve duplicates)
SOURCE DESTINATION DISTANCE(KM)
HYD CHN 500
CHN HYD 500
BANG HYD 600
HYD BANG 600
PUN HYD 750
HYD PUN 750
How to achieve this?
My input data:
My output should look like
Customer_ID Customer_Name Customer_City
100 ABC Delhi
How to convert multiple rows into single row in datastage
Can you please solve this in datastage..
my input is
want output as
pls explain with steps
thanking in advance...
Increasing A Number
I would like to know if you could help me out. I have a a file with 2 columns (TABLENAME and CLOB) and in the TABLENAME there are "Providers". I would like to know how to set them at number 5000 and then increment them, per provider. So if I have 5 providers per file, it would be 5000, 5001, 5002, 5003, 5004. This is a daily file so we will get a file everyday. So Day 2, the 1st provider must be 5005...
Convert and Ereplace Every Double Dash
I have heard of both Convert and Ereplace but I am stumped. I need to take every double dash (--) from my files and convert them to a single hyphen (-). What would be the best way to do this?
Extracting from Rows
To further this, it is probably simple, but :
HEADER(first row) PROVIDER12082015
MISCROWS IN BETWEEN
TRAILER(last row) 00000000669
If I have three columns created in the transformer (HeadName, HeadDate, RecCount), how would I put this in the derivations?
HeadName is supposed to be equal to PROVIDER
Cumulative Sum Calculation
Solve with steps in datastage
employee_id, salary, cumulative_sum
10, 1000, 1000
20, 2000, 3000
Add a Sequence Number for a Table/Row
I have a file structure that I need to add things to and it is as follows:
I need to know how to create a sequence number the tables in between the PROV_TB. The PROV_TB has been assigned a number I created (153365000 is the 1st, 153365001 is the...
Convert multiple rows into columns in datastage
i have sourse like
want output like
thanks in advance..
Filter Out Errors
I am getting a file in and I want to be sure that it has specific traits. The first record must say HEADER, the second record must say PROVIDER, the last record must say TRAILER, Record Count must equal TRAILER count (HEADER - TRAILER = Record Count; TRAILER COLUMN has number of Records)
Validation and Row Counts
I need help validating rows. 1st. I have a sequential file that has 139 rows, 2 columns (TABLENAME, CLOB). Of those rows, two (in TABLENAME column) are named "HEADER" and "TRAILER". I do not want these in my output. How do I keep the 137 rows and cut off the HEADER & TRAILER. 2nd. In the TRAILER row (TABLENAME column), there is a number that reads 00000000137 (in the CLOB column), which is the 137...
Sequencers in Autosys
There is a sequencer 1 scheduled at 12:30 that contains 2 jobs. After sequencer 1 finishes sequencer 2 will execute that again contains 2 jobs. Now if one of the jobs on sequencer 1 fails, then sequencer 2 will not execute. Sequencer 1 should exactly start at 12:30 AM every day. Write the jil script for these sequencers.
Sequence Job Creation Scenario
You are given 2 jobs say job A and Job B with parameters x and y respectively. You need to create a sequence job. If you pass parameter x then Job A should run, If you pass parameter y then Job B should run, if you dont pass any parameter then Both Job A & B should run
DataStage Interview Questions