July 1, 2009 at 7:10 am
Hi friends,
I want to update the Flat file column b4 using it into the data flow task.
For ex : I have a flat file which has months column having values jan,feb, mar so on, i want to update the flat file (.txt) b4 using it as a source in the data flow task.Months should be represented as numbers like for jan replaced by 1, feb replaced by 2 ..... in the flat file.
numerical values(Reference values) can be taken from table.
can anyone help with code used in the Script task
please,
Thanks in advance
Arvind
July 1, 2009 at 8:18 am
I think there is a better way..
As a matter of fact I can think of two..
First way (best):
1. Build a table that contains the text values and the id of the month
MonthId, MonthAbbr
1 Jan
2 Feb
etc..
2. In the Dataflow use the lookup dataflow transformation, use the Month Abbreviation to output the MonthId.
Second way (ok):
1. Use the derived column dataflow transformation and build an if/then/else kind of logic in the expression, not pretty..
CEWII
July 1, 2009 at 1:38 pm
Thanks CIWII for the reply. This is easier way to do it.:-):-)
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy