Select all except 2 fields

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is it possible to Select * except fieldA & fieldB?
I have a number of regional database and need to transfer all additons edits
and changes into a central master. Currently I have duplicates of all my
tables with the additional fields of ChangeType and ChangeDate every time
data is added edited or deleted it is written both to the main table and to
the update table with the additional information added.

I then have an export button so that once a month the update tables are
exported, and emailed to the gatekeeper of the master database. The plan was
to include an import/update button whereby the program will cycle through the
tables sorted in order by ChangeDate and append ChangeType 'Add', edit
ChangeType'Edit' and delete ChangeType 'Delete'.

All was going well until I began working on the generic import button and
suddenly realised I couldn't just append or rewrite a record because my
import table has 2 extra fields to the main table.

I'm thinking I could copy an update table out to 3 seperate temporary tables
ie all the Add data all the Edits and all the deletes and then delete the 2
extra fields before appending or rewriting. Sounds like "Hard Way Harry" to
me but probably easier than writing a separate select statement for every
table.

Any suggestions
Cheers
Teewan
 
There's no "except" capability. You'll have to list all of the fields you
want, rather than using *.
 
Thanks Doug
Really was afraid that was what the response would be. Oh well, I like
coding don't I ! That's why I'm doing it.

Cheers
 
Why can't you use an append query? Just select the fields you want from the
source table and append them to the target table. The column names, column
order, column count of the two tables can all be different.
 
Back
Top