Results 1 to 2 of 2
  1. #1
    congamond is offline Novice
    Windows 8 Access 2010 32bit
    Join Date
    Jan 2014
    Posts
    1

    Concatenation of Access Fields.

    Hello,



    I have the following data:

    Tax_ID Store_ID Last4_CC
    1111 222 6789
    1122 234 1234
    1122 245 1234
    1124 678 7890
    1124 890 8900

    A tax ID can have 1 to 1 or 1 to many stores and each store can have the same credit card number or each store could have their own credit card number. The output will break on a change in credit card number and/or store. I need to concatenate store_id in a new field if the credit card and tax id are the same, also capture the number of stores concatenated. like example 2.

    Any help would be greatly appreciated.

    Thank you, Brian

    Report output needs to look like:


    example 1.


    Tax ID: 1111
    Number of Stores: 1
    Store ID: 222

    example 2.
    Tax ID: 1112
    Number of Stores: 2
    Store ID: 234, 245

    example 3.
    Tax ID: 1124
    Number of Stores: 1
    Store ID: 678

    Tax ID: 1124
    Number of Stores: 1
    Store ID: 890

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,972
    Could just do report using Grouping & Sorting features with aggregate calc in group footer. Set up group on TaxID, StoreID in Detail section, Count(*) in group footer textbox. Otherwise, need VBA code. Review: http://allenbrowne.com/func-concat.html
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. concatenation issue
    By SuicidalDriver in forum Queries
    Replies: 11
    Last Post: 07-31-2013, 04:42 AM
  2. Two-color concatenation?
    By KDTom in forum Forms
    Replies: 2
    Last Post: 02-01-2013, 03:13 PM
  3. Concatenation
    By Rhubie in forum Access
    Replies: 3
    Last Post: 08-30-2012, 05:09 PM
  4. Field concatenation
    By Trojnfn in forum Access
    Replies: 1
    Last Post: 10-10-2011, 05:56 PM
  5. Query and Concatenation
    By Try2Live4God in forum Programming
    Replies: 2
    Last Post: 05-25-2010, 03:45 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