Search Results

Search: Posts Made By: userix
3,845
Posted By userix
Finding Minimum value per Row range of data
Here is an example of a file I am working with:


C 4704 CB 1318 ASP 115 BGRF 1 weak 0.0% 4.33
C 4720 OD 1322 ASP 115 BGRF 1 weak 0.0% 3.71
O 4723 OD 1322 ...
19,588
Posted By userix
for (@test) { $last = `awk '/OXT/{print...
for (@test)
{
$last = `awk '/OXT/{print \$4}' $_`;
$lastnum = `awk '/OXT/{print \$5}' $_`;
system("sed -i -e '/O ${last} ${lastnum}/{s/-0.51000\$/-0.25500/;}' $_");
system("sed...
19,588
Posted By userix
I want to search for a number found in the 4th...
I want to search for a number found in the 4th column on a specific line in a file and store that value into a variable. This file contains over 7000 lines of data. The specific line I am looking...
19,588
Posted By userix
Saving output from awk into a perl variable
How would I pass awk output to a perl variable?

For example, I want to save the value in the 4th column into the variable called test. My best guess is something as follow, but I am sure this...
13,312
Posted By userix
[Perl] Accessing array elements within a sed command in Perl script
I am trying to use a script to replace the header of each file, whose filename are stored within the array $test, using the sed command within a Perl script as follows:

$count = 0;
while ( $count...
14,823
Posted By userix
I have a similar issue. I also need to pass a...
I have a similar issue. I also need to pass a perl variable into the sed command as follows:

system("sed -e s/",$test[0],"/",$test[1],"/g file > output");
Basically, I want to have my perl...
56,585
Posted By userix
[PERL] Running unix commands within Perl Scripts
I understand that in order to run basic unix commands I would normally type at the prompt, I would have to use the following format
system(ls -l);
or
exec(ls -l);

But when I actually try to use...
9,515
Posted By userix
I grabbed the definition of sticky bit from...
I grabbed the definition of sticky bit from wikipedia: "when set, items inside the directory can be renamed or deleted only by the item's owner, the directory's owner, or the superuser"

So would...
6,877
Posted By userix
How come my code in the OP does not work? Is...
How come my code in the OP does not work? Is there a different syntax I need for the condition of my if statement?
6,877
Posted By userix
Thanks. So it's not possible to check using the...
Thanks. So it's not possible to check using the if statement?
6,877
Posted By userix
[csh] checking for specific character ranges in a variable
I want to check if a zip code is valid, using a variable that stores the zipcode. I am not sure how I would do this in a script. I know that simply checking for the numerical range of the number...
9,515
Posted By userix
If I use sticky bit, wouldn't that not allow my...
If I use sticky bit, wouldn't that not allow my script to delete the temp file when he runs it? Since he is not the owner of my script.
If I need to allow him to run my script from within my...
9,515
Posted By userix
I am curious if it is possible to do it without...
I am curious if it is possible to do it without temp file, because I can set the data into a variable, but the only problem is the newlines not being stored as well. Is this a limitation with the...
9,515
Posted By userix
echo command and file I/O Redirection
I have a colon-delimited text file of names, addresses and phone numbers. I am trying to write a script that can add additional entries and then sort it alphabetical by last name and resave it to...
Showing results 1 to 14 of 14

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