Sponsored Content
Full Discussion: sed command to delete row
Top Forums Shell Programming and Scripting sed command to delete row Post 302182966 by anhtt on Tuesday 8th of April 2008 01:54:03 AM
Old 04-08-2008
It cann't work.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

SED: delete matching row and 4 next rows?

Hi, Tried to look for solution, and found something similar but could not adapt the solution for my needs.. I'm trying to match a pattern (in this case "ProcessType")in a logfile, then delete that line and the 4 following lines. The logfile looks as follows: ProcessType: PROCESS_A... (5 Replies)
Discussion started by: Juha
5 Replies

2. Shell Programming and Scripting

sed command to delete points in a certain colum

Dear Unix users, I have a (I think simple) question; I have a file (out.dat) like below, the file contains some line which include 'LOS' string. . LOS 46.5360 91.0220 200708.2515.4900. 5400 64 1100010 . . I would like to delete the points in 4th... (4 Replies)
Discussion started by: mgunduz
4 Replies

3. Shell Programming and Scripting

deleting blank line and row containing certain words in single sed command

Hi Is it possible to do the following in a single command /usr/xpg4/bin/sed -e '/rows selected/d' /aemu/CALLAUTO/callauto.txt > /aemu/CALLAUTO/callautonew.txt /usr/xpg4/bin/sed -e '/^$/d' /aemu/CALLAUTO/callautonew.txt > /aemu/CALLAUTO/callauto_new.txt exit (1 Reply)
Discussion started by: aemunathan
1 Replies

4. Shell Programming and Scripting

SED delete only first line command - Help need

Can any one help me how the sed delete only first line command (D) works. sed -f sedcmds File.txt In this how the sed delete only first line command (D) works to delete the blank lines appearing more than ones leaving only one blank and deleting others blanks. While doing step by step when... (2 Replies)
Discussion started by: gwgreen1
2 Replies

5. Shell Programming and Scripting

Delete a line between selected lines using sed or any other command

I want to delete a line between selected lines using sed: e.g. : Between "bus" to "pins", delete lines conaining "signal" word. Input : bus direction signal new signal old pins signal ok end Desired Output: bus direction pins signal end (4 Replies)
Discussion started by: nehashine
4 Replies

6. Shell Programming and Scripting

sed command to delete line

HI, Im using the below commmand to delete lines having "(" at the start of a line. sed -e '/^(/d' But i need a command to delete lines that has only "(" in it and no other strings. infile - asdf asdf ( asdf ( asd outfile (1 Reply)
Discussion started by: dvah
1 Replies

7. Shell Programming and Scripting

delete the line with a particular string in a file using sed command.

Hello, I want to delete all lines with given string in file1 and the string val is dynamic. Can this be done using sed command. Sample: vars="test twinning yellow" for i in $vars do grep $i file1 if then echo "Do Nothing" else sed `/$i/d` file1 fi done Using the above... (5 Replies)
Discussion started by: PrasadAruna
5 Replies

8. Shell Programming and Scripting

sed command to delete everything after > on line

I have a large data file that I need to edit. There are lines like, > <IDNUMBER> (ST000002) > <SUPPLIER> (ST000002) > <IDNUMBER> (ST000004) > <SUPPLIER> (ST000004) and I need to delete everything after the >, excepting the end of line. > <IDNUMBER> > <SUPPLIER> > <IDNUMBER> > ... (4 Replies)
Discussion started by: LMHmedchem
4 Replies

9. Shell Programming and Scripting

sed command to delete a pattern in a file

Hi Everyone, I have an unusual requirement. Here is where i am stuck for sometime now... I have this text file.. lets say .. output.sql... it has lot of entries... here below is part of the entry... .. . . . . . . . . . . . . . . . .... (3 Replies)
Discussion started by: vivek d r
3 Replies

10. Shell Programming and Scripting

How to delete line from file using sed command?

hello Team, I want to delete below linux using sed command but I am getting error.sed -i '/url=/status.cgi?hostgroup=/d' 3 error:sed: -e expression #1, char 32: unknown option to `s' Could you please help me with correct syntax. My line contain / character because of that I am getting... (4 Replies)
Discussion started by: ghpradeep
4 Replies
RFIO_UNLINK(3)						      Rfio Library Functions						    RFIO_UNLINK(3)

NAME
rfio_unlink - remove a file entry SYNOPSIS
#include <sys/types.h> #include "rfio_api.h" int rfio_unlink (const char *path); int rfio_munlink (const char *path); int rfio_munlink_reset (); int rfio_unend (); DESCRIPTION
rfio_unlink removes a file entry. path specifies the logical pathname relative to the current directory or the full pathname. rfio_munlink is identical to rfio_unlink but keeps the connection open to the server unless there are more than MAXMCON connections already opened. This is useful when issuing a series of unlink calls. The last rfio_munlink call should be followed by a call to rfio_unend. rfio_munlink_reset is to be used when your program is forking. In such a case the permanent connections opened with rfio_munlink become shared between the parent and the child. Use rfio_munlink_reset to perform the necessary reset and close of the socket file descriptor in the parent or the child in order to be sure that only of them will receice an answer from the RFIO daemon. rfio_munlink_reset is to be used when your program is forking. In such a case the permanent connections opened with rfio_munlink become shared between the parent and the child. Use rfio_munlink_reset to perform the necessary reset and close of the socket file descriptor in the parent or the child in order to be sure that only of them will receice an answer from the RFIO daemon. See NOTES section below. RETURN VALUE
This routine returns 0 if the operation was successful or -1 if the operation failed. In the latter case, serrno is set appropriately. NOTES
Multiple connections using rfio_munlink are thread-safe but not process-wide, therefore a forked child cann share file descriptors opened with rfio_munlink by its parent. Use rfio_msymlink_reset in such case. Multiple connections behaviour is undefined if you work in a multi-threaded environment and with threads not created using the LCG's Cthread interface. ERRORS
EPERM path is a directory. ENOENT The named file does not exist or is a null pathname. EACCES Search permission is denied on a component of the path prefix or write permission is denied on the parent directory or the parent has the sticky bit S_ISVTX set and the effective user ID of the requestor does not match the owner ID of the file and the effective user ID of the requestor does not match the owner ID of the directory and the file is not writable by the requestor and the requestor is not super-user. EFAULT path is a NULL pointer. ENOTDIR A component of path prefix is not a directory. ENAMETOOLONG The length of path exceeds CA_MAXPATHLEN or the length of a path component exceeds CA_MAXNAMELEN. SENOSHOST Host unknown. SENOSSERV Service unknown. SECOMERR Communication error. SEE ALSO
Castor_limits(4), rfio_rmdir(3), Cthread(3) AUTHOR
LCG Grid Deployment Team LCG
$Date: 2005/03/31 13:13:04 $ RFIO_UNLINK(3)
All times are GMT -4. The time now is 09:53 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy