LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-12-2009, 05:10 AM   #1
xpucto
Member
 
Registered: Sep 2005
Location: Vienna, Austria
Distribution: Mint 13
Posts: 524

Rep: Reputation: 31
MySQL: how to be abble to see well aranged tables?


Hi!
when doing for example
Code:
select * from myTable;
it may happen that the result in the shell window shows fields that are not properly arranged when some fields too big are. In those cases it is just impossible to read anything.
How may I get readable results even when fields are very long?

Thanks
 
Old 03-12-2009, 06:09 AM   #2
T74marcell
Member
 
Registered: Mar 2009
Posts: 102

Rep: Reputation: 18
You can specifically list the fields that you want to see.
Quote:
SELECT name, address, phone FROM TABLE adressbook;
Assuming that 'addressbook' has these fields (among others), only these ones will be listed. You can also limit the number of results:
Quote:
SELECT name, address, phone FROM TABLE addressbook WHERE id>'999' LIMIT 10;
Get yourself some good SQL documentation or tutorial.

Arch Linux

Last edited by T74marcell; 03-14-2009 at 01:14 AM. Reason: corrected typo
 
Old 03-13-2009, 03:32 AM   #3
xpucto
Member
 
Registered: Sep 2005
Location: Vienna, Austria
Distribution: Mint 13
Posts: 524

Original Poster
Rep: Reputation: 31
Thank you for your answer. I already know the answers you gave though and it doesn´t solve my problem.
1) I need to see all the fields
2) the number of rows are not the problem but their length which does not pass to the width of my screen.
 
Old 03-13-2009, 03:55 AM   #4
xpucto
Member
 
Registered: Sep 2005
Location: Vienna, Austria
Distribution: Mint 13
Posts: 524

Original Poster
Rep: Reputation: 31
ok, I´ve got it:
Code:
select * from myTable \G
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mysql can't create tables tzpow2k2 Linux - Software 1 06-17-2006 11:28 AM
mysql reinstallation distorted by previous tables in /var/mysql mad4linux Linux - Software 0 10-04-2005 01:39 PM
MySQL tables from 4.0 to 3.0 michaelbhahn Linux - Software 0 08-31-2004 10:23 AM
mysql tables with a - pk21 Linux - Software 7 05-23-2003 06:27 AM
mysql tables noord28 Linux - Newbie 0 02-20-2003 02:56 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:53 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration