SYSOPS: please place MERGS1B3.ZIP with BBS UTILITIES. Thank you. The text that follows was contributed by Charles Strusz, the sysop of InfoQuest BBS in Carbondale, IL, whose desire for a merge program to help manage his file lists led to the development of MERGEPRO/MERGESYS. You can also see EXAMPLES.DOC for more suggestions on using MERGE. Hello Fellow Sysop! This PCB utility has value! Please Check it Out! Hal Parks of HAL SoftWare modified his 'Merge' ASCII text file combiner at my request to handle duplicate removal and PCB DIR list combining. Merge actually does a lot more than that, but here's what you can use Merge for: You download stuff for your BBS, and users upload stuff. (hah!) So this is fine as long as the hard drive space lasts. Then you get the new Night Owl XXXVIII, and find that half that stuff on the hard drive is duplicated on your new CD. So you run a dupe checker that won't puke on a CD (I like DFL), and kill those dupes from the hard drive. Ahh... that feels better. But what to do about all the text listings in your DIR file? PCBFILER? Yes, but with great difficulty and hours of manually tagging stuff to be deleted. Merge to the rescue! PCBFILER will remove duplicate filenames with their descriptions from a single DIR. The problem is that it is too cautious and prompts you for every single duplicate encountered. It can take hours of boredom picking description 1 or description 2, plus, it is SLOW, since it takes a filename and then compares it against every other filename in the list, then gets the next filename... I have had some success wedging a a full can of brew on the keyboard to hold down the '1' key. If you want to find dupes across DIR listings, you are out of luck. Merge takes a different approach. With Merge, you can eliminate all duplicate text listings in your DIR file descriptions in a few moments. Merge is like lightning! Do you run several Shareware CD-Roms? Don't you hate how each set of CD-ROM DIRs has to either be in its own conference or you have to use some DOOR to access your CDs? Just wait 'till you have dual 18-CD Changers like I do! (for sale cheap, btw... I want a 100 CD changer!) Managing 250,000 file descriptions tends to be a bit of a chore. MERGE makes it easy to keep all your files together without duplicate listings caused by duplication between CDs! Don't you hate having to Z)ippy search first the main files, then the conferences or the CD-ROM door to find a file or text in a description? The solution is simple. Keep all your files descriptions in the main area. When you get a new cd, just figure out with pencil or text editor how the categories on the CD relate to your own categories, then write (or modify the one you used last time) a batch file to copy the files together, like this: (Work with Backups ONLY) :::NIGHT38.BAT COPY D:\PCB\DIR\DIR1 + C:\NEWCDDIRS\DIR1 COPY D:\PCB\DIR\DIR2 + C:\NEWCDDIRS\DIR2 COPY D:\PCB\DIR\DIR3 + C:\NEWCDDIRS\DIR3 COPY D:\PCB\DIR\DIR4 + C:\NEWCDDIRS\DIR4 (Continue for each dir on the new CD, usually 60 lines or so) Of course, the illustration above assumes a perfect world where the CD Dir categories match those on your bbs, but you can see that if YOUR DIR1 is Games and the Games DIR on the CD is DIR22, your batch file will have to look like this: COPY D:\PCB\DIR\DIR1 + C:\NEWCDDIRS\DIR22 IN FACT, I have a batch file that calls ALL THE BATCH FILES for all the CDs I have online! That is so I can easily recombine all my DIR files when I take a CD offline! It looks like this: :::COMPILE.BAT CALL NIGHT11.BAT CALL NIGHT12.BAT CALL NIGHT13.BAT CALL PIER3.BAT CALL PIER4.BAT CALL GIFA2Z.BAT Now for the rub: with all the Shareware CDs out there, you are going to have duplication. No way around that. Your dirs will now show endless copies of SPAZBOOB.ZIP, since every new CD out there probably has the latest version of SpaceBoobs on it. Just run MERGE on each dir to get rid of those duplicate listings. The DIRs copied together above still need to be sorted, so run PCBFILER on each one - maybe more than once, depending on how you want your lists to look. Assume, in the case of duplicate descriptions, you want to keep the one with the latest date. You'd need to sort each DIR first on date descending, which gets all the newer dates toward the top. Since MERGE can only remove duplicate names when they are adjacent, next sort each list on name ascending, then run MERGE: MERGE A SINGLE FILE: merge FILENAME LIKE SO: MERGE DIR1 MERGE DIR2 MERGE DIR3 MERGE DIR4 Voila! No more dupes. When a duplicate name is encountered, only the first is kept, which is also the latest date. If you're concerned about what's been removed, use MERGE's /T option to write all stripped dupes to a 'trash' file, which you can check later. WELL, that's one way, but there's another, much quicker, depending on how your DIRs are organized. Assuming both your hard drive and the CD-ROM lists are already in name ascending order, you can just MERGE them together. (After all, it IS a merge program!) The question is, if a dupe is found, which one do you want to keep, the one off your bbs or the CD-ROM? Whichever, make that DIR file1 and the other file2. The merged list will be file2 when two file names are used, but you can also specify a separate output file if you like, which will retain both original lists: MERGE D:\PCB\DIR\DIR1 C:\NEWCDDIRS\DIR22 D:\PCB\DIR\NEWDIR1 MERGE D:\PCB\DIR\DIR2 C:\NEWCDDIRS\DIR13 D:\PCB\DIR\NEWDIR2 MERGE D:\PCB\DIR\DIR3 C:\NEWCDDIRS\DIR9 D:\PCB\DIR\NEWDIR3 So, that's great, how do I remove dupe listings from ALL my DIRs? MERGE FILE1 AGAINST FILE2: merge file1 file2 /1 /1 doesn't merge both files together, but 'compares' file1 to file2 and removes any name from file2 that is also in file1 (file1 isn't touched). MERGE DIR1 DIR2 /1 MERGE DIR1 DIR3 /1 MERGE DIR1 DIR4 /1 MERGE DIR1 DIR5 /1 MERGE DIR1 DIR6 /1 Just keep that up for however many dirs you have and then start in on DIR2 (it is already merged against DIR1). And you have it! I know you don't want to write a 2000 line batch file, but it is so repetitive, just use your editor's dupe line function (I like QEdit) and then number the dirs correctly. Hal has promised that the registered version of MERGE will do the same by just reading a list of your DIR names from a text file, so you'll just need one line for each! Please Register! NOW FOR THE BIG NEWS! Want to automagically take new files nabbed from other boards, the internet, the Planet Connect and just shovel them into a work directory and then have them 'uploaded' to your BBS daily as seemingly random uploads? Gaaaaa! Just get ADDTODAY and CHK4DES from HAL SoftWare! (two other goodies I asked Hal to write) CHK4DES takes a DIR created by one of the DIZ extractors (I like WGM_Make) and removes all the 'Description not found' listings. Then it moves the files into a downloadable directory. ADDTODAY then appends a few of those descriptions to your UPLOADS dir - making it look like you have some awesome file activity that day. ADDTODAY is fairly random. A description is added if its filedate 'day of the month' (the number 1 thru 31) matches the system day. Anything dated the 18th, regardless of month, will be 'uploaded' on the 18th, and the month and year in the description will be changed to the current month and year. If you'd like more information, Contact Hal at any of the numbers listed in MERGE Help's 'about' screen, or you can send me EMAIL: charlies@twister.c-lib.siu.edu RBBSNet: 8:970/201 FIDONet: 1/11/157 USERNAME: CHARLES STRUSZ FIDO NODELIST CORRECTION: Phone should be 618.529.0000