Results 1 to 4 of 4
  1. #1
    ballaterach is offline Novice
    Windows 7 64bit Access 2003
    Join Date
    Feb 2014
    Posts
    9

    Sum from part of a field?


    On a report I have customer details including the product they have ordered e.g Growers Choice 2 Min 7 veg £10.00. Is ther a way I can sum all the £ values so I can see what our weekly income will be in total?

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Well, that's not a good way to store data, but I suppose in the report's source query you can separate out the amount with the Mid() function using InStrRev() to find the position of the last space.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    ballaterach is offline Novice
    Windows 7 64bit Access 2003
    Join Date
    Feb 2014
    Posts
    9
    Many thanks for your reply; no my Database is very amateurish but I will try to fathom out how to use your suggestion or maybe a complete rebuild from scratch would be more advantageous

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Well, in general you want to store each component separately: product, quantity and price for example. It's a lot easier to join them together to present on a report or whatever than to try to break them apart. There's also normalization, very important:

    Fundamentals of Relational Database Design -- r937.com
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

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

Similar Threads

  1. Replies: 1
    Last Post: 05-27-2015, 08:57 AM
  2. Part of field matches part of another field
    By fishhead in forum Queries
    Replies: 13
    Last Post: 04-10-2015, 01:54 PM
  3. Query Part of a Field
    By EHittner in forum Queries
    Replies: 1
    Last Post: 01-31-2015, 07:28 PM
  4. Query any part of the field
    By spleewars in forum Queries
    Replies: 1
    Last Post: 05-31-2012, 07:13 PM
  5. Format part of field
    By tylerg11 in forum Forms
    Replies: 2
    Last Post: 01-21-2012, 01:48 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