Solved

MYSQL join and export to CSV

Posted on 2015-02-05
2
114 Views
Last Modified: 2015-02-06
Apologies I know this is simple for people but I have tried lots of different ways and failed.

I need to export

I am using SQL workbench and I need to export to a CSV file all the emails in the "em_subscriber" table that have a status=3 in the "em_subscriber_list".  Obviously its the "subscriberid" and "id" fields which are the unique identifier so I need a statement that will join the 2.

em_subscriber_list
subscriberid
status


em_subscriber
email
id


Can anyone help me
0
Comment
Question by:ncomper
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 11

Accepted Solution

by:
N R earned 500 total points
ID: 40592966
select *
from em_subscriber es
inner join em_subscriber_list esl on es.id = esl.subscriberid
where status = 3

Open in new window

0
 
LVL 5

Author Closing Comment

by:ncomper
ID: 40593397
perfect
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
MySQL Error Code 2 31
AWS EC2 & RDS Instance 5 74
mysql db 3 96
Inserting data into database 10 52
Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question