Sponsored Content
Top Forums Shell Programming and Scripting How to find union of two files Post 91834 by futurelet on Tuesday 6th of December 2005 04:39:05 AM
Old 12-06-2005
Code:
ruby -e 'puts IO.read($*[0]).to_a - IO.read($*[1]).to_a' dat1 dat2

 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Find files older than 20 days & not use find

I need to find files that have the ending of .out and that are older than 20 days. However, I cannot use find as I do not want to search in the directories that are underneath the directory that I am searching in. How can this be done?? Find returns files that I do not want. (2 Replies)
Discussion started by: halo98
2 Replies

2. Shell Programming and Scripting

Little bit weired : Find files in UNIX w/o using find or where command

Yes , I have to find a file in unix without using any find or where commands.Any pointers for the same would be very helpful as i am beginner in shell scritping and need a solution for the same. Thanks in advance. Regards Jatin Jain (10 Replies)
Discussion started by: jatin.jain
10 Replies

3. Shell Programming and Scripting

union of two files

Given two files of the same format (For example number1|text1|number2) what is the command to print lines in file1 which do not occur in file2? diff command seems a bit complicated for me for this purpose. Please help!! Thank you very much. (3 Replies)
Discussion started by: sherkaner
3 Replies

4. Shell Programming and Scripting

Text files union

How can i union two files that each of them contain text to one new file in unix shell scripting or in awk scripting language? (2 Replies)
Discussion started by: tal
2 Replies

5. Shell Programming and Scripting

awk: union regions

Hi all, I have difficulty to solve the followign problem. mydata: StartPoint EndPoint 22 55 2222 2230 33 66 44 58 222 240 11 25 22 60 33 45 The union of above... (2 Replies)
Discussion started by: phoeberunner
2 Replies

6. Web Development

Intersection and union of array by hash

Hi, A piece of script from Perl-cookbook I do not understand, and post here for explanation. The purpose is to find the element in either array (union), and in both array (intersection). Thank you in advance. @a=qw(1 3 5 6 7 8); @b=qw(2 3 5 7 9); foreach $e (@a, @b) {$union{$e}++ &&... (3 Replies)
Discussion started by: yifangt
3 Replies

7. Programming

GDB and GCC union

My concept may sound a bit cryptic but I what some startup information as to how we can use GDB APIs / debugging techniques in programs with GCC when we compile the program. We can definitely tell gcc to link GDB libs also. The ultimate aid would be that when the compiled programs executes it... (4 Replies)
Discussion started by: uunniixx
4 Replies

8. Programming

Event driven programming / epoll / typedef union / session data array

Sorry for the “word salad” subject, but I wanted to cast a wide net for help. I've created an IP (Internet Protocol) server which serves HTTP, SMTP, and FTP requests. As you probably know, they all require creating a socket, listening on it, accepting connections, and then having a short... (3 Replies)
Discussion started by: John S.
3 Replies

9. Shell Programming and Scripting

Find command to find a word from list of files

I need to find a word '% Retail by State' in the folder /usr/sas/reports/RetailSalesTaxallocation. When I tried like below, -bash-4.1$ cd /usr/sas/reports/RetailSalesTaxallocation -bash-4.1$ find ./ -name % Retail by State find: paths must precede expression: Retail Usage: find ... (10 Replies)
Discussion started by: Ram Kumar_BE
10 Replies
ODIDX(1)						      Quick Database Manager							  ODIDX(1)

NAME
odidx - indexer of document files SYNOPSIS
odidx register [-l file] [-wmax num] [-tsuf sufs] [-hsuf sufs] name[dir] odidx relate name odidx purge name DESCRIPTION
This manual page documents briefly the odidx commands. The command odidx is a utility for indexing files on the local file system. This command is useful for a full-text search system of a Web site. Supported file format are plain text and HTML. Supported character encoding are US-ASCII and ISO-8859-1. The URI of each document is specified with the path of its file. Attributes named as title and date are given to each documents. When a document is already existing in the database, it is registered if its last modification time is newer, or it is ignored. Modification times are stored in the sub database `_mtime' in the main database directory. Score information are stored in the sub database `_score' in the main database directory. This command is used in the above format. name specifies a database name. dir specifies a directory name. OPTIONS
A summary of options is included below. For a complete description, see the file:///usr/share/doc/qdbm-doc/spex.html#odeumcli. -l file read a file and get list of paths of files to register. If `-' is specified, the standard input is read. -wmax num specify the max number of words to be stored in the document database. -tsuf sufs specify suffixes of plain text files in comma separated format. The default is `-tsuf .txt,.text'. -hsuf sufs specify suffixes of HTML files in comma separated format. The default is `-hsuf .html,.htm'. EXAMPLES
For example, to register files which are under `/home/mikio' and whose suffix are `.txt', `.c', or `.h', perform the following command. odidx register -tsuf ".txt,.c,.h" -hsuf "" casket /home/mikio Thus, to retrieve documents which include `unix' and `posix' and show the top 8 terms, perform the following command. odmgr search -max 8 -h casket "unix posix" SEE ALSO
qdbm(3), odmgr(1), odeum(3), odopen(3). AUTHOR
QDBM was written by Mikio Hirabayashi <mikio@fallabs.com>. This manual page was written by Fumitoshi UKAI <ukai@debian.or.jp>, for the Debian project (but may be used by others). Man Page 2005-05-23 ODIDX(1)
All times are GMT -4. The time now is 07:54 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy