Results 1 to 3 of 3
  1. #1
    insixt is offline Novice
    Windows XP Access 2007
    Join Date
    Sep 2009
    Posts
    6

    Only positive values in random auto-numbers.

    Hello all .


    I have a table where I would like the primary key to be automatically generated by Microsoft Access. At present I have the field set to Auto Number(Random) and Long Integer. Unfortunately this gives me both positive and negative values. How can I get Access to just return positive numbers (I do not wish for the number to be incremented - I need random.)


    Thanks for reading and I hope you can help!

  2. #2
    dcrake's Avatar
    dcrake is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    435
    What difference does it make if the numbers are pos or neg? PK's are PK's and are only used internally to identify relationships. And why must you have ramdom?

    David

  3. #3
    insixt is offline Novice
    Windows XP Access 2007
    Join Date
    Sep 2009
    Posts
    6
    Cheers for your reply. I just realised I can use negative values after all! Thanks again.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Random numbers
    By Gator777 in forum Access
    Replies: 3
    Last Post: 08-12-2009, 10:04 AM
  2. Suming Positive Numbers Only
    By jbarrum in forum Access
    Replies: 5
    Last Post: 04-24-2009, 03:51 PM
  3. Matching positive with negative amounts
    By cwert11 in forum Access
    Replies: 1
    Last Post: 09-29-2008, 12:26 AM
  4. random record
    By wasim_sono in forum Programming
    Replies: 1
    Last Post: 02-06-2008, 02:42 PM
  5. generating random numbers on form
    By anitra in forum Forms
    Replies: 1
    Last Post: 02-14-2006, 10:08 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums