on 09-29-2015 7:21 AM
Hi ,
I have a source column datatype as date and target also date .
my source date column is in dd.mm.yyyy format and i wanted to change to ddmmyyyy format in target .
Db used here is MSsql
i have tried many options and nothing is working.
please advise.
If both source are target columns are really dates then no explicit conversion at all is needed! Every database has its own internal binary format for storing date and datetime fields. DS automatcially recognises those and takes care of the conversion internally.
The external format has nothing to do with the internal storage, that's only how you huh... externalise it.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Repeat: if both fields are dates in a database, your source data is not in 'dd.mm.yyyy' format and your target data is not in 'ddmmyyyy'. Databases typically store dates (just like numbers) in an internal binary format.
When you want your dates in an external (text!) format use the to_char built-in function with a format string. When you want to convert dates in text format to the internal representation use to_date built-in function with a format string.
Please use this Function Module
CONVERSION_EXIT_SDATE_INPUT
i.e:
Give input = 01.02.2015
then the output wil be = 20150201
Or please have a look.
Regards:
Usman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.