35

I do have thousands of website list and other info in MySQL database.

I want only website column named "web" to be exported to excel or text or csv.

I know how to export the whole data but dont know how to export particular column.

mathew
  • 359
  • 1
  • 3
  • 3

6 Answers6

33

Query

SELECT `web` FROM `yourtablename` 

Or this to export unique records only:

SELECT DISTINCT `web` FROM `yourtablename`

Then click export link given on bottom (in phpmyadmin)

It is easiest way as per me

p.s.w.g
  • 146,324
  • 30
  • 291
  • 331
Kinjalk
  • 331
  • 3
  • 3
  • 1
    This works, but It doesn't allow me to export all the data, I have around 3000 lines of data, I can export only 25 rows, is there any way to export all? – iphonic May 28 '18 at 09:58
  • 3
    There are two 'Export' links. Click the one further down, in the 'Query results operations' section. – Stephen Jun 27 '18 at 23:21
20

In my case, I have a users table with 20k records. Then i export 20k email address using this technique. You don't need to write any query.

open your table (user_login) and click on the structure button

enter image description here

Select column which you want to export. In my case I need on email column so I selected the email column and then click on browse button.

enter image description here

After click on browse button scroll down the page and click on export button. which i mentioned in screen.

enter image description here

Final step

select your export format and click on the go button... :) enter image description here

Thank you for reading this. I hope you get the solution

Neeraj Tangariya
  • 1,159
  • 1
  • 17
  • 29
7

You can execute this query directly using phpmysql :

SELECT web FROM your_table INTO OUTFILE '/tmp/web.sql'

After that, you can login to the database server OR use php to access the OUTFILE

details - mysql select

ajreal
  • 46,720
  • 11
  • 89
  • 119
5

open the table from which you want to export only certain column , click on structure , tick mark on check box of that column , click on browse button ! after that it will show you your column data , below their is written export button click on it ! don't click on export button which is at the top bar , now export your column by clicking on go Button.

Mohsin Shoukat
  • 1,190
  • 1
  • 13
  • 22
2

You could do a query like:SELECT web FROM table; and then just export that.

Sean
  • 97
  • 4
1

Enter SELECT web FROM table; and then click on the "Export" button that is at the bottom of the list. IMPORTANT, don't clic on the "Export" button at the top of the list, or you will export the whole data.

jptsetung
  • 9,064
  • 3
  • 43
  • 55