10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hi,
I have an issue modifying a file. Below is the content of the file.
File name - a.txt
SELECT LISTAGG(SCORE), LISTAGG(VB),
LISTAGG(SCORE*12 + 3),
LISTAGG(DOB)
from T_CONCAT ;
SELECT LISTAGG(SCORE),
LISTAGG(VB),
LISTAGG(SCORE*100 + 3),
from... (1 Reply)
Discussion started by: Mannu2525
1 Replies
2. Shell Programming and Scripting
i have to append a text file
grep for a word, if found, put comment in starting of the line.
here is an example
cat test.sh
bin/ksh
Hello World
Test Message
:wq!
search for "bin" word in test.sh file if found comment it out at starting of the line:
Output as follows:
#bin/ksh... (5 Replies)
Discussion started by: raghur77
5 Replies
3. Shell Programming and Scripting
Hi all.. I have several unique files that contain one thing in common, and that is acct#. For all files in the directory, I want to append the 10 characters following the word "ACCOUNT:" to the end of the filename.
for example:
I have file 111_123 that contains ACCOUNT:ABC1234567
The file... (5 Replies)
Discussion started by: cinderella1
5 Replies
4. Shell Programming and Scripting
I have some html with hrefs that contain local links to pdf filenames. These filenames should have standardised names, i.e. there should be a label prior to the ".pdf" filename suffix. There can be many of these links on a single line of text and some may already have the label. For example
... (13 Replies)
Discussion started by: adb
13 Replies
5. UNIX for Dummies Questions & Answers
Hi Folks,
I wanted to know if i can use RegEx in a for-loop of a shell script.
Here's a scenario, I have a set of files say x1, x2, x3..x9 in a directory(obviously with files other than this pattern). I want to append a line of text to all files that follow pattern x. Can someone help me out? I... (4 Replies)
Discussion started by: prithvirao17
4 Replies
6. Shell Programming and Scripting
Sup guys, today I tried to append a string from my text by asking the user to input and change the specific text they wanna append.
The problem is that, the code looks logically correct, but when I run it there's an error somewhere.
Can anyone identify for me?
echo "Search data"
read... (4 Replies)
Discussion started by: aLHaNz
4 Replies
7. Shell Programming and Scripting
hi,
I've a file with some text in it, i need to append few strings in the beginning and end of each row.
--in file
richie
matt
..
--out file
hi, 'richie' is here
hi, 'matt' is here
...
I tried with awk command, but it fails because of '
Thanks (2 Replies)
Discussion started by: dvah
2 Replies
8. UNIX for Advanced & Expert Users
Hi,
I have a file which have set of rows and has to create separate files based on the id.
Eg:
001_AHaris020
001_ATony030
002_AChris090
002_ASmit060
003_AJhon001
Output: I want three files like 001_A.txt, 002_A.txt and 003_A.txt.
001_A.txt should have
... (1 Reply)
Discussion started by: techmoris
1 Replies
9. Shell Programming and Scripting
I have a command stream that will parse down an ftp DIR listing of a remote directory and return the name of the newest file that I am interested in. The command is
sed -e '/^d/d' sppay.listing |sed -n -e '/SPPAY/p'|sort -r -k 43M,45 -k 47,48 -k 50,54|sed -n -e '1p'|cut -c 56-99
and what it... (2 Replies)
Discussion started by: beilstwh
2 Replies
10. Shell Programming and Scripting
I'm creating a script that counts the number of users currently online, then records that in a file called "log.txt" along with the time. Everytime the script is ran, the script appends the "log.txt"
this is what I have:
who|wc|cut -c6,7>>log.txt
date|cut -c12-24>>log.txt
After running... (5 Replies)
Discussion started by: 801238429
5 Replies