Link to home
Start Free TrialLog in
Avatar of Fordraiders
FordraidersFlag for United States of America

asked on

linked sql server tables repeating time entries in access views

Access 2010
Linked sql server tables

Let me start by saying this question has nothing to do with duplicate data.
DATETIME fields repeating data for entries.


I have something strange that started recently.
When I view the Linked tables in Access.
It displays the data : as shown below...for a repeated  ID

User generated image
in sql server  this is correct...( second entry)

User generated image
not so concerned about the military time..but...the entries in Access are repeating...
if i had 5 entries..
they would all be the same ?

or maybe military time is causing the problem ?




Thanks
fordraiders
Avatar of Gustav Brock
Gustav Brock
Flag of Denmark image

I guess you should add a Timestamp field to the table to not confuse the ODBC driver.
The "military" style - the ISO format - is just the default display form of SQL Server, while Access uses the local settings from Windows.
How about refreshing the records...what if you retrieve the records using  a passthrough query ?
Not enough information, need to see the query that gathers the blue-lines with duplicate-dates.

My first guess would be that the two lines in blue are using the same date-field twice, and the correct SQL server result-set is using two different date-fields.
Avatar of Fordraiders

ASKER

I needed a primary key in my table . I created a unique key field and worked fine.
Primary Keys and the timestamp fields are considered prerequisite when we do Access to SQL linkage...
Are you using a query with an Order By clause in BOTH situations?  Tables are unordered sets of data and Access may be seeing different records than you see when you open the table in DS view.  The only way to be absolutely certain is to use the exact same query AND Sort Order from Access and from SSMS.
Pat, thanks i double checked...
primary key issue
ASKER CERTIFIED SOLUTION
Avatar of PatHartman
PatHartman
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks
You're welcome