9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi folks,
I have a scenario to convert the update statements into insert statements using shell script (awk, sed...) or in database using regex.
I have a bunch of update statements with all columns in a file which I need to convert into insert statements.
UPDATE TABLE_A SET COL1=1 WHERE... (0 Replies)
Discussion started by: dev123
0 Replies
2. Shell Programming and Scripting
$ ls -1
a.1
b.1
x_a.1
x_b.1
$ ls -1 *
b.1
x_a.1
x_b.1
$ ls -1 **
a.1
b.1
x_a.1
x_b.1The last result is not as expected.
Why?
Thanks. (2 Replies)
Discussion started by: carloszhang
2 Replies
3. Homework & Coursework Questions
Hello, have anybody any idea, how to negate some expression?
I have code that greps somethnig and I want filter from it some results...How to make it?
IDontWantThisExpression=$1
grep 'some regex' | grep '$IDontWantThisExpression' testfile.txt
Thanks for any advices.
Faculty of... (2 Replies)
Discussion started by: Dworza
2 Replies
4. Shell Programming and Scripting
Is there an option for negation in the "tr" command?
For eg:
echo hi | tr "h" "i"
will print "ii".
But if I want to covert all characters that are not "h" to "j", how do I do that?
Is there something like "!" in tr? Or any switch?
Thanks,
Prasanna (17 Replies)
Discussion started by: prasanna1157
17 Replies
5. Shell Programming and Scripting
Hi All,
I am using Unix ksh script.
I need to insert values to a table using the o/p from a slelect statement.
Can anybody Help!
My script looks like tihs.
---`sqlplus -s username/password@SID << EOF
set heading off
set feedback off
set pages 0
insert into ${TB_NAME}_D... (2 Replies)
Discussion started by: nkosaraju
2 Replies
6. UNIX for Dummies Questions & Answers
I have an "if" statement which checks for certain pattern in the file:
if grep -i dblist.comdbg /bb/bin/rstrt
then
copydb
else
exit 1
fi
How can I use the same statement with negation, checking if file does not exist, something like
if ! grep -i dblist.comdbg /bb/bin/rstrt
then ... (2 Replies)
Discussion started by: aoussenko
2 Replies
7. Shell Programming and Scripting
In my ksh script, if the conditions of a if statement are true, then do nothing; otherwise, execute some commands.
How do I write the "do nothing" statement in the following example?
Example:
if (( "$x"="1" && "$y"="a" && "$z"="happy" ))
then
do nothing
else
command
command
fi... (3 Replies)
Discussion started by: april
3 Replies
8. Shell Programming and Scripting
Guys,
Pl suggest me how to ignore a path in find command... I am aware of using "!" for other option... but how can i use it like this exampl...
I want to search something for in / but not in
Pl help.
Thanks.. (2 Replies)
Discussion started by: clx
2 Replies
9. Shell Programming and Scripting
I am taking an online course on Unix scripting. The topic is Unix arithmetic operators and the lesson is Logical and bitwise operations. It is not clear how much storage space Unix uses to represent integers that are typed. Bitwise negation caused me to question how many bits are used to... (3 Replies)
Discussion started by: dLloydm
3 Replies