Quantcast
Channel: Active questions tagged users - Drupal Answers
Viewing all articles
Browse latest Browse all 570

How to use subquery in views where clause

$
0
0

In my project user can created by profile2 module. When user is created i am assigning some role,initially user is block state. I have another user role ie.user app rover who can approved these user and send activation link for active user.

I am using Mail Logger module for saving sending mailNow i have created a view for user unapprove list

    SELECT users.name AS users_name, users.uid AS uid, users.mail AS users_mail,     profile_users.pid AS profile_users_pid, users.created AS users_created, 'profile2' AS     field_data_field_cc_first_name_profile2_entity_type, 'profile2' AS     field_data_field_cc_address_office_profile2_entity_type, 'profile2' AS     field_data_field_cc_designation_profile2_entity_type         FROM          {users} users         LEFT JOIN {profile} profile_users ON users.uid = profile_users.uid AND          profile_users.type IN ( 'company', 'goverment_profile' )         WHERE (( (users.status = '0') AND (users.login = 0) AND (profile_users.type IN             ('company', 'goverment_profile')) ))            ORDER BY users_created DESC            LIMIT 10 OFFSET 0

Hear i want to add sub-query in where condition user those already send activation link who will not list in view.

My other table is mail_logger.

Is there any module by which i can use sub-query in where condition?


Viewing all articles
Browse latest Browse all 570

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>