Transfer Datetime field from MS-Access to SQL server?
-
Hi, I need to transfer data from MS-Access db to SQL server db. I am having the date/time field in MS-Access with format as "mm/dd/yyyy h:nn:ss AM/PM". Having the field in SQL server as datetime. For eg, If I store current datetime - in MS-Access it will be like this "15/06/2007 7:07:17 PM", when i try to update it in SQL server it gives error as "The conversion of a char data type to a datetime data type resulted in an out-of-range datetime value." How to solve this. Rams.
Be simple and Be sample.
-
Hi, I need to transfer data from MS-Access db to SQL server db. I am having the date/time field in MS-Access with format as "mm/dd/yyyy h:nn:ss AM/PM". Having the field in SQL server as datetime. For eg, If I store current datetime - in MS-Access it will be like this "15/06/2007 7:07:17 PM", when i try to update it in SQL server it gives error as "The conversion of a char data type to a datetime data type resulted in an out-of-range datetime value." How to solve this. Rams.
Be simple and Be sample.
My guess is that SQL server is seeing 15/06/2007 as an American date i.e. the 6th day of the 15th month of 2007. Check how you have your dates set up on SQL Server - are they set up as defaulting to mm/dd/yyyy? Also how are you moving the data to SQL Server - DTS package, flat file, import wizard? If you can let me know how you are transfering the data I can probably give you more specific help. Regards Guy Cambridge UK You always pass failure on the way to success. -- modified at 12:04 Saturday 16th June, 2007