10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
In Bash shell - the ps -ef shows only the /bin/bash but the script name is not displayed ? Is there any way to get the script names for the process command ?
--- Post updated at 08:39 AM ---
in KSH (Korn Shell), my command output shows the script names but when run in the Bash Shell... (3 Replies)
Discussion started by: i4ismail
3 Replies
2. UNIX for Beginners Questions & Answers
Re: Query on using command "SED" for replacing text in bash shell
While using the command "sed" for find and replace, I wanted to know how one could find a constant and replace it with a variable inside the quotation syntax of sed?
I wanted to replace constant 3 with variable name... (3 Replies)
Discussion started by: achandra81
3 Replies
3. Shell Programming and Scripting
So I'm trying to pass certain json elements as env vars and use them later on in a script.
Sample json:
JSON='{
"Element1": "file-123456",
"Element2": "Name, of, company written in, a very weird way",
"Element3": "path/to/some/file.txt",
}'
(part of the) script:
for s... (5 Replies)
Discussion started by: da1
5 Replies
4. Shell Programming and Scripting
I think(hope) I've got a simple one - I just need to send an email if a mysql query returns any results (ideally - it will never match).
Currently I just pipe the mysql query output to the mail program, but of course that emails regardless of the output( and I check this every 10 minutes from... (5 Replies)
Discussion started by: jcass78
5 Replies
5. Shell Programming and Scripting
I have a $file which will be used as an input file for the script, pasting ie.
16 VDBDN084_K_TPVV016 SDBDN081 5:3:2 t 4313 273 4313 69077 3689 69077 2.0 2.1 16.0 13.5 5
16 VDBDN084_K_TPVV016 SDBDN081 4:3:3 t 4313 273 4313 69890 3679 ... (2 Replies)
Discussion started by: vishalgoyal
2 Replies
6. Shell Programming and Scripting
Hi,
I need to query Oracle database for 100 users. I have these 100 users in a file. I need a shell script which would read this User file (one user at a time) & query database.
For instance:
USER CITY
--------- ----------
A CITY_A
B CITY_B
C ... (2 Replies)
Discussion started by: DevendraG
2 Replies
7. UNIX for Dummies Questions & Answers
Hi Guys,
I would like with this script
"DATA=`ora123 su -c 'echo "SET HEADING OFF;\n SET FEED OFF;\n select USER NAME, ACCOUNT_STATUS from dba_users;\n exit" | sqlplus / as sysdba -s /' `
echo $DATA >> $DAT"
make a sql query, but the statement
"select USER NAME, ACCOUNT_STATUS from... (6 Replies)
Discussion started by: ixibits
6 Replies
8. Shell Programming and Scripting
I'm running a bash script query and assigning the output to a variable like this:
exists=`mysql -u $USER_NAME --password=$PASSWORD -D "somedb" \
-e "SELECT * FROM somedb.sometable WHERE field1 ='$a' \
AND field2 ='$b' LIMIT 0 , 30";`
which returns something like:
echo... (2 Replies)
Discussion started by: unclecameron
2 Replies
9. Shell Programming and Scripting
Hi,
I have a requirement as below which needs to be done viz UNIX shell script
(1) I have to connect to an Oracle database
(2) Exexute "SELECT field_status from table 1" query on one of the tables.
(3) Based on the result that I get from point (2), I have to update another table in the... (6 Replies)
Discussion started by: balaeswari
6 Replies
10. UNIX for Dummies Questions & Answers
Hi All,
I am setting bash as my working shell in my .profile file.
So I have written a line :
bash
as the list line in my .profile
I want to use alias as follows:
alias me='who am i'
When i log in, as expeced I enter the bash shell but alias doesn't work.
Is it because the alias is defined... (1 Reply)
Discussion started by: VENC22
1 Replies