Shell menus And Oracle


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Shell menus And Oracle
# 1  
Old 05-08-2009
Question Shell menus And Oracle

Dear All,

Kindly suggest on how should i proceed with the following requirement

I need to develop an interactive shell script menu which would enable the user to inquire the value of a column based on a key value [i would use "like" in oracle to search]. The output can be more records..
Also is it possible to do the following
1) format the output of the query to display the values like

--------------------------------------------
key1 This is the description column i'm trying
to search1
key2 This is the description column i'm trying
to search2
key3 This is the description column i'm trying
to search3
--------------------------------------------

2) is it possible to have some thing similar to the header where in i have some options for the user to choose and the body section where in the output is displayed in the above format

Kindly clarify. Any inputs regarding this will be highly useful

Thanks
~S
# 2  
Old 05-10-2009
What interpreter Are you using for this script ?. (KSH, SH, BASH).
If you are using ksh this example can help us.

"
echo "Introduce first field to search"
read a
echo "You have introduced "$a
echo "Introduce second field to search"
read b
echo "You have introduced "$b

"

Its an easy way to make an interactive menu with ksh.
I hope have been helpfull
# 3  
Old 05-10-2009
Is it possible to have a header and footer kind of display
to make it more clear, what i'm talking about is something show below


============================================
Keyword: key
Exit (Y/N):
============================================
key1 Description
key2 Description
key3 Description
key4 Description
key5 Description
key6 Description
=============================================


Any inputs would be very useful

~S
Login or Register to Ask a Question

Previous Thread | Next Thread

6 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Cascading bash menus

I currently have a main menu (using whiptail) and one of the options makes an instance of another menu - sort of cascading fashion. I like to be able to terminate the current (top) menu and return to the underlying main one. I was thinking enclosing the main menu in "do... done" block. ... (0 Replies)
Discussion started by: annacreek
0 Replies

2. AIX

SMS menus are not supported on JS20

Hello, I am new to AIX... I am having this problem trying to re-install AIX 5L 5.2 on a blade (JS20) Then update it to 5.3 This blade now has 5.3 and needs to be re-install But the problem is when I press 1 while it is restarting.... I see the message: SMS menus are not supported on... (4 Replies)
Discussion started by: mifch
4 Replies

3. Shell Programming and Scripting

Menus in Korn Shell and invalid selections

Hey Guys. I need to code a series of menus that have four options, selectable either by the number in the menu or the name, in succession. This part I have achieved however I am struggling to find a way that should the user try to enter an invalid selection, such as the number 5 or an incorrect... (5 Replies)
Discussion started by: Mudja
5 Replies

4. UNIX for Dummies Questions & Answers

Creating menus in script file

I'm very new to Unix and know the simplest of its commands. I am trying to write a script file that has a menu with the following options showing: 1) Display all files in a user's home directory. 2) Welcome yourself to the program 3) Display System Information 4) Exit to Windows I am able... (6 Replies)
Discussion started by: sinjin
6 Replies

5. Shell Programming and Scripting

Shell Script Menus - Rejecting invalid input (KSH)

Greetings all, I'm currently writing a shell script menu which is dynamically populated from an array. Have a question to ask about the filtering of invalid input. I'm using KSH. A brief description of my algorithm is as follows: 1) Read in input from user and store in a variable. (a valid... (2 Replies)
Discussion started by: rockysfr
2 Replies

6. Programming

ncurses -> the best way to use menus

hello there, i'm exploring the curses lib and i'm having some trouble with "defining a style". to clarify: i'm creating a menu driven app and i've been thinking what's the best way to use menus: make global vars (not my favourite), creating a function which designs the menu and returns the... (2 Replies)
Discussion started by: crashnburn
2 Replies
Login or Register to Ask a Question