
28-Jul-2006, 08:42 AM
|  | Guest | | | | | | | | | | Make Table Query and AutoNumbers Hi, I can't find an answer that is quite right for this but there must
be a way to do it. Very simply, I have a make table query that is run Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/information-technology/14042-make-table-query-and-autonumbers.htmlReference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=14042
monthly. I want the resulting table to have an autonumber field -
which later on becomes part of a key for the line item. In the
meantime though, I can't make the autonumber field any way but
manually.
This field should be created automatically when I run the macro that
runs all of my queries. Barring a delete and then append query, how do
I do it?
Thanks! *
Do share your immediate thoughts or reactions on this issue? We value your views! Login Now! or Sign Up Today! to share your views with us.. Gurfateh! | 
28-Jul-2006, 08:42 AM
|  | Guest | | | | | | | | | | Re: Make Table Query and AutoNumbers Nicholajlg wrote:
> Hi, I can't find an answer that is quite right for this but there must
> be a way to do it. Very simply, I have a make table query that is run
> monthly. I want the resulting table to have an autonumber field -
> which later on becomes part of a key for the line item. In the
> meantime though, I can't make the autonumber field any way but
> manually.
>
> This field should be created automatically when I run the macro that
> runs all of my queries. Barring a delete and then append query, how do
> I do it?
>
> Thanks!
A delete, then an append query is about it I'm afraid. AutoNumbers aren't
the only data type that might not come out the way you want with a MakeTable
query. They generally should not be used in a production application, but Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=14042
only for one-off development stuff.
--
Rick Brandt, Microsoft Access MVP
Email (as appropriate) to...
RBrandt at Hunter dot com Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=14042 | 
28-Jul-2006, 08:42 AM
|  | Guest | | | | | | | | | | Re: Make Table Query and AutoNumbers What is the danger in using autonumbers in production? Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=14042
Rick Brandt wrote:
> Nicholajlg wrote:
> > Hi, I can't find an answer that is quite right for this but there must
> > be a way to do it. Very simply, I have a make table query that is run
> > monthly. I want the resulting table to have an autonumber field - Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=14042
> > which later on becomes part of a key for the line item. In the
> > meantime though, I can't make the autonumber field any way but
> > manually.
> >
> > This field should be created automatically when I run the macro that
> > runs all of my queries. Barring a delete and then append query, how do
> > I do it?
> >
> > Thanks!
>
> A delete, then an append query is about it I'm afraid. AutoNumbers aren't
> the only data type that might not come out the way you want with a MakeTable
> query. They generally should not be used in a production application, but
> only for one-off development stuff.
>
> --
> Rick Brandt, Microsoft Access MVP
> Email (as appropriate) to...
> RBrandt at Hunter dot com | 
28-Jul-2006, 08:42 AM
|  | Guest | | | | | | | | | | Re: Make Table Query and AutoNumbers Nicholajlg wrote:
> What is the danger in using autonumbers in production?
Not AutoNumbers, MakeTable queries.
--
Rick Brandt, Microsoft Access MVP
Email (as appropriate) to...
RBrandt at Hunter dot com | 
28-Jul-2006, 08:42 AM
|  | Guest | | | | | | | | | | Re: Make Table Query and AutoNumbers "Nicholajlg" wrote in message <1154011793.566593.315160@m73g2000cwd.googlegroups. com>:
> Hi, I can't find an answer that is quite right for this but there
> must be a way to do it. Very simply, I have a make table query that
> is run monthly. I want the resulting table to have an autonumber
> field - which later on becomes part of a key for the line item. In
> the meantime though, I can't make the autonumber field any way but
> manually.
>
> This field should be created automatically when I run the macro that Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=14042
> runs all of my queries. Barring a delete and then append query, how
> do I do it?
>
> Thanks!
The counter keyword. Have a look in this reference for more info http://msdn.microsoft.com/library/de...l/acintsql.asp
(watch for linebreaks)
CREATE TABLE MyTable (id COUNTER PRIMARY KEY,
MyNextField TEXT(25) NOT NULL UNIQUE, ...)"
Though, I agree there is seldom need to create tables on the fly.
--
Roy-Vidar | 
Support Us! Become a Promoter! | | Gurfateh ji, you can become a SPN Promoter by Donating as little as $10 each month. With limited resources & high operational costs, your donations make it possible for us to deliver a quality website and spread the teachings of the Sri Guru Granth Sahib Ji, to serve & uplift humanity. Every contribution counts. Donate Generously. Gurfateh! | (View-All)
Members who have read this thread : 0
| | There are no names to display. | |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | | | | Tools | Search | | | | | Display Modes | Linear Mode |
Posting Rules
| You may not post new threads You may not post replies You may not post attachments You may not edit your posts HTML code is On | | | | » Gurbani Jukebox | Listen to Gurbani while surfing SPN! | » Active Discussions | | | | | | | ਨਾਮਾ Today 06:37 AM 2 Replies, 53 Views | | | | | | | | | | | | | | | | | | | | | | | » Books You Should Read... | | | |