At 15:14 +0100 3/20/03, Yasen Petrov wrote:
>when I try
>mysql> select * from member;
>it shows lots of records and the screen goes up quickly. Thus I can't see
>the results very well because of the small screen (only 19" :):):) and I
>wonder if there's a way to output the results into a .txt file.
>why not be like:
>mysql> use samp_db
>mysql> select * from member > output_file.txt
>Is there some way to work around this problem? Thanks a lot.
You can run mysql with a --tee option to capture your output in a
file as well as sending it to the screen.
C:\> mysql --tee=junk
mysql> use samp_db
mysql> select * from member;
C:\> type junk
Under Unix (which I believe you are not using), you can also use a pager
to view the results page by page. For example:
% mysql --pager=/bin/more
Long queries will be run through the paging program.