Results 1 to 7 of 7
  1. #1
    fekrinejat is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Jan 2013
    Posts
    29

    Calculated filed in Access 2007

    Hi
    I need to make a calculated filed in access 2007,
    actually i have two date fileds which have to be calculated and inserted
    in separate column , it's possible by Access 2010 but


    i can't do it in 2007

    Please Help me
    Thanks

  2. #2
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    I think we need more details.
    Calculated fields are done in queries.
    Do you know how to write expressions (calculated fields) in queries?

  3. #3
    fekrinejat is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Jan 2013
    Posts
    29
    For Example we have two fields named (Enter_Time , Exit_Time) for each person

    exp:

    Enter_Time ==> 8:30
    Exit_Time ==> 14:00

    i need to put 5:30 which is 14:00 - 8:30 (duration time) in other field
    and then i can make query on calculated filed
    any better idea ?

  4. #4
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    You don't actually store the calculation in a field in a table, but rather do the calculation in the query itself.
    If some value can be calculated, there is no reason to store the calculation in a table (and it actually violates rules of normalization to do so).

  5. #5
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    Perhaps you are referring to the new Calculated Data Type field that Access offers in versions newer than 2010 (see: http://www.quepublishing.com/article...aspx?p=1594884).
    Unfortunately, Access 2007 does not have that. So you can also store the values of calculations, but not the calculations themselves in tables. Which goes to my comments about queries...

    So if you are using Access 2007, you won't be able to store the calculations in tables.

  6. #6
    fekrinejat is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Jan 2013
    Posts
    29
    anyway .. How can i get the above scenario done ?
    without calculated filed ..

  7. #7
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    I don't understand.
    How do you think you can perform a calculation without doing a calculation?

    As I said and referenced, you CANNOT store calculations in table fields in Access 2007. So if you are trying to do this in Access 2007, I am afraid you are limited to doing it in a query, or to try to use VBA. But you would have to have some event trigger the VBA. It won't be automatic if they update the table directly.

    What's the big hang-up on doing it in a query anyway?

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

Similar Threads

  1. Export Table in Access 2007 to Multiple Workbooks in Excel 2007
    By hutchinsm in forum Import/Export Data
    Replies: 5
    Last Post: 03-01-2012, 05:23 PM
  2. Ms Access 2007 report export to excel 2007
    By Stan2man in forum Access
    Replies: 6
    Last Post: 11-23-2011, 01:24 PM
  3. Linking Access 2007 to Outlook Calender 2007
    By izzygrace3 in forum Programming
    Replies: 1
    Last Post: 11-10-2011, 11:53 PM
  4. Replies: 2
    Last Post: 06-18-2011, 09:55 AM
  5. Replies: 0
    Last Post: 11-17-2009, 02:35 PM

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