Home › Forums › Archives › Computer Support › Computer Support Discussion › Microsoft Word 2003 trouble.
- This topic has 2 replies, 2 voices, and was last updated 21 years, 1 month ago by
GoldenKnight8987.
-
AuthorPosts
-
September 16, 2005 at 9:58 pm #19981
GoldenKnight8987
MemberOKay, I dont even know what to call this…. but I know I have done it before…. I dont know if it was in word or another gadget…. didnt even know what to look for under google…. ANYWAYS…. here’s what I am trying to do.
I have 2 huge gigantic lists of things on 2 seperate word documents. I’d like to find matches in the two documents and highlight it or something…
Say my list is
apples
bananas
orangesList2:
grapefruit
kiwi
bananasit would find that bananas was in both documents…… I dont even know what word I am searching for…. there’s like 400 words on each document and I am trying to see if there are any of the same ones on each list, so I can remove them from one of the lists.
How do I do this?!?! Thanks in advance!
September 16, 2005 at 11:25 pm #130232Jeff Hester
KeymasterWord is not the type of software you need for this (scroll down if you want to use Word). you need really small, fast, and simple unix programs. if you have access to a shell (free shell account info: https://bigblueball.com/forums/showthread.php?t=32022#post178163) you can type the following will add the two files together and then remove any duplicates (keeping one of them) in the two files. it will then save the file as the output. type (or paste) cat file1 file2 | sort | uniq > output at the prompt.
for example… if you had a file f.txt and a file g.txt which you suspected contained duplicates you could type the following: cat f.txt g.txt | sort | uniq > lala.txt which would save the output as lala.txt. (you can also choose to only display the duplicates cat file1 file2 | sort | uniq -d > output. read more about uniq, sort, or cat in their manual pages (command man uniq, man sort, or man cat)
after the command has been preformed:
cat f.txt:Code:boo
hh
jj
oo
ll
lala
34cat g.txt:
Code:boo
la
34cat lala.txt:
Code:34
boo
hh
jj
la
lala
ll
ooif you do not want to get into all this unix junk here is how to do it in word.
open up one of the .doc files in Microsoft Word. click on Insert>> File >> find your second list and click Insert (from http://www.techlearning.com/story/showArticle.jhtml?articleID=47902766).
remove duplicates in Microsoft Word: http://informationweek.desktoppipeline.com/shared/article/printablePipelineArticle.jhtml?articleId=169400914 (sorry about the ads, but the print view is easier to read).September 17, 2005 at 12:57 am #130233GoldenKnight8987
Memberhey thanks! I got what I needed accomplished!
-
AuthorPosts
- You must be logged in to reply to this topic.