how do i query Multiple Databases in access?

G

Guest

Help…

I need to create an access database that would query Multiple Paradox
Databases

the Paradox Databases all have the same fields.

the purpose of the access database to check all the Paradox Databases for
any differences from the master and flag and variance with a indicial Paradox
Database.


Dan
:)
 
M

MGFoster

I need to create an access database that would query Multiple Paradox
Databases

the Paradox Databases all have the same fields.

the purpose of the access database to check all the Paradox Databases for
any differences from the master and flag and variance with a indicial Paradox
Database.

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Basically, you're talking about replication. I don't believe Access can
do that w/ Paradox files. The alternative is to run a query that checks
each individual row/column (record/field) value and show rows that are
different. You'd have to use a unique identifier (Primary Key) to
identify each row to be compared.

I'd create a VBA routine (using the TransferDatabase method of the DoCmd
object - see the VBA Help file on TransferDatabase method for examples)
that attaches each Paradox data file to the Access front-end, one at a
time, and run the comparison query.

The query would look something like this, if there were 4 columns
(primary_key, col1, col2, col3) in the comparison tables:

SELECT COUNT(*) AS RowAnomolies
FROM MasterTable As A INNER JOIN AttachedTable As B
ON A.primary_key = B.primary_key
WHERE A.col1 <> B.col1
OR A.col2 <> B.col2
OR A.col3 <> B.col3

You'd change the names of the tables and the columns to whatever your
tables and column names were. You'd change the names and number of
columns in the WHERE clause (IOW, be sure to compare all columns). The
primary key can be more than one column so be sure to include all of the
PK's columns in the JOIN's ON clause.

If the query returned a value > 0 then you'd know that the AttachedTable
didn't match the MasterTable.
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)
** Respond only to this newsgroup. I DO NOT respond to emails **

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBRzY4fIechKqOuFEgEQJuLQCfbAoGmF+h3qqQv5N5h3xnOtYCjOYAoJzQ
SqdTuye+iIJk3j0oH/BYY4HE
=pXKl
-----END PGP SIGNATURE-----
 
G

Guest

MGFoster said:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Basically, you're talking about replication. I don't believe Access can
do that w/ Paradox files. The alternative is to run a query that checks
each individual row/column (record/field) value and show rows that are
different. You'd have to use a unique identifier (Primary Key) to
identify each row to be compared.

I'd create a VBA routine (using the TransferDatabase method of the DoCmd
object - see the VBA Help file on TransferDatabase method for examples)
that attaches each Paradox data file to the Access front-end, one at a
time, and run the comparison query.

The query would look something like this, if there were 4 columns
(primary_key, col1, col2, col3) in the comparison tables:

SELECT COUNT(*) AS RowAnomolies
FROM MasterTable As A INNER JOIN AttachedTable As B
ON A.primary_key = B.primary_key
WHERE A.col1 <> B.col1
OR A.col2 <> B.col2
OR A.col3 <> B.col3

You'd change the names of the tables and the columns to whatever your
tables and column names were. You'd change the names and number of
columns in the WHERE clause (IOW, be sure to compare all columns). The
primary key can be more than one column so be sure to include all of the
PK's columns in the JOIN's ON clause.

If the query returned a value > 0 then you'd know that the AttachedTable
didn't match the MasterTable.
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)
** Respond only to this newsgroup. I DO NOT respond to emails **

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBRzY4fIechKqOuFEgEQJuLQCfbAoGmF+h3qqQv5N5h3xnOtYCjOYAoJzQ
SqdTuye+iIJk3j0oH/BYY4HE
=pXKl
-----END PGP SIGNATURE-----
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top