Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

One query options dependent upon another query selects

  • cpaschen
  • cpaschen
  • OFFLINE
  • Posts: 328
  • Thanks: 42
  • Karma: 9
8 years 1 month ago #285454 by cpaschen
Sorry, I forgot to mark the query as code and some elements got removed in the formatting. Here is the proper format:
Code:
SELECT DISTINCT `id`, `name` FROM #__classification_parent WHERE `flag`=1 AND `parent`=0 AND NOT '[cb_reviewer_fiction_favcat]' REGEXP concat('[[:<:]]',`id`,'[[:>:]]') ORDER BY `name`

Also 'cb_reviewer_fiction_favcat' is the first multi-select query result (the ones that you want to exclude in the second query)
The following user(s) said Thank You: krileon

Please Log in or Create an account to join the conversation.

  • cpaschen
  • cpaschen
  • OFFLINE
  • Posts: 328
  • Thanks: 42
  • Karma: 9
8 years 1 month ago - 8 years 1 month ago #285455 by cpaschen
Also, you need to set the Update on (under the query) to:
cb_reviewer_fiction_favcat
(or whatever your initial field is)
Last edit: 8 years 1 month ago by cpaschen.
The following user(s) said Thank You: krileon

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum