LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-15-2008, 10:36 AM   #1
juanczm
LQ Newbie
 
Registered: Jan 2005
Location: Caracas, Venezuela
Distribution: debian
Posts: 5

Rep: Reputation: 0
Question console configuration horizontal scrollbar


Hello.

Sorry by my english, not mother tongue.

What i really like from windows is cmd. Because can be configurated in buffer horizontal size, buffer vertical size, buffer history commands, color font, quick edition, etc.

Any of those things can be get with configuration in linux formed console.

But 2 things i cant learn how to do it is:
1) Get a horizontal Scroll bar. (buffer horizontal) I really use this function when i work with PostgreSQL in console (i know about graphic tools but i get used to work with console an a text editor).
2) Copy a section of screen. Example.
Idx | values
--------------------------------------
1 | i want copy this column
2 | i want copy this column
3 | i want copy this column
4 | i want copy this column
Used in same type of work.

Thanks in advace for any help.

Last edited by juanczm; 07-17-2008 at 07:47 AM. Reason: writing right database name.
 
Old 07-15-2008, 04:20 PM   #2
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
Windows cmd console is pretty poor thing, I'm wonder if there is another one to like it...

What type of console do you mean? Is it a text tty console, or framebuffer console? Or you're using a terminal emulator?
 
Old 07-15-2008, 05:21 PM   #3
juanczm
LQ Newbie
 
Registered: Jan 2005
Location: Caracas, Venezuela
Distribution: debian
Posts: 5

Original Poster
Rep: Reputation: 0
Ok..

Poor thing... no must like me..
what can i do in order to get what i want in linux?

I try with yakuake, tilda, terminator, terminal emulator. KDE or Gnome.
 
Old 07-15-2008, 11:01 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
All you need to do is make less your pager .... then you can scroll either way
to your hearts content. Btw, the database is called PostgreSQL, or short
Postgres, not postgre .....


Cheers,
Tink
 
Old 07-15-2008, 11:17 PM   #5
cyclepathology
LQ Newbie
 
Registered: Sep 2007
Location: Seattle, WA
Distribution: Red Hat, Ubuntu, PCLinuxOS, Fedora, Vector Linux, CentOS, HP-UX, Solaris, AIX, FreeBSD
Posts: 28

Rep: Reputation: 15
Quote:
Originally Posted by juanczm View Post
Hello.

2) Copy a section of screen. Example.
Idx | values
--------------------------------------
1 | i want copy this column
2 | i want copy this column
3 | i want copy this column
4 | i want copy this column
Used in same type of work.

Thanks in advace for any help.
You can get this effect with the "cut" command.

Run the command that produces your output and pipe the output through cut, telling it which fields to pull. awk would work too, but cut is easier. "man cut" for more info.
 
Old 07-16-2008, 05:27 PM   #6
juanczm
LQ Newbie
 
Registered: Jan 2005
Location: Caracas, Venezuela
Distribution: debian
Posts: 5

Original Poster
Rep: Reputation: 0
Smile Sorry, i think i am too much noob for this.

Quote:
You can get this effect with the "cut" command.

Run the command that produces your output and pipe the output through cut, telling it which fields to pull. awk would work too, but cut is easier. "man cut" for more info.

thank you for your help. I dont know how use this in PostgreSQL shell (psql).

Quote:
All you need to do is make less your pager .... then you can scroll either way
to your hearts content. Btw, the database is called PostgreSQL, or short
Postgres, not postgre .....
Sorry, i think i am too noob for that, i dont know how "make less my pager" and how use it in PostgreSQL (my mistake before) shell client (psql).

Thanks, for help
 
Old 07-16-2008, 10:08 PM   #7
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
If you do
env| grep PAGER
in the terminal - what does it say?

If it's 'more', try the following:
PAGER=less psql

If you have lots of output that you don't want to
wrap around at the screen-width but rather feel
like scrolling, try:
PAGER='less -S' psql

As for the stuff you want to copy - try not adding
things you don't want to your query, you may find
the queries return faster, too.


Cheers,
Tink
 
Old 07-18-2008, 04:11 PM   #8
juanczm
LQ Newbie
 
Registered: Jan 2005
Location: Caracas, Venezuela
Distribution: debian
Posts: 5

Original Poster
Rep: Reputation: 0
Wink Thanks.

Quote:
If it's 'more', try the following:
PAGER=less psql
This work. Thanks. Just that first vision is any register wrapped but if i press right key, then this work.

Quote:
If you have lots of output that you don't want to
wrap around at the screen-width but rather feel
like scrolling, try:
PAGER='less -S' psql
This have same behavior that before command.

Quote:
As for the stuff you want to copy - try not adding
things you don't want to your query, you may find
the queries return faster, too.
Sure. You are right, but.. too many times i miss this function.

Thanks.
 
Old 07-18-2008, 05:40 PM   #9
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Quote:
Originally Posted by juanczm View Post
Code:
PAGER=less psql
This work. Thanks. Just that first vision is any register wrapped but if i press right key, then this work.

Code:
PAGER='less -S' psql
This have same behavior that before command.
The -S should make the difference that the lines NEVER
wrap, and it works like that for me. How odd.


Cheers,
Tink
 
  


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
Changing LILO and Console Configuration dast Slackware 3 06-05-2006 01:12 PM
Question about the console configuration.. Deeze Debian 6 06-18-2005 05:17 PM
console configuration problems with keymap amimusa Debian 1 04-13-2005 12:46 PM
Problem on X configuration from console Japan Lnx Mandriva 5 01-25-2005 11:32 AM
Console Scrollbar Not fucntioning??? $13.40 Linux - General 0 10-18-2001 04:40 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:56 AM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration