Solved

ms access query - find unmatched

Posted on 2014-01-20
6
265 Views
Last Modified: 2014-01-24
I have 2 linked .dbf tables that I want to check for unmatched entries on 2 fields. Field#1 is a text field in both tables. field#2 is a text field in table#1 which contains a date in the format yyyymmdd. field#2 is a date field in table#2 in the format mm/dd/yyyy.

I need a query that will detect an unmatched entry based on the 2 fields. Don't know how to specify/convert field#2 in table#1 so that I don't get a "type mismatch" error on the 2 date fields.

Source tables cannot be changed.
tks
0
Comment
Question by:jsgould
  • 3
  • 3
6 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
ID: 39795175
part 1: converting text vs date values:
Cdate(field2)   for the text field
or
Format( field, "mm/dd/yyyy")  for the date field

part 2: non-matched entries - you can do with the wizard:
http://office.microsoft.com/en-us/access-help/compare-two-tables-and-find-records-without-matches-HA010205132.aspx#BM2
0
 

Author Comment

by:jsgould
ID: 39795320
how do I construct the query so that the dates are in the correct form when running?
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 39795338
as posted above, use the format function as needed...
0
Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

 

Author Comment

by:jsgould
ID: 39795360
I mean where do I put the functions in the access query ? i.e. Field name, table,criteria, etc..
tks
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 39796361
are you working in a SQL Query Window, or pure sql?
the table names remain as they are, instead of the field name, you put the expression having the function(fieldname) instead of just fieldname
0
 

Author Closing Comment

by:jsgould
ID: 39807459
Thank You.
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

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

Suggested Solutions

In the previous article, Using a Critera Form to Filter Records (http://www.experts-exchange.com/A_6069.html), the form was basically a data container storing user input, which queries and other database objects could read. The form had to remain op…
In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
Familiarize people with the process of utilizing SQL Server stored procedures from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Micr…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

910 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now