2022-02-071077 total records, but ordered differently. Gotta unpack this...
ISTR shapefile record numbering starts at 1.
But my "DBFquery" tool starts at 0 (oops), so using that nomenclature here.
Record number vs OBJECTID gets out of sync by 1.OBJECTID 918 is missing from new file.
With match offset by 1 in that part of the file (see table below), that corresponds to OBJECTID 919 in the old file.
Because my array numbering starts @ 0, we're back to record "918", the missing apocryphal "SS 345". BAM!
Before this point in each file is "Proposed designation of SL195 along a new location from US 83 at Loma Blanca Rd to FM 755".
Do earlier revisions differ similarly? Check using script.2021-04-28 <-> 2021-08-13: OBJECTID 1058 & 1068 have missing MO_NBR, APRV_DT, APRV_YR & STATE fields filled.
2020-08-19 <-> 2021-04-28 has diffs.2020-04-28 <-> 2020-08-19: FID field renamed OBJECTID.
2019-03-26 <-> 2020-04-28: Data formatting changed too much to be easily diffable, but data looks substantially the same.
old=/home/yakra/gis/data/tx/TxDOT_Highway_Designations-2021-08-13/Highway_Designations.dbf
new=/home/yakra/gis/data/tx/TxDOT_Highway_Designations-2022-02-07/Highway_Designations.dbf
for r in {0..1076}; do
echo '#'$r;
diff <(./DBFquery $old $r | grep -v "^$old opened\.$") \
<(./DBFquery $new $r | grep -v "^$new opened\.$");
echo;
done > 20220207a.diff
^ Find exact matches
old=/home/yakra/gis/data/tx/TxDOT_Highway_Designations-2021-08-13/Highway_Designations.dbf
new=/home/yakra/gis/data/tx/TxDOT_Highway_Designations-2022-02-07/Highway_Designations.dbf
for r in {457..1076}; do
echo '#'$r;
diff <(./DBFquery $old $(expr $r + 1) | egrep -v "^$old opened\.$|OBJECTID") \
<(./DBFquery $new $r | egrep -v "^$new opened\.$|OBJECTID");
echo;
done > 20220207b.diff
^ Find offset matches. Adjust r, expr, and diff filename as needed.
old | new | route | wot0 | 0 | | identical
... | ... | | identical
456 | 456 | | identical
457 | 1034 | SL0368 | Transferred to City of San Antonio -> Remains on State Highway System458 | 457 | | match offset by 1
... | ... | | match offset by 1
917 | 916 | | match offset by 1
918 | | SL0345 | DSPN_DSCR appears swapped w/919. That's the removal of SL 345; redesignation as SS 345 appears erroneous, so record removed.
919 | 1035 | SS0345 | Redesignate as SS 345 -> Remove Portion of SL 345920 | 917 | | match offset by 3
... | ... | | match offset by 3
947 | 944 | | match offset by 3
948 | 1036 | US0090 | NULL -> Designate US 90 Concurrent with IH 10949 | 945 | | match offset by 4
... | ... | | match offset by 4
1037 | 1033 | | match offset by 4
457 | 1034 | SL0368 | Transferred to City of San Antonio -> Remains on State Highway System
919 | 1035 | SL0345 | Redesignate as SS 345 -> Remove Portion of SL 345
948 | 1036 | US0090 | NULL -> Designate US 90 Concurrent with IH 101038 | 1037 | | match offset by 1
... | ... | | match offset by 1
1059 | 1058 | | match offset by 1
1060 | 1059 | | match with missing MO_NBR, APRV_DT & APRV_YR fields filled in
1061 | 1060 | | match with missing MO_NBR, APRV_DT & APRV_YR fields filled in
1062 | 1061 | | match with missing MO_NBR, APRV_DT & APRV_YR fields filled in
1063 | 1062 | | match with missing MO_NBR, APRV_DT & APRV_YR fields filled in1064 | 1063 | | match offset by 1
... | ... | | match offset by 1
1067 | 1066 | | match offset by 1
1068 | 1067 | BU0059-C | Fix for "WTF" above. This allows new BU 59C @ Marshall, and leaves more letters available for future routes northward toward Texarkana. Nothing to change for TM purposes.1069 | 1068 | | match offset by 1
... | ... | | match offset by 1
1076 | 1075 | | match offset by 1
| 1076 | FM1516 | Designate FM 1516 on New Location