COMP
Compares selected items, in the same or different files, to determine the exact number and types of mismatches.
Command Class
TCL-II command.
Syntax
COMP file-specifier1 item-list1
{(options}
WITH: {(file-specifier2} {item-list2}
Syntax Elements
file-specifier1 Specifies a file containing the items to be compared.
item-list1 Specifies the items in file-specifier1 to be compared. This can be one or more item-ids separated by spaces, a list generated by a list-generating command such as SELECT, or an asterisk (*) to specify all items.
file-specifier2 Specifies a different file containing the items to be compared with the items in file-specifier1.
file-specifier2 need not be entered if the items to be compared are in file-specifier1.
item-list2 Specifies the Items in file-specifier2 to be compared with items in file-specifier1. This can be one or more item-ids separated by spaces or an asterisk (*) to specify all items.
item-list2 need not be specified if it is identical to item-list1.
Options
n Integer. Overrides the default parameter of 20 lines to search forward when trying to realign items after a misalignment has been detected. This is useful when large blocks have been inserted into or deleted from the items being compared.
A Prints all lines within the compared items. Also prints all inserted, deleted, and mismatched lines.
B Forces a page break between items.
C Suppresses comparison of DataBasic source code comment lines.
E Suppresses comparison of end of line comments in REAL assembly language source code items. (Must be used with the M option.)
I Selects item-ids for display.
M Compares items in REAL assembly language macro option format.
N Specifies the NOPAGE feature for screen listings.
P Sends all output to the printer assigned to your port.
S Suppresses the listing of item-ids of matching items.
W Formats terminal listings so that lines exceeding the specified number of display columns for a particular monitor wrap rather than truncate.
The default truncates the line at the field boundary.
Report
All lines that do not compare are displayed on the report under one of three categories, identified by a single letter:
D Deleted from the original item.
I Inserted into the second item in the comparison.
C Changed between the two items.
The COMP command automatically realigns items within the item-list.
Example
This example use files BP and BP1 listed below.
:COMP BP * WITH: (BP1 PAGE 1 COMPARISON 12:53:35 23 FEB 1999 BP TEST1 BP1 TEST1 C 1 HHH C 1 AAA C 2 GGG C 2 BBB C 3 FFF C 3 CCC C 4 EEE C 4 DDD BP TEST2 BP1 TEST2 C 1 BBB C 1 GGG C 2 CCC C 2 FFF I 3 EEE D 4 EEE BP TEST3 BP1 TEST3 I 1 FFF I 2 EEE I 3 DDD D 2 DDD D 3 EEE D 4 FFF BP TEST4 BP1 TEST4 I 1 EEE C 2 EEE C 3 CCC C 3 FFF C 4 BBB D 4 GGG BP TEST5 BP1 TEST5 C 1 EEE C 1 DDD C 2 FFF C 2 CCC C 3 GGG C 3 BBB C 4 HHH C 4 AAA BP TEST6 BP1 TEST6 BP BP1 TEST1 TEST1 001 HHH 001 AAA 002 GGG 002 BBB 003 FFF 003 CCC 004 EEE 004 DDD TEST2 TEST2 001 BBB 001 GGG 002 CCC 002 FFF 003 DDD 003 EEE 004 EEE 004 DDD TEST3 TEST3 001 CCC 001 FFF 002 DDD 002 EEE 003 EEE 003 DDD 004 FFF 004 CCC TEST4 TEST4 001 DDD 001 EEE 002 EEE 002 DDD 003 FFF 003 CCC 004 GGG 004 BBB TEST5 TEST5 001 EEE 001 DDD 002 FFF 002 CCC 003 GGG 003 BBB 004 HHH 004 AAA TEST6 TEST6 001 AAA 001 AAA 002 BBB 002 BBB 003 CCC 003 CCC 004 DDD 004 DDD