Page 1 of 1

date error

Posted: Tue Oct 10, 2006 9:04 am
by ravindrag
i have a datecolumn 2055/12/09 with date datatype i have to populate to target datatype timestamp i.e to MSOLEDB but it is comming as 2055/00/00 i have tried 2055/00/00 : " " : Oconv( Time(), "MTS:" ) and
2055/00/00 :00:00:00 but it is not working

2.And i have to check a date if it is valid i have to load to target date datatype is date(8)


thanks in advance

Posted: Tue Oct 10, 2006 9:22 am
by kris007
From what it looks like your date datatype is of length 8 and you are trying to insert data whose length is greater than that. That is where you will need to look at. or are your point 1 and 2 two different scenarios?

Posted: Tue Oct 10, 2006 10:58 am
by DSguru2B
What is your source and target???
The date format seems to be ok.And if Oconv(Time(), MTS) is giving you all zeros, then there is something else going on. Try loading the output to a flat file and check the format.

Posted: Tue Oct 10, 2006 12:40 pm
by diamondabhi
Might as well try 2055/00/00:" ":"00:00:00"

Posted: Tue Oct 10, 2006 2:04 pm
by ray.wurlod
2055/00/00 is not a date. Maybe that's the issue. Try 2055/01/01.

Posted: Tue Oct 10, 2006 10:10 pm
by ravindrag
first and second points are different scenarios my source is sequential file and target is msoledb stage. when iam loading to flatfile it is working fine but it is coming as 2500/00/00 :00:00 when i am loading to database stage

Posted: Wed Oct 11, 2006 1:18 am
by ray.wurlod
Then, clearly, there is something amiss with your derivation. Please post the derivation expression you used.