Search Results

Search: Posts Made By: Sri3001
2,718
Posted By Sri3001
hi the Echo was not returning any output,...
hi

the Echo was not returning any output, so instead of calling it from the caller script and passing it as a Command Line argument, I derived the File count value in this script.and it worked...
2,718
Posted By Sri3001
This code is being called by another scipt, on...
This code is being called by another scipt, on that script the file count is defined as

word_length=`head -1 /infadata/Temp/file_limit`

it is passed to this program as a command line argument ...
2,718
Posted By Sri3001
Sorry The If condition is Line 30
Sorry

The If condition is Line 30
2,718
Posted By Sri3001
Integer expression expected
Hello ,

This is the piece of the code which is giving me trouble

if [ ! -r "${SOURCEDIR}/${OUT_FILE}" ] ;then
exit_proc "${SOURCEDIR}/${OUT_FILE} does not exists or not readable"...
1,727
Posted By Sri3001
Thanks, Its working...But just out of...
Thanks,

Its working...But just out of curiosity, is there any other way of doing it , just comparing the 2nd ,3rd and 4th field as a key to find duplicates in a file.Would be great its there in...
1,727
Posted By Sri3001
Even after that I am getting the same output ...
Even after that I am getting the same output

-bash-3.2$ sort -t, -k 2,2 -k 3,3 -k 4,4 sample.txt |sort -u

I,01,000131,764,2,4.00
I,01,000131,764,2,5.00
I,01,000131,765,2,4.00...
1,727
Posted By Sri3001
Removing duplicates from a file
Hi All,

I am merging files coming from 2 different systems ,while doing that I am getting duplicates entries in the merged file

I,01,000131,764,2,4.00
I,01,000131,765,2,4.00...
6,593
Posted By Sri3001
Thanks everyone , finally was left with no option...
Thanks everyone , finally was left with no option but to do a math , perl would not have been an ideal scenario because this is just one part of the whole script,
here is what I came up with...
6,593
Posted By Sri3001
Doing a math would me my last option.. Is there...
Doing a math would me my last option.. Is there any piece of code that does this, If there is none i would be left with no other option other than doing something which you have told
6,593
Posted By Sri3001
My Apologies for the ambiguity on the query , ...
My Apologies for the ambiguity on the query ,

1. I need 12 files no matter whatever is the size of the file
2. I think I cant use split function as I have to give either the number of lines...
6,593
Posted By Sri3001
Splitting files
Hello all

I have a file which has around 80 million records, I want to split it to 12 equal files, I tried using the split command but it is allowing me to split according to number of lines or...
1,427
Posted By Sri3001
Yes the second line is a part of the first line
Yes the second line is a part of the first line
1,427
Posted By Sri3001
Thanks it worked , It would be really kind if you...
Thanks it worked , It would be really kind if you could explain what the code does a bit elaborately.
1,427
Posted By Sri3001
Adding a column to a file
Hello all,

I need to add a coloumn at the 5th Position of a file, Can this be done using awk or sed.

Sample Input
...
2,531
Posted By Sri3001
Thanks you for that reply , but would be really...
Thanks you for that reply , but would be really nice, if I could get something in AWK or SED.

Thanks
Sri
2,531
Posted By Sri3001
Replace 0's with NULL
Hi all,

Need a small help I am in lookout for a command that changes 0's to NULL in my file, The content will look like

1139,223108,R,2009,0,854,854,854,732,854,854,854,854,854...
1,974
Posted By Sri3001
Real time processing
Hi

Not sure if this can be achieved by unix , but still would like to know if there is any way by which I can do the below given logic

cat sam1 > out1
cat sam2 > out2
when either one of...
992
Posted By Sri3001
Printing using awk
Hi
I am relatively new to awk so i am getting confused a lot
I am in need of help ... I am trying to append coloumns to the end of line using AWK

I tried using this command
awk -F ","...
3,101
Posted By Sri3001
It is not working , I was trying to get...
It is not working ,

I was trying to get the o/p of the first command you have given save it as a file , Then remove the coloumns between the 6th coloumn and the coloumn we get from the 5th...
2,395
Posted By Sri3001
Deleting column using awk
How Can we delete a range of coloumns using awk? (or any other method is fine)

If we have a file which has about 200 coloumns.
I need to delete a particular range lets say for eg from $6 to $119...
3,101
Posted By Sri3001
Sorry, That is not giving the count of...
Sorry,

That is not giving the count of zeros and nulls that was coming before the non null value,

Can you please give me a statement to delete these fields , probably we can append it as the...
3,101
Posted By Sri3001
Thank you Scrutinizer, Can you please...
Thank you Scrutinizer,

Can you please explain me the logic , because this is just one step of my requirement i need to do some more steps in this , I would need the o/p of that 5th Coloumn , My...
3,101
Posted By Sri3001
Counting the number of characters
Hi all,

Can someone help me in getting the following o/p

I/p:...
1,396
Posted By Sri3001
Re
Hi Scrutinizer,

Please find the o/p of od -c command

[xstif@cletld3 ~]$ od -c sri1.txt
0000000 \ \n ' \n " \n
0000006


also the OS i am working with is Linux
1,396
Posted By Sri3001
Thanks But if you see the below set of...
Thanks

But if you see the below set of codes ,
[xstif@cletld3 ~]$ cat sri1.txt
\
'
"
[xstif@cletld3 ~]$ sed 's/\"/\\\"/g' sri1.txt
\
'
\"
[xstif@cletld3 ~]$ sed "s/\'/\\\'/" sri1.txt...
Showing results 1 to 25 of 36

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