Search Results

Search: Posts Made By: sumoka
6,492
Posted By sumoka
Thanks Bipin. I'm building on it to meet my...
Thanks Bipin.

I'm building on it to meet my requirement. I will keep you posted thanks.
6,492
Posted By sumoka
That works thanks. but, is there a way to...
That works thanks.

but, is there a way to generalize it ? there's no fixed number of key-value pairs.
6,492
Posted By sumoka
Parse key-value pair into separate rows
Hi,

I'm getting key-value pairs in a string as follows -

0000xm7zcNDIkP888vRqGv93xA7:176n00qql||9700005405552747,9700005405717924,9700005405733788|unidentified,unidentified,unidentified


I...
5,517
Posted By sumoka
Parse (delimited string) key-value pairs in a column into separate lines
Hi experts,

e.g.

i/p data looks like

0000xm7zcNDIkP888vRqGv93xA7:176n00qql||9700005405552747,9700005405717924,9700005405733788|unidentified,unidentified,unidentified||

o/p data should...
6,352
Posted By sumoka
Efficient way to grep
Hi Experts,

I've been trying simple grep to search for a string in a huge number of files in a directory.

grep <pattern> *

this gives the search results as well as the following -

grep:...
5,013
Posted By sumoka
U r right.. my bad.. shouldn't have echo'ed it! ...
U r right.. my bad.. shouldn't have echo'ed it!

That worked, thanks!

btw.. how do you get the binary code? is there any conversion or standard list available ? please share.

Suyog.
5,013
Posted By sumoka
Even in my case, the above code works.. my...
Even in my case, the above code works.. my problem is, when I call it in the SQL using `echo $delm` it prints "\t" :p has anybody tried it calling in an sql ?
5,013
Posted By sumoka
No.. the same result... It doesn't seem to detect...
No.. the same result... It doesn't seem to detect '\t' as a tab, what could be the reason ?
5,013
Posted By sumoka
Unable to export delimiter as variable to SQL
Hi,

I'm using a shell wrapper to trigger a teradata sql fastexport script as follows:

#!/bin/ksh

export delm=`echo "\t"`

fexp <<!
SELECT
COALESCE(TRIM(CAST(col1 AS VARCHAR(10))),'')...
8,144
Posted By sumoka
can you suggest one solid link or book that...
can you suggest one solid link or book that covers these basics...?
8,144
Posted By sumoka
Experts, This is slightly beyond my...
Experts,

This is slightly beyond my comprehension but let me try to put it in my words to verify.

. combining cat & Cut will cause spawning and will utilize more CPU threads which is fine for...
2,407
Posted By sumoka
Thanks! but in my case it did not work. I...
Thanks!

but in my case it did not work. I ran it on the following para from wiki abt grep


stored it in a file names "Text"

and ran..
lines=5
awk -v ln=$lines '/may also behave/ {n=ln}...
2,407
Posted By sumoka
capture data from matched string/line
Hi,

I have a query as follows :

suppose I am matching a string in a file say "start from here"
and I want to pick up 'n' number of lines () from the matched string. Is there any way to do that...
8,144
Posted By sumoka
Which cut command is more efficient?
Hi,

I've got a query regarding which of the following is more efficient & why -

cat <filename>|cut -d'*' -f2- > <newfilename>
or
cut -d'*' -f2- <filename> > <newfilename>

Thanks.
9,785
Posted By sumoka
Thank you! you are right. one last question...
Thank you!

you are right. one last question is cut faster than sed ?

to avoid spaces I have modified the code but getting 2 junk characters at the beginning of every line . want to use cut -c...
9,785
Posted By sumoka
Thanks ! I can see slight saving on time. ...
Thanks ! I can see slight saving on time.

but , is there any other way to do it ? any other command than sed ?
9,785
Posted By sumoka
sed working slow on big files
HI Experts ,

I'm using the following code to remove spaces appearing at the end of the file.


sed "s/[ ]*$//g" <filename> > <new_filename>

mv <new_filename> <filename>

this is...
13,393
Posted By sumoka
Ok. Thanks a lot!
Ok.

Thanks a lot!
13,393
Posted By sumoka
:-) good question. I feel so because...
:-)

good question.

I feel so because , I would like to generalize this piece of code.

To handle the unwanted characters except for [0-9],[a-z],[A-Z],@,.,-

is there any way to find out...
13,393
Posted By sumoka
junk characters in the begining of every line
Hi Experts,

here is a background to my problem :

I am exporting data from teradata using fastexport utility, as varchar data.
This pads additional two bytes (2 places as seen in notepad) in...
24,697
Posted By sumoka
sorry for the late response . Please ignore...
sorry for the late response .

Please ignore the first two o/p s .

1. In the 3rd o/p , even though I have selected first two matching occurrances it is selecting 3 characters

2. If I reduce...
24,697
Posted By sumoka
Hi , I have been trying various combinations...
Hi ,

I have been trying various combinations of . & * but I have not yet completely understood how the placement of "." affects the o/p & can't use the sed for this purpose very convincingly....
24,697
Posted By sumoka
Hi Scrutinizer/felipe , I have been going...
Hi Scrutinizer/felipe ,

I have been going through teh tutorials & they are very helpful thansk a lot!

However , I tried two slightly different statements on the same string & the o/p varied...
24,697
Posted By sumoka
Hi ,Thanks again... I have never used sed this...
Hi ,Thanks again... I have never used sed this way before , can u explain me the use of "...\" , ".*" & "n\" ?or direct me to a some page which will explain this usage ?
24,697
Posted By sumoka
Yes, but since in this case I know where...
Yes,

but since in this case I know where the date field starts , I want to make it indeppendant of teh date location.. is there anyway by which I can check the occurance of date & print it ?
Showing results 1 to 25 of 27

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