Results 1 to 4 of 4
  1. #1
    Join Date
    Feb 2007

    Unanswered: Access table question

    Can you assign the default value of a field in a table to a tempvar or global variable?


  2. #2
    Join Date
    May 2008
    Raleigh, NC
    Hi Bill,
    If you mean in the actual 'design' mode of creating the table then no. The default value will be limited to column type you designate it as.

    Hope this helps.
    --If its free, take it for what its worth!

  3. #3
    Join Date
    Jan 2007
    Provided Answers: 10
    Very good answer

    Can you explain why you would want to do this; because there is a possible solution, but it's not a very good one!
    Home | Blog

  4. #4
    Join Date
    Feb 2007

    Thumbs up

    Well, I have the user login and then I store their userid into a tempvar. When a record is created in the userselects table I need to have the userid field set to that userid each and everytime. However, this record is automatically created when the user clicks on the check box to show the record as selected. Anyway, what I did is to create a function that I'm using in a query to relate the LeaseInfo table and the UserSelects table together. This gives me the ability to allow multiple users to select records and keep them selected while other users keep their selections from the same table. Is you look at the posting titled "Mutli-user record selections in Access" you will hopefully understand what I was trying to accomplish.

    All is good though now. I just had to whiteboard it for awhile.

    Thanks for all of the input everyone.


Posting Permissions

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