Re: to create a Query with 2 Tables

From: Gary Walter (garylwpleasenospam_at_wamego.net)
Date: 04/14/04


Date: Wed, 14 Apr 2004 08:37:40 -0500

Hi Markus,

Sorry, union queries are not updateable.

Have you thought about setting up
a form bound to Main table and a
subform bound to Purge table?

Possibly each table relates to each
other in some master/child relationship;
or you set up no master/child relationship,
but on the Purge subform you have some
search combo that would show relevant
Purge data based on what record was
currently being shown in the Main form.

A general rule of thumb is you edit data
in a form, not a query view anyway. Queries
provide sources for forms or reports. If possible,
I suggest using the power of form/subform to
get the job done.

Good luck,

Gary Walter

"Markus Mortsiefer" <mmortsie@ford.com> wrote
> Hallo
>
> I want to say thank you its working well the only thing I have seen is that
> I can now not change the data is there a way I can do this but it allows me
> to still change the data even they are in two different tables but the
> record will either be in the one or the other table never in both the at the
> same time
>
> Best regards
>
> Markus
>
> "Gary Walter" <garylwpleasenospam@wamego.net> wrote in message
> news:udh4T8WIEHA.2300@tk2msftngp13.phx.gbl...
> >
> > "MDW" <anonymous@discussions.microsoft.com> wrote
> > > If you columns are in the same order for both tables:
> > >
> > > SELECT * FROM [Main Table]
> > >
> > > UNION
> > >
> > > SELECT * FROM [Purge Table]
> >
> > PMFBI
> >
> > If some record erroneously occurs in
> > both tables, you won't see that unless
> > you use
> >
> > UNION ALL
> >
> > (plus it is faster).
> >
> > And I might want to know where
> > each record comes from
> >
> > SELECT "Main" AS WhichTable, * FROM [Main Table]
> > UNION ALL
> > SELECT "Purge", * FROM [Purge Table]
> >
> > Apologies again for butting in.
> >
> > Gary Walter
> >
> >
>
>