Solved

Append from Access to SQL failing on date fields.

Posted on 2011-03-09
3
362 Views
Last Modified: 2012-05-11
Hello,

I'm moving an Access database to SQL using the Wizard.  All the tables convert OK apart from two.  I've discovered it is related to date fields - if I copy the tables, remove all the date fields and then try it works fine.

I've tried migrating just the table structure and using an append query but this errors with an "Overflow" message.  Again if I do the same with the date fields removed it works.

Can anyone suggest a solution for this.

Thanks


0
Comment
Question by:Petermcg001
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 13

Expert Comment

by:devlab2012
ID: 35085103
in sql convert dates to a string in the format yyyy-mm-dd. In sql this format always works fine. Also, check between smalldatetime and datetime data types in sql server.
0
 
LVL 77

Accepted Solution

by:
peter57r earned 500 total points
ID: 35085119
So the problem is with he data values , not with the structure?

SQL Server ha a narrower range of acceptable dates than Access.  If you have dates in Access before 1753 these will not convert to sql server.  Access goes back to year 100.
0
 
LVL 1

Author Comment

by:Petermcg001
ID: 35085621
It was data related with some very silly dates in the table.  Feel pretty silly TBH!
0

Featured Post

Get MongoDB database support online, now!

At Percona’s web store you can order your MongoDB database support needs in minutes. No hassles, no fuss, just pick and click. Pay online with a credit card. Handle your MongoDB database support now!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question