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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T01:31:55+00:00 2026-06-18T01:31:55+00:00

I have read all the related questions but could not get this simple thing

  • 0

I have read all the related questions but could not get this simple thing working. I’d like to concatenate the results of this query:

SELECT DISTINCT ord.uid AS u
  FROM  `uc_order_products` ord_prod,  `uc_orders` ord,  `uc_roles_expirations` re
WHERE ord.order_id = ord_prod.order_id
  AND ord_prod.title LIKE  '2012. évi%'
  AND ord.uid NOT 
IN (SELECT uid FROM uc_roles_expirations re)

It looks like this:

U
----
1234
1235
...

This is what I tried:

SELECT GROUP_CONCAT(DISTINCT ord.uid AS u
  FROM  `uc_order_products` ord_prod,  `uc_orders` ord,  `uc_roles_expirations` re
WHERE ord.order_id = ord_prod.order_id
  AND ord_prod.title LIKE  '2012. évi%'
  AND ord.uid NOT 
IN (SELECT uid FROM uc_roles_expirations re) SEPARATOR ',')

..and did not work. Could you help me?

  • 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-06-18T01:31:57+00:00Added an answer on June 18, 2026 at 1:31 am

    only the columnName should be in the GROUP_CONCAT function.

    SELECT GROUP_CONCAT(DISTINCT ord.uid SEPARATOR ',')AS u
    FROM  `uc_order_products` ord_prod,  
            `uc_orders` ord,  
            `uc_roles_expirations` re
    WHERE ord.order_id = ord_prod.order_id
      AND ord_prod.title LIKE  '2012. évi%'
      AND ord.uid NOT 
    IN (SELECT uid FROM uc_roles_expirations re)
    

    PS: As side note, this uqery will produce a cartesian result due to lacking of join condition on this table uc_roles_expirations. What is the relationship of the table on the other table?

    I’m not sure, but I think you want the result of this query,

    SELECT GROUP_CONCAT(DISTINCT ord.uid SEPARATOR ',')AS u
    FROM  `uc_order_products` ord_prod
           INNER JOIN `uc_orders` ord
              ON ord.order_id = ord_prod.order_id
    WHERE ord_prod.title LIKE  '2012. évi%' AND 
          ord.uid NOT IN (SELECT uid FROM uc_roles_expirations)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Sorry if you feel like this has been asked but I have read the
I have read all threads about this without finding any answer to my problem.
I have read all the docs I can get my hands on and google'd
I have already read all the previous similar posts but I couldn't find a
I have read the documentation and searched all over but I can't find how
First of all let me tell you that i have read the following questions
I read many related questions but my case seems a little bit different that
I have read every answer related to this question and nothing has helped me.
I've read a few related questions, but none of them really helps me. So,
I have read all the documentation I found on how to integrate Unity3D projects

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.