Answer the question
In order to leave comments, you need to log in
sql query result output without fields
When executing a normal SELECT, I get a small table with the field name and content on the output. Can this be bypassed somehow? For example, what would the output be like the output from sqlite?
Answer the question
In order to leave comments, you need to log in
I solved my problem like this (the piece used in the script):
mysql -pPASSWORD --skip-column-names --exec="\
SELECT userid FROM proftpd.users WHERE userid='$name';" | cat -
There is a line by line output
mysql> select now();
+---------------------+
| now() |
+---------------------+
| 2013-11-14 16:22:29 |
+---------------------+
1 row in set (0.00 sec)
mysql> select now() \G
*************************** 1. row ***************************
now(): 2013-11-14 16:22:32
1 row in set (0.00 sec)
mysql>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question