Jump to content

Recommended Posts

Posted

Appreciate some SQL help as I intend to filter members based on one of the field but being that field is multi option so I can't filter members from Admin CP.

Hope there is a way to do that from DB and download all members email addresses who have checked "off-road - learn/drive" from this registration field.

https://carnity.com/register

image.png.790ccca3c7a134f8aa973a9c8e020793.png

Posted
SELECT email FROM core_members LEFT JOIN core_pfields_content ON core_members.member_id=core_pfields_content.member_id WHERE FIND_IN_SET(4, field_22);

or

SELECT email FROM core_members LEFT JOIN core_pfields_content ON core_members.member_id=core_pfields_content.member_id WHERE field_22=4;

 

Posted
4 minutes ago, Gauravk said:

Both have worked and shown different number of results (emails). Any clue which one is correct 213 or 109?

 

Depends on what you need

1st query returns results for users which selected "off-road - learn/drive" or "off-road - learn/drive" + others

2st query returns results for users which only selected "off-road - learn/drive"

  • 2 weeks later...
Posted

Hello,

SELECT core_members.name, core_pfields_content.field_15 AS mobile 
FROM core_clubs_memberships 
LEFT JOIN core_members ON core_members.member_id=core_clubs_memberships.member_id 
LEFT JOIN core_pfields_content ON core_pfields_content.member_id=core_members.member_id 
WHERE core_clubs_memberships.club_id=7;

 

  • 2 months later...
Posted

Hi @newbie LAC may I please have a new script for extracting all member who joined for car problem and solution.

Fields needed: email    phone    first name    last name    zip    city    country     gender

elCheckbox_core_pfield_22_0

Thanks in advance

image.thumb.png.2c010cb3d27a12ebf202ee2ebb656442.png

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...