Post by michael2820 » Mon Jun 18, 2018 9:48 pm

PHPMyAdminn: I want to extract all emails from customers that bought certain model (product). Maybe I am lucky, that you know SQL and know the command to run ? I want to do this, because the Mail function in my OC 2.102 where you select Product as the receiver, does NOT work for me right now - I have issues with SMTP and Mail function in Settings
Last edited by michael2820 on Fri Jul 13, 2018 4:54 pm, edited 1 time in total.

--- please reply only with verified data, that is: no 'I think', 'maybe' etc. ---


User avatar
Active Member

Posts

Joined
Sun May 15, 2011 8:16 pm
Location - Denmark ver. 2.1.0.2

Post by MarketInSG » Mon Jun 18, 2018 10:41 pm

Code: Select all

SELECT email FROM `order` o LEFT JOIN order_product op ON op.order_id = o.order_id WHERE op.model = 'ABC'
The above will get you the emails for customers who purchased product model 'ABC'


User avatar
Guru Member

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by michael2820 » Tue Jun 19, 2018 12:38 am

fantastic, thank you so much

--- please reply only with verified data, that is: no 'I think', 'maybe' etc. ---


User avatar
Active Member

Posts

Joined
Sun May 15, 2011 8:16 pm
Location - Denmark ver. 2.1.0.2

User avatar
Guru Member

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by lovol2 » Sat Jun 23, 2018 3:36 am

I’m just at the testing stage of my mod/website that does this live. Eg 1 min after the purchase of a specific product. Then follow up with emails for up sells or down sells. Etc.

It’s worked amazing for me and got plenty of extra money. But most importantly my customers are getting the right combination of products.

Sometimes they just don’t read they need a specific cleaner to go with some of our products. .

Now they get an automatic email educating them. With buy links and coupons.

I only bring it up as it looks like your doing this as a one time manual thing.

I’ve a mod that automates this whole thing.

I’ll help you set it up no problem if you’re interested.

New member

Posts

Joined
Wed Mar 24, 2010 6:41 am

Post by michael2820 » Fri Jul 13, 2018 4:45 pm

Next question; what is SQL command to extract emails customers who bought model FROM order_id 3.000 to order_id 4.000?
Highly appreciated if you know that
Michael, Denmark

--- please reply only with verified data, that is: no 'I think', 'maybe' etc. ---


User avatar
Active Member

Posts

Joined
Sun May 15, 2011 8:16 pm
Location - Denmark ver. 2.1.0.2

Post by MarketInSG » Tue Jul 17, 2018 10:22 pm

michael2820 wrote:
Fri Jul 13, 2018 4:45 pm
Next question; what is SQL command to extract emails customers who bought model FROM order_id 3.000 to order_id 4.000?
Highly appreciated if you know that
Michael, Denmark

Code: Select all

SELECT * email FROM oc_order o LEFT JOIN oc_order_product op ON op.order_id = o.order_id WHERE o.order_id >= 3000 AND o.order_id <= 4000 AND op.model = '1234'


User avatar
Guru Member

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by michael2820 » Tue Jul 17, 2018 10:39 pm

thank U so much

--- please reply only with verified data, that is: no 'I think', 'maybe' etc. ---


User avatar
Active Member

Posts

Joined
Sun May 15, 2011 8:16 pm
Location - Denmark ver. 2.1.0.2
Who is online

Users browsing this forum: No registered users and 47 guests