Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Transfer Datetime field from MS-Access to SQL server?

Transfer Datetime field from MS-Access to SQL server?

Scheduled Pinned Locked Moved Visual Basic
databasesql-serversysadminhelptutorial
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    NetRams
    wrote on last edited by
    #1

    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.

    G 1 Reply Last reply
    0
    • N NetRams

      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.

      G Offline
      G Offline
      GuyThiebaut
      wrote on last edited by
      #2

      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

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups