MySql Select,MANY FIELDS,如何在终端中最好显示? [英] MySql Select, MANY FIELDS, how best to display in terminal?

查看:150
本文介绍了MySql Select,MANY FIELDS,如何在终端中最好显示?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Putty(命令行)并运行

I'm using Putty (Command-line) and running a

mysql> SELECT * FROM sometable;

sometable有许多字段,这导致许多列试图显示在终端中。

The 'sometable' has many fields and this results in many columns trying to be displayed in the terminal. The fields wrap onto the next line so it is very hard to line up Column titles with Field values.

在终端中查看这些数据有什么解决方案?

What solutions are there for viewing such data in terminal?

(ps我没有/想要访问phpMyAdmin或其他GUI界面)

(p.s. I don't have/want access to phpMyAdmin - or other GUI interfaces)

寻找命令行解决方案,例如将MySQL查询结果保存到文本或CVS文件中( save-mysql-query-results-into-a-text-or-csv-file

Looking for command-line solutions such as this Save MySQL Query results into text or CVS file (save-mysql-query-results-into-a-text-or-csv-file)

推荐答案

SELECT * FROM sometable\G

显示如下行:

*************************** 1. row ***************************
             id: 1

这篇关于MySql Select,MANY FIELDS,如何在终端中最好显示?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆