Sponsored Content
Full Discussion: Unix File operations
Top Forums Shell Programming and Scripting Unix File operations Post 302165236 by nivas on Thursday 7th of February 2008 06:25:12 AM
Old 02-07-2008
Unix File operations

Hi,

Iam having the two files as follows:

file1:

ASQWEDFR09876543121234512
POIUYTREW09876512345676788
ZXCVBNMKS1209888888888888

file2:
ASQWEDFR09876543121234516 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----
CXADFGTU09876543121234789 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----
KLOPIUYRE09876541234234516 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----
ZXSDCVFG09876512345634516 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----


i WANT TO update the contents in file1 to file2 and remove the other lines.

example.:

ASQWEDFR09876543121234516 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----
POIUYTREW0987651234567678 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----
ZXCVBNMKS1209888888888888 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----
nivas
 

8 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

mathematics operations in unix

Hello guys! Can say me anybody about operatios with unix, I don't to make operations, only inside in a variable, like this #y=4 #x=2 #let z=$y-$x #echo $z # 2 but I can't to make mathematical operations with decimal like this #y=3.2 #x=1.5 #let z=$y-$x #echo $z # 3 this... (2 Replies)
Discussion started by: cesar720213
2 Replies

2. UNIX Desktop Questions & Answers

where i can find list of UNIX commands for daily operations ?

Hi There, Can anyone help, where i can find list of UNIX commands just for regulat day ro day operations Thanx MGR (1 Reply)
Discussion started by: mgoutham
1 Replies

3. UNIX for Dummies Questions & Answers

File operations

Hi I have a tab delimited file with 3 fields. I need to sort this file on the first field and remove all the records where the first field has dulplicates. For eg my file is 133|arrfdfdg|sdfdsg 234|asfsdgfs|aasdfs 133|affbfsde|dgfg When this file gets sorted I need the result to be ... (2 Replies)
Discussion started by: monks
2 Replies

4. Shell Programming and Scripting

Unix file operations(shell script)

Hi, I want to compare two files. Files will look like as follows: file1: ASDFGHJU|1234567890123456 QWERTYUI|3456789098900890 file2: ZXCVBVNM|0987654321234567 POLKIJUYH|1234789060985478 output file should be: ASDFGHJU|1234567890123456 QWERTYUI|3456789098900890 Thnaks in advance (6 Replies)
Discussion started by: nivas
6 Replies

5. Shell Programming and Scripting

Date operations in Unix?

Hi Friends, I need help in below requirements, 1. I have to get current datetime + <mins> into a variable 2. I have to compage dates like, A=01-JAN-2009 10:20:10 B=01-JAN-2009 10:30:00 C=<same format date as above> I have to find whether, 1. C is less than A OR, 2. C is greater... (7 Replies)
Discussion started by: smr_rashmy
7 Replies

6. IP Networking

What is the best Unix-like for firewalling operations

Hello from France, I'd like to have your opinion on this : What unix-like would you choose for high bandwidth netwoking operations like a cluster of statefull firewalls ? NetBSD, Linux, others ? Thank you. Best regards. Vincent. (0 Replies)
Discussion started by: vrzs
0 Replies

7. Shell Programming and Scripting

How to search and append words in the same file using unix scripting file operations

Hi , I have a file myhost.txt which contains below, 127.0.0.1 localhost 1.17.1.5 atrpx958 11.17.10.11 atrpx958zone nsybhost I need to append words only after "atrpx958" like 'myhost' and 'libhost' and not after atrpx958zone. How to search the word atrpx958(which is hostname) only,... (5 Replies)
Discussion started by: gsreeni
5 Replies

8. Shell Programming and Scripting

To skip operations in UNIX shell

hi i am having a acript for which i need to skip the execution of some lines and to continue with remaining lines for eg script.sh rm text for i in * do . . . . . if then rm i want to skip the execution of the lines and to start with (11 Replies)
Discussion started by: rohit_shinez
11 Replies
LTSCOMPARE(1)							   User Commands						     LTSCOMPARE(1)

NAME
ltscompare - compare two LTSs SYNOPSIS
ltscompare [OPTION]... [INFILE1] INFILE2 DESCRIPTION
Determine whether or not the labelled transition systems (LTSs) in INFILE1 and INFILE2 are related by some equivalence or preorder. If INFILE1 is not supplied, stdin is used. The input formats are determined by the contents of INFILE1 and INFILE2. Options --in1 and --in2 can be used to force the input format of INFILE1 and INFILE2, respectively. The supported formats are: 'aut' for the Aldebaran format (CADP), 'dot' for the GraphViz format, 'fsm' for the Finite State Machine format, 'lts' for the mCRL2 LTS format, or 'svc' for the SVC format OPTIONS
OPTION can be any of the following: -c, --counter-example generate counter example traces if the input lts's are not equivalent -eNAME, --equivalence=NAME use equivalence NAME: 'bisim' for strong bisimilarity, 'branching-bisim' for branching bisimilarity, 'dpbranching-bisim' for divergence preserving branching bisimilarity, 'sim' for strong simulation equivalence, 'trace' for strong trace equivalence, or 'weak-trace' for weak trace equivalence (not allowed in combination with -p/--preorder) -iFORMAT, --in1=FORMAT use FORMAT as the format for INFILE1 (or stdin) -jFORMAT, --in2=FORMAT use FORMAT as the format for INFILE2 -pNAME, --preorder=NAME use preorder NAME: 'sim' for strong simulation preorder, 'trace' for strong trace preorder, or 'weak-trace' for weak trace preorder (not allowed in combination with -e/--equivalence) --tau=ACTNAMES consider actions with a name in the comma separated list ACTNAMES to be internal (tau) actions in addition to those defined as such by the input --timings[=FILE] append timing measurements to FILE. Measurements are written to standard error if no FILE is provided Standard options: -q, --quiet do not display warning messages -v, --verbose display short intermediate messages -d, --debug display detailed intermediate messages --log-level=LEVEL display intermediate messages up to and including level -h, --help display help information --version display version information AUTHOR
Written by Muck van Weerdenburg. REPORTING BUGS
Report bugs at <http://www.mcrl2.org/issuetracker>. COPYRIGHT
Copyright (C) 2012 Technische Universiteit Eindhoven. This is free software. You may redistribute copies of it under the terms of the Boost Software License <http://www.boost.org/LICENSE_1_0.txt>. There is NO WARRANTY, to the extent permitted by law. SEE ALSO
See also the manual at <http://www.mcrl2.org/mcrl2/wiki/index.php/User_manual/ltscompare>. ltscompare mCRL2 toolset 201202.0 (Release) April 2012 LTSCOMPARE(1)
All times are GMT -4. The time now is 10:08 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy