10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi
OS: Redhat
Version 7.5 Enterprise
Trying to post message from shell script to Slack channel and trying below code:
text="$msg"
text1="$lmsg"
if ]
then
echo "No text specified"
exit 1
fi
escapedText=$(echo $text | $text1 | sed 's/"/\"/g' | sed "s/'/\'/g" )... (13 Replies)
Discussion started by: onenessboy
13 Replies
2. Shell Programming and Scripting
Input File:
>Seq1
ASDADAFASFASFADGSDGFSDFSDFSDFSDFSDFSDFSDFSDFSDFSDFSD
>Seq2
SDASDAQEQWEQeqAdfaasd
>Seq3
ASDSALGHIUDFJANCAGPATHLACJHPAUTYNJKG
......
Desired Output File
>Seq1
ASDADAFASF
ASFADGSDGF
SDFSDFSDFS
DFSDFSDFSD
FSDFSDFSDF
SD
>Seq2 (4 Replies)
Discussion started by: patrick87
4 Replies
3. Shell Programming and Scripting
Greetings Experts,
I do have some basic knowledge of Unix. The task I am trying to do through shell script is to generate the view script for all of the tables which is in YYYYMMDD format (I assume I am on Ksh).
I have certain tables that ends in YYYYMMDD format (eg: tbl_20150630)
For each... (1 Reply)
Discussion started by: chill3chee
1 Replies
4. UNIX for Dummies Questions & Answers
Hi there,
I am trying to read the content such that if there is 'adsmsext.dll', it will read everything from line one until it reads line 6 with 'C:' then it will terminate at line 5.
1. C:\WINDOWS\system32\adsmsext.dll NT AUTHORITY\Authenticated Users:R
2. ... (5 Replies)
Discussion started by: alvinoo
5 Replies
5. Shell Programming and Scripting
i have to remove the commented (/* . . . .*/) part which starts in one line and ends in other.help me with generic code because i have 1000 to 10k lines code which i have to remove.
data one;
set work.temp;
input name age;
infile filename;
/* dfsdf
dsfs
sdfdf
dsdd
sdfsf
sdfsf
sfs... (4 Replies)
Discussion started by: saaisiva
4 Replies
6. Shell Programming and Scripting
I have a file with data records separated by multiple equals signs, as below.
==========
RECORD 1
==========
RECORD 2
DATA LINE
==========
RECORD 3
==========
RECORD 4
DATA LINE
==========
RECORD 5
DATA LINE
==========
I need to filter out all data from this file where the... (2 Replies)
Discussion started by: Finja
2 Replies
7. Shell Programming and Scripting
Hi,
I have a requirement where i have to read a file line by line and see if the string(fixed postion 10 to 15 in the file) in line 2 is greater than string in line 1.
I have used following code
while read LINE1
do
current_inv_no=$(echo "$LINE1" | cut -c 10-15)
read... (2 Replies)
Discussion started by: chethanbg2010
2 Replies
8. Shell Programming and Scripting
Hi
I am a complete newbie in unix. Learning the ropes. I have a task where I have to write a shell script to read a file line by line. I have tried some code from the net like.
The file data looks like this.
FIN427;2010003;2010003
FIN475;2010001;2010003
FIN476;2010001;2010003... (4 Replies)
Discussion started by: chamajid
4 Replies
9. Shell Programming and Scripting
i'm used a sql query in a unix script to get the information from table. but unable to extract the output which i need. Any help with logic will be greatly appreciated.
my sql query provide output some thing like this -
col1 col2 count
---- ---- ------
A B 10
c D 6
e... (8 Replies)
Discussion started by: pharos467
8 Replies
10. UNIX for Advanced & Expert Users
Can any u pls tell me :-
I want to read a particular line from a file, say line no. 10.
This can be done by using awk..but that method I think, is inefficient.
Is there any direct command for this?
Thanks (2 Replies)
Discussion started by: yeheyaansari
2 Replies