RE: [ACFUG Discuss] Database incremental Counter

2008-03-12 Thread Paul Morton
PM To: discussion@acfug.org Subject: RE: [ACFUG Discuss] Database incremental Counter Couldn't you create a small stored procedure that will actually run the select and subsequently increment the number? Therefore you simply can the stored procedure which in turn will return the record(s) yo

RE: [ACFUG Discuss] Database incremental Counter

2008-03-12 Thread McTure, Greg
EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Paul Morton Sent: Wednesday, March 12, 2008 6:38 PM To: discussion@acfug.org Subject: RE: [ACFUG Discuss] Database incremental Counter Thanks Greg, I'm not looking to create a table full of records, which is what is required to use th

RE: [ACFUG Discuss] Database incremental Counter

2008-03-12 Thread Paul Morton
6 449-3151 w: www.mortonint.com _ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of McTure, Greg Sent: Wednesday, March 12, 2008 4:12 PM To: discussion@acfug.org Subject: RE: [ACFUG Discuss] Database incremental Counter Hi Paul: There are a few functional ways yo

RE: [ACFUG Discuss] Database incremental Counter

2008-03-12 Thread McTure, Greg
Hi Paul: There are a few functional ways you could do this; however, for the sake of simplicity and quick implementation, I would consider using an IDENTITY column with an INT or NUMERIC data type. That will function just like the auto num column for primary keys in an Access database. You

RE: [ACFUG Discuss] Database incremental Counter

2008-03-12 Thread Paul Morton
Howard, Thanks. I like the idea of doing it with a trigger. Paul _ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Howard Fore Sent: Wednesday, March 12, 2008 11:02 AM To: discussion@acfug.org Subject: Re: [ACFUG Discuss] Database incremental Counter

Re: [ACFUG Discuss] Database incremental Counter

2008-03-12 Thread Howard Fore
Barring some other requirement that dictates otherwise, you'd be better off to keep the incrementing function on the database. Use an insert trigger on the table to update the row or make the field autoincrementing. Howard On Wed, Mar 12, 2008 at 12:45 PM, Paul Morton <[EMAIL PROTECTED]> wrote: