Transform yyyy-m-d to yyyy-mm-dd
Posted: Fri Jan 11, 2008 3:38 am
Hi,
I'm new to DataStage and have an issue regarding a transform.
All my job has to do is load a .csv file into an SQL2000 tabel.
File consists of temperature measures by day:
2007-1-1; 30
2007-1-2; 34
2007-1-3; 29
2007-1-4; 24
...
Problem is that I encouter the following error message when trying to insert all values in the table:
"[DataStage][SQL Client][ODBC][Microsoft][ODBC SQL Server Driver]Invalid character value for cast specification"
I think I know the problem since only the records conaining a date of format yyyy-mm-dd are inserted.
So in my transform stage I should transform 2007-1-1 to 2007-01-01.
How should I transform this???
Thnks!!!!
I'm new to DataStage and have an issue regarding a transform.
All my job has to do is load a .csv file into an SQL2000 tabel.
File consists of temperature measures by day:
2007-1-1; 30
2007-1-2; 34
2007-1-3; 29
2007-1-4; 24
...
Problem is that I encouter the following error message when trying to insert all values in the table:
"[DataStage][SQL Client][ODBC][Microsoft][ODBC SQL Server Driver]Invalid character value for cast specification"
I think I know the problem since only the records conaining a date of format yyyy-mm-dd are inserted.
So in my transform stage I should transform 2007-1-1 to 2007-01-01.
How should I transform this???
Thnks!!!!