how can we generate row values like
1
1
1
2
2
2
3
3
3
using col generator
plz let me know
Answers were Sorted based on User's Feedback
Answer / koti
seq -----------cg------------seq
Take input file like
1
2
3
4
5
6
7
8
9
10
comming to CG
Column Method =Explicit
column Generate = Test
go to cg Porperties output ----Mapping----- map the test column----ok
next ,column---edit column meta data--columnname test--sqltype integer----parallel properties---genartor-
type=cycle,increment =1,intial vlue=1.
go to target file do link sort to outputfile
go to apt_config file
check how many node is their
if it 2 nodes
you just create one more node that means total 3nodes.
while runing a job run on 3 nodes.
you will get output like
1
1
1
2
2
2
3
3
3
4
| Is This Answer Correct ? | 5 Yes | 0 No |
Answer / peeyush sehgal
Take input file like 0 1 2 3 4 5 6 7 8 9
seq -> trans -> seq
in transformer, clear its partitioning and sort the data.
then in stage variable
initialize sv=1
if inputlink%3=0 then sv+1 else sv
populate sv in output column.
| Is This Answer Correct ? | 0 Yes | 0 No |
Enlist various types of routines in datastage.
What is lookup table?
what is time dimension? and how to populate time demension
Drop duplicate records ... SOURCE LIKE .......... ID flag1 flag2 100 N Y 100 N N 100 Y N 101 Y Y 101 N Y 102 Y N 103 N N 104 Y Y 105 N N 106 N Y 102 N Y 105 Y Y in above file if any id having both the flags as "N" then that corresponding id records should be dropped, in above case o/p should be as ID flag1 flag2 101 Y Y 101 N Y 102 Y N 102 N Y 104 Y Y 106 N Y Steps to do : 1) Identified the id’s that got duplicated (both the flag values having vales “N”) 2) Look up with these id’s to existing id’s to drop .
How one source columns or rows to be loaded in to two different tables?
souce file having the columns like name company krish IBM pooja TCS nandini WIPRO krish IBM pooja TCS if first row will be repeat i want the result like this name company count krish IBM 1 pooja TCS 1 nandini WIPRO 1 krish IBM 2 pooja TCS 2
what about data stage requirement
How to remove duplicates in transformer stage? in parallel mode
if a column contains data like ram,rakesh,madhan,suraj,pradeep,bhaskar then I want to place names separated by commas in another columns how can we do?
hi everbody, i have a problem in my project.. Native Error Code: -407 "Assignment of a null value to a not null column" hi everbody, i have a problem in my project.. Native Error Code: -407 "Assignment of a null value to a not null column" i have no idea, what should i do..please help :(
How to read multiple files at different directories using a single Sequential File stage in DS Enterprise Edition
in aggregator , how can i get the sum in readable format