Search Results

Search: Posts Made By: abhinav192
20,098
Posted By abhinav192
will this be able to delete 10000 files.... ...
will this be able to delete 10000 files....

---------- Post updated at 05:40 AM ---------- Previous update was at 05:37 AM ----------

where is filename coming in the command that you have...
20,098
Posted By abhinav192
Deleting files in awk
Hi All,

I have about 10000 files having names of the same pattern

I am using awk to match the pattern.

Inside the awk block how can i delete all the 10000 files..


Or is there any...
3,672
Posted By abhinav192
Hi , This is not working ----------...
Hi ,

This is not working

---------- Post updated at 10:43 AM ---------- Previous update was at 10:32 AM ----------

Hi All,

If i do

echo "$DateFileFormat" | sed 's/\./\\\\./g' | sed...
3,672
Posted By abhinav192
Taking sed result in a variable
Hi All,

How can i take the following code having three seds into a variable :

echo "$DateFileFormat" | sed 's/\./\\\\./g' | sed 's/\$/[0-9]+/g' | sed 's/\#/'$job_date'/g'


I want to get...
1,905
Posted By abhinav192
Hi tony, The point is i want to get the...
Hi tony,

The point is i want to get the replaced string in a variable
1,905
Posted By abhinav192
Replacing tokens
Hi all,

I have a variable with value

DateFileFormat=NAME.CODE.CON.01.#.S001.V1.D$.hent.txt


I want this variable to get replaced with :

var2 is a variable with string value
...
2,298
Posted By abhinav192
calling a method inside awk
Hi All,

How do we call a method existing in another file inside awk.

After matching a pattern i want to call a method secureCopy that exists in another file, but method not getting called:
...
2,382
Posted By abhinav192
Reading a variable from parameter file
HI all,

I have a parameter file with entries like

$$Name =Abhinav
$$CUTOFF_DATE = 11/11/2209

I am reading a variable from this file using a awk command like :

var2=`awk -F"[=]"...
2,017
Posted By abhinav192
Accessing a variable from another file
HI all,

How can i access a variable that is
defined in another file as: $$Name= "abhinav;

in my script.

The catch is that it has 2 $s behind it...

Thnaks

---------- Post updated...
1,492
Posted By abhinav192
cant this be done without perl
cant this be done without perl
1,492
Posted By abhinav192
help with sed
Hi all


I have a large file with some text in it..

I am using command : sed 's/text/human/g' text.txt

but this prints the resultant file...

I dont want that file on my screen, but ...
9,884
Posted By abhinav192
Thanks Jean for quick reply.. Real FileName...
Thanks Jean for quick reply..

Real FileName example would be :

EAGFRU.UK.01.$date.S001.V001.D1.data.xml
EAGFRU.UK.01.$date.S001.V001.D2.data.xml
EAGFRU.UK.01.$date.S001.V001.D3.data.xml
....
9,884
Posted By abhinav192
HI Jean, Can you Please review the below...
HI Jean,

Can you Please review the below snippet and let me know if its fine ad will solve my purpose :

ls -l 2>/dev/null |
awk -v var=$TOTAL -v var2=$job_date '
BEGIN { pattern =...
9,884
Posted By abhinav192
i already did this, but it was not matching any...
i already did this, but it was not matching any file name..

are you sure that we will have "$0 ~ pattern" in there..

because above this we are having " ls -l " as suggested by you..for...
9,884
Posted By abhinav192
Name of the file will be like: ...
Name of the file will be like:

FileName.Version.JobDate.SerialNumber.Constant.xml

Now all the things can be hardcoded, but only Jobdate will vary with time..

This Date is extracted and...
9,884
Posted By abhinav192
Hi Jean, i used your code in my script which...
Hi Jean,
i used your code in my script which was also told by you : but the files are not matching the patterns and not getting printed
ls -l 2>/dev/null |
awk -v var=$TOTAL -v var2=$job_date '...
9,884
Posted By abhinav192
Thanks ahmad.diab, I want this variable...
Thanks ahmad.diab,


I want this variable in between the Name and version as shown above..

How to go about that

---------- Post updated at 11:17 AM ---------- Previous update was at 11:16 AM...
9,884
Posted By abhinav192
Using a script variable in awk search patterns
Hi all,

In a script like :

job_date=....

ls -l 2>/dev/null |
awk -v var =$job_date '
/Name\.Version\.[0-9]+\.xml$/ {

How can i include a script variable job_date store in "var" ...
2,513
Posted By abhinav192
Great help... But how did this code manage...
Great help...

But how did this code manage so many files..can you please explain a bit....

It will be really helpful..

---------- Post updated at 10:05 AM ---------- Previous update was at...
6,085
Posted By abhinav192
got it
got it
2,513
Posted By abhinav192
Hi Jean-Pierre, The above code is mentioning...
Hi Jean-Pierre,

The above code is mentioning all the exisiting xmls in the file.

I want only those xmls which have a specific pattern.

I have 300k file s of some fixed pattern like...
2,513
Posted By abhinav192
Hi all, As i am having close to 300k files...
Hi all,

As i am having close to 300k files in my database, so ls -l *.xml is failing.

I have file names like file1 to file300000...

Can i do this job in batches of 1000s and using '?'...
6,085
Posted By abhinav192
NOT WORKING
NOT WORKING
6,085
Posted By abhinav192
hi FRanklin, As always, great help... ...
hi FRanklin,

As always, great help...

Can you please explain this command in parts...It would be a great help
6,085
Posted By abhinav192
can we achieve this using sed??
can we achieve this using sed??
Showing results 1 to 25 of 36

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