Print Page | Close Window

"AutoValue" in Ms Access

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: General Discussion
Forum Description: General discussion and chat on any topic.
URL: https://forums.webwiz.net/forum_posts.asp?TID=13081
Printed Date: 28 March 2026 at 2:24am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: "AutoValue" in Ms Access
Posted By: Amateur
Subject: "AutoValue" in Ms Access
Date Posted: 22 December 2004 at 7:34am
Hi all,
 
I am wondering if anyone knows how to create an "AutoValue" in Ms Access. To take as an example, when a ne record is added, a particular field is incremented from R001 to R002. I am aware of auto number but this doesnt allow for characters, only numbers.
 
Anyone know how to do the above?



Replies:
Posted By: dj air
Date Posted: 22 December 2004 at 11:48am
the only real easy way i can think is opening a query to get the last records ID value then use a temp value of the veriable,

say trim the left side off... CLNG the rest and then +1 and recreate the veriable. and add it into the record as the Primary key with required.

Just an idea. there might be an easier better way.


Posted By: Amateur
Date Posted: 05 January 2005 at 10:54am
I have come up with another way that would solve my problem, help is needed though!
 
I was wondering how i could do the following in MS Access. I want a field called ref to automatically contain the same value as the primary key which is called Pid when a record is entered. Is this possible and if so, how?
 
Thanks.


Posted By: Mart
Date Posted: 05 January 2005 at 11:32am
In SQL Server it is @@IDENTITY, in access I am not sure



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net