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 6082793
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T11:19:44+00:00 2026-05-23T11:19:44+00:00

EDIT: I’m using MySQL, InnoDB. I have some trouble with the below: My tables

  • 0

EDIT: I’m using MySQL, InnoDB.

I have some trouble with the below:

My tables are user, user_matrix, user_parts.

user:  
id, username

user_matrix:  
userid, partcode

user_parts:  
id, label, partcode

What I’m trying to do is join these into a single query, where the following data:

user:  
1, zenph

user_matrix:  
1, abc  
1, def  
1, ghi  

user_parts  
1, arms, abc  
2, legs, def  
3, head, ghi

..results in a user, with the parts as the array for each row. Is this possible? I’ve tried but I keep retuning a single user_parts row per user row. I need the entire related rows. The output should be:

1, zenph, array(  
  array(1,arms,abc),  
  array(2,legs,def),  
  array(3,head,ghi)  
)

Appreciate ANY help. I’m currently reading up what I can but I just can’t get my head around this particular situation.

  • 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-23T11:19:44+00:00Added an answer on May 23, 2026 at 11:19 am

    This would likely necessitate using a cursor to loop through the parts and add them to an array/delimited string. We would need to know what DBMS you are using to provide any code examples.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Edit: I have solved this by myself. See my answer below I have set
Edit: The below question was answered by this . I have a new updated
EDIT: Link should work now, sorry for the trouble I have a text file
EDIT: Note. I should have mentioned I'm not interested in using the .Select, DataRowView,
edit #2: Question solved halfways. Look below As a follow-up question, does anyone know
Edit: This was accidentally posted twice. Original: VB.NET Importing Classes I've seen some code
Edit: I would like to model a 1 to 0:1 relationship between User and
EDIT: Changed as I have a different issue with the same code 2nd Edit:
EDIT: Sorry about ellipsis that's not what I actually have. For declaring an array
EDIT: I have reworded the title question slightly, and adjusted the text to respond

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.