Results 1 to 4 of 4
  1. #1
    Join Date
    Jul 2011
    Location
    Denmark
    Posts
    2

    Unanswered: Helping changing an access template database

    Hi!

    In my 2007 Microsoft Access it has a template called Project, which I am using for a business I am starting.

    For the project ID numbers it wont let me manually change the ID number, and each ID number starts automatically at 1. I need the ID numbers to start at 2011001, and the next one is called 2011002 and so on and so forth, and when the year ends I need to be able to change it so it is called 2012001...

    Any ideas of how to change that?

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    enter it yourself
    I'd rather be riding on the Tiger 800 or the Norton

  3. #3
    Join Date
    Jul 2011
    Location
    Denmark
    Posts
    2
    Quote Originally Posted by healdem View Post
    enter it yourself
    Thats the point...it wont let me... :-(

  4. #4
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    so change the underlying table
    for the relevant column
    remove autonumber
    leave it as a primary key
    consider if you want to put a table level validation rule
    eg >= 2010xxx and less than, say 2020xxx
    where xxx is the number of digits,if you use 3 digits then that would be >- 2010000 and <= 2020999

    OR

    leave well alone and add a new column which you add the project number. as the year prefix is derived you could just enter the suffix eg 1,2,3...999

    that means you will have to do changes to the rest of the template to bring that number through.

    if you do decide to roll your own project number then consider putting in some code to allocate the next available project number for that year.

    as an alternative tell who ever came up with the idea of using the year of the project as part of the project number to rethink that.
    I'd rather be riding on the Tiger 800 or the Norton

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •