- Community Home
 - >
 - Servers and Operating Systems
 - >
 - Operating Systems
 - >
 - Operating System - HP-UX
 - >
 - Re: Pattern substitution
 
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
 - Entry Storage Systems
 - Legacy
 - Midrange and Enterprise Storage
 - Storage Networking
 - HPE Nimble Storage
 
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
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
Community
Resources
Forums
Blogs
- 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-11-2002 01:23 AM
05-11-2002 01:23 AM
find: /fs36/nwd/f1 :Permission denied
find: /fs36/nwd/f1/audio :Permission denied
How do I write a csh script to do that? What is the single command utility does the job?
Thanks.
Solved! Go to Solution.
- Mark as New
 - Bookmark
 - Subscribe
 - Mute
 - Subscribe to RSS Feed
 - Permalink
 - Report Inappropriate Content
 
05-11-2002 01:32 AM
05-11-2002 01:32 AM
			
				
					
						
							Re: Pattern substitution
						
					
					
				
			
		
	
			
	
	
	
	
	
command to use
cat file | awk -F : '{print $2}' > file2
Hope this helps
Steve
- Mark as New
 - Bookmark
 - Subscribe
 - Mute
 - Subscribe to RSS Feed
 - Permalink
 - Report Inappropriate Content
 
05-11-2002 01:37 AM
05-11-2002 01:37 AM
			
				
					
						
							Re: Pattern substitution
						
					
					
				
			
		
	
			
	
	
	
	
	
%s/find:/ /g
%s/:Permission denied/ /g
- Mark as New
 - Bookmark
 - Subscribe
 - Mute
 - Subscribe to RSS Feed
 - Permalink
 - Report Inappropriate Content
 
05-11-2002 01:43 AM
- Mark as New
 - Bookmark
 - Subscribe
 - Mute
 - Subscribe to RSS Feed
 - Permalink
 - Report Inappropriate Content
 
05-11-2002 01:47 AM
05-11-2002 01:47 AM
			
				
					
						
							Re: Pattern substitution
						
					
					
				
			
		
	
			
	
	
	
	
	
After using vi to edit the file
%s/find:/ /g
Your method also works
Steve
- Mark as New
 - Bookmark
 - Subscribe
 - Mute
 - Subscribe to RSS Feed
 - Permalink
 - Report Inappropriate Content
 
05-11-2002 01:58 AM
05-11-2002 01:58 AM
			
				
					
						
							Re: Pattern substitution
						
					
					
				
			
		
	
			
	
	
	
	
	
cat f1 | grep -v "Permission denied" > newfile
cheers
John.
- Mark as New
 - Bookmark
 - Subscribe
 - Mute
 - Subscribe to RSS Feed
 - Permalink
 - Report Inappropriate Content
 
05-11-2002 02:07 AM
05-11-2002 02:07 AM
			
				
					
						
							Re: Pattern substitution
						
					
					
				
			
		
	
			
	
	
	
	
	
please ignore my last response I misread the question the grep -v will remove the full line from the file.
cat f1 | cut -f2 > newfile
John