- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- script to modify file
Operating System - HP-UX
1758569
Members
1978
Online
108872
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-10-2010 06:21 AM
тАО05-10-2010 06:21 AM
Hi All,
i have a script to search for oracle alert log file "ORA-" and it is working fine.
i would like to do: when it find "ORA-", it will add a character like " A" to "ORA" like this "AORA" and save the file.
is it possible.
Please help.
Thanks,
Tom
i have a script to search for oracle alert log file "ORA-" and it is working fine.
i would like to do: when it find "ORA-", it will add a character like " A" to "ORA" like this "AORA" and save the file.
is it possible.
Please help.
Thanks,
Tom
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-10-2010 06:25 AM
- Tags:
- Perl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-10-2010 09:02 AM
тАО05-10-2010 09:02 AM
Re: script to modify file
Thanks James,
It works,
if i just want to search for ORA- and not AORA-
i am using grep ORA- now and the result :
ORA- AND AORA-
how can i limit the search only to ORA- but not AORA-.
Thanks very much for your help.
It works,
if i just want to search for ORA- and not AORA-
i am using grep ORA- now and the result :
ORA- AND AORA-
how can i limit the search only to ORA- but not AORA-.
Thanks very much for your help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-10-2010 09:31 AM
тАО05-10-2010 09:31 AM
Re: script to modify file
Hi (again) Tom:
# perl -pi.old -e 's/\bORA\b/AORA/' logfile
This substitutes "AORA" for the sequence "ORA" when "ORA" is bounded by a "word" boundary. That is, where there is a "word character" on one side but not the other.
Regards!
...JRF...
# perl -pi.old -e 's/\bORA\b/AORA/' logfile
This substitutes "AORA" for the sequence "ORA" when "ORA" is bounded by a "word" boundary. That is, where there is a "word character" on one side but not the other.
Regards!
...JRF...
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP