09-06-2012
input
this is my book |
and it is pen |
do you like it |
output is first word deleted
is my book |
it is pen |
you like it |
basically I want to print words between first and last word
or drop first and last word .. but having problems with the last word bit
p.s. they are .txt files with line breaks
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi I have a text file like this name today.txt
the request has been accepted
the scan is successful at following time
there are no invalid packages
5169378 : map : Permission Denied
the request has been accepted
Now what i want do is
I want to search the today.txt file and
if i... (1 Reply)
Discussion started by: gsusarla
1 Replies
2. UNIX for Advanced & Expert Users
Hi Canone please provide me solution how can achieve the result below:
File1.txt
$
sweet appleŁ1
scotish
green
$
This is a test1
$
sweet mangoŁ2
asia
yellow
$
This is a test 2
$
sweet apple red (there is no pound symbol here)
germany
green (1 Reply)
Discussion started by: Aejaz
1 Replies
3. Shell Programming and Scripting
Hi All
Can u help me..
My problem is delete word per line
sample:
cat /tmp/file.txt
monitor 192.168.1.11 Copying files in current directory 1
monitor 192.168.1.1 Copying files in current directory 2
monitor 192.168.1.12 Copying files in current directory 3
monitor 192.168.1.14... (1 Reply)
Discussion started by: carnegiex
1 Replies
4. Shell Programming and Scripting
write a shell script that deletes all lines containing a specified word in one or more files supplied as arguments to it.help is appreciated .thank you. (2 Replies)
Discussion started by: shawz
2 Replies
5. Shell Programming and Scripting
Hello,
I have several files in a specific directory.
A specific string in one file can occur in another files.
If this string is in other files. Then all the files in which this string occured should be deleted and only 1 file should remain with the string.
Example.
file1
ShortName "Blue... (2 Replies)
Discussion started by: premier_de
2 Replies
6. Shell Programming and Scripting
I have a line that gets pulled from a database that has a variable number of fields, fields can also be of a variable size. Each field has a variable number of spaces between them so there is no 'defined' delimiter. The LastData block is always a single word.
What I want to do is delete the... (2 Replies)
Discussion started by: Bashingaway
2 Replies
7. Shell Programming and Scripting
I am writing a script below, which has 2 loops. The outer one reads file sufffixed with a number and inner inside which loop through each line of the file and display each space delimited string. However, i find that the string printed out in the inner loop includes not only the delimited string in... (2 Replies)
Discussion started by: martie
2 Replies
8. UNIX for Dummies Questions & Answers
I have a file from which I am trying to delete a particular word on a particular line.
NEW
NEW
/v/engine
NEW
/ifs/list
NEW
/ifs/vdrome
NEW
I am trying to delete the first line only if it contains the word NEW. I am also trying to delete the last line only if it contains the word NEW. I... (11 Replies)
Discussion started by: newbie2010
11 Replies
9. Shell Programming and Scripting
I have a file: file.txt, which contains the following data in it.
This is a file, my name is Karl, what is this process, karl is karl junior, file is a test file, file's name is file.txt
My name is not Karl, my name is Karl Joey
What is your name?
Do you know your name and... (3 Replies)
Discussion started by: anuragpgtgerman
3 Replies
10. Shell Programming and Scripting
he following are the files available in my directory
RSK_123_20141113_031500.txt
RSK_123_20141113_081500.txt
RSK_126_20141113_041500.txt
RSK_126_20141113_081800.txt
RSK_128_20141113_091600.txt
Here, "RSK" is file prefix and 123 is a code name and rest is just timestamp of the file when its... (7 Replies)
Discussion started by: kridhick
7 Replies
LEARN ABOUT CENTOS
drop_foreign_table
DROP FOREIGN
TABLE(7) PostgreSQL 9.2.7 Documentation DROP FOREIGN TABLE(7)
NAME
DROP_FOREIGN_TABLE - remove a foreign table
SYNOPSIS
DROP FOREIGN TABLE [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]
DESCRIPTION
DROP FOREIGN TABLE removes a foreign table. Only the owner of a foreign table can remove it.
PARAMETERS
IF EXISTS
Do not throw an error if the foreign table does not exist. A notice is issued in this case.
name
The name (optionally schema-qualified) of the foreign table to drop.
CASCADE
Automatically drop objects that depend on the foreign table (such as views).
RESTRICT
Refuse to drop the foreign table if any objects depend on it. This is the default.
EXAMPLES
To destroy two foreign tables, films and distributors:
DROP FOREIGN TABLE films, distributors;
COMPATIBILITY
This command conforms to the ISO/IEC 9075-9 (SQL/MED), except that the standard only allows one foreign table to be dropped per command,
and apart from the IF EXISTS option, which is a PostgreSQL extension.
SEE ALSO
ALTER FOREIGN TABLE (ALTER_FOREIGN_TABLE(7)), CREATE FOREIGN TABLE (CREATE_FOREIGN_TABLE(7))
PostgreSQL 9.2.7 2014-02-17 DROP FOREIGN TABLE(7)