Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6635081
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T23:00:24+00:00 2026-05-25T23:00:24+00:00

Any help that can be provided to a Access and VB noob would be

  • 0

Any help that can be provided to a Access and VB noob would be greatly appreciated. What I’m trying to do is concatenate the values from one table and insert it as a comma delimited value into a field in another table. I’m trying to take all the server names that are say Linux boxes and concatenate them into a different field.

Table A looks like this

Machine Name | Zone   | Operating System
----------------------------------------
Server01      Zone A    Linux
Server02      Zone B    Linux
Server03      Zone A    Windows
Server04      Zone C    Windows
Server05      Zone B    Solaris

Table B has the field I want to insert into: Affected_Machine_Names.

Now, I’ve tried looking through the Concatenate/Coalesce posts, but the SQL view in Access doesn’t like the Declare statements. My VB skills suck badly and I can’t seem to get the code to work in VB for Applications. Unfortunately, I can’t get this database converted into our SQL farm cause I don’t have a server available at the moment to host it.

Can anyone point me in the right direction?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T23:00:25+00:00Added an answer on May 25, 2026 at 11:00 pm

    You can use Concatenate values from related records by Allen Browne for this. Copy the function code from that web page and paste it into a new standard module. Save the module and give the module a name different from the function name; modConcatRelated would work.

    Then I think you should be able to use the function in a query even though you’re not proficient with VBA.

    First notice I changed the field names in TableA to replace spaces with underscores. With that change, this query …

    SELECT
        sub.Operating_System, 
        ConcatRelated("Machine_Name", "TableA", 
            "Operating_System = '" & sub.Operating_System & "'") AS Machines
    FROM [SELECT DISTINCT Operating_System FROM TableA]. AS sub;
    

    … produces this result set:

    Operating_System Machines
    Linux            Server01, Server02
    Solaris          Server05
    Windows          Server03, Server04
    

    If you can’t rename the fields as I did, use a separate query to select the distinct operating systems.

    SELECT DISTINCT TableA.[Operating System]
    FROM TableA;
    

    Save that as qryDistinctOperatingSystems, then use it in this version of the main query:

    SELECT
        sub.[Operating System], 
        ConcatRelated("[Machine Name]", "TableA", 
            "[Operating System] = '" & sub.[Operating System] & "'") AS Machines
    FROM qryDistinctOperatingSystems AS sub;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

can any one help me with code that subtract 1 from a digit stored
Is there any program code that can help me to pop up the virtual
Is there any method that can help me track internet usage by application? I
Wondering if there is any tool that can help me to detect a pronoun's
Do any libraries or other development resources exist that can help reduce the effort
I'm looking for any beyond basic resources that can help me to be proficient
Are there any tools/libraries on Windows that can help me tarck down the culprit?
Just a curious question but is there any programs that can help/aid you when
I want to disable camera flash. How can I do that? Any help will
can any body help me on separating this example of data that i need

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.