logic required
Posted: Tue Aug 26, 2014 5:32 pm
hi,
I am using the db2 stage to extract the using the query to fetch the records from column using the logic expression
YEAR(TO_DATE(AUC_SALE_DATE,'yyyy-mm-dd')) || '-' || WEEK(TO_DATE(AUC_SALE_DATE,'yyyy-mm-dd'))
the results from this query coming as
2012-5
2012-44
2011-47
2012-18
2013-32
I want the last two numbers of first field like 2012-05 instead of 2012-5 .
the design of job is
db2 stage................xfm...................seqfile
in tried with following way in transformer
right((0:AUC_SALE_DATE),2) but not getting the right result like 2012-50 can you please help me about this.
I am using the db2 stage to extract the using the query to fetch the records from column using the logic expression
YEAR(TO_DATE(AUC_SALE_DATE,'yyyy-mm-dd')) || '-' || WEEK(TO_DATE(AUC_SALE_DATE,'yyyy-mm-dd'))
the results from this query coming as
2012-5
2012-44
2011-47
2012-18
2013-32
I want the last two numbers of first field like 2012-05 instead of 2012-5 .
the design of job is
db2 stage................xfm...................seqfile
in tried with following way in transformer
right((0:AUC_SALE_DATE),2) but not getting the right result like 2012-50 can you please help me about this.