SOLVED Pre-filer list with value from other list's element

Trembowiecki

Active Member
Hi,

I'd like to pre-filter a list with a value of other list's element. Here's the situation:

List 'users': 'id', 'user_id', 'user_name', 'user_department', 'user_archived'

List 'documents': 'id', 'user_id' [databasejoin element: users.user_id = documents.user_id - rendered in form as a dropdown], 'document1', 'document2', 'document3'

Now I want to pre-filter 'documents' list based on a value of 'user_archived' element from 'users' list - you know, if set to 'yes', then don't show records with this user's id. How to do this?

Cheers,

Olek

UPDATE

I've solved this!
Elements: user_id
Condition: IN
Value: SELECT user_id FROM users WHERE user_archived='no'
Type: Query
 
Last edited:
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top