Search Results

Search: Posts Made By: KK230689
5,413
Posted By apmcd47
If I read you correctly you wish to dynamically...
If I read you correctly you wish to dynamically change the delimiter used by cut:
DELIM=,
echo "a,b,c,d,e" | cut -d "$DELIM" -f 3
DELIM="|"
echo "A|B|C|D|E" | cut -d "$DELIM" -f 2

Or is it a...
2,170
Posted By rdrtx1
rm -f outfile_* file_count=1 line_count=1 ...
rm -f outfile_*

file_count=1
line_count=1

outfile="outfile_$file_count"

while read line
do
echo "$line" >> $outfile
(( line_count = line_count + 1 ))
[[ $line_count -ge 5 ]] &&...
2,170
Posted By apmcd47
This looks like it should work to me. Have you...
This looks like it should work to me. Have you tested it? I don't think you need the echo "$line" | grep. If using ksh93 or bash 4 you could write:

[[ "${line}" =~ ";" ]] && [[ "${line_count}"...
7,275
Posted By Yoda
That is not a true statement. Here is an...
That is not a true statement. Here is an example:-
$ cat script.ksh
#!/bin/ksh

conn_str="user@passwd@dbinstance"

sqlid=$(
sqlplus -s $conn_str << EOF
set echo off head off...
2,170
Posted By rbatte1
Welcome KK230689, I have a few to questions...
Welcome KK230689,

I have a few to questions pose in response first:-
Is this homework/assignment? There are specific forums for these.
What have you tried so far?
What output/errors do you...
Showing results 1 to 5 of 5

 
All times are GMT -4. The time now is 09:48 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy