# Example: finding missing items in a pair of spreadsheets

### How to check spreadsheets for missing data

You can check for missing lines and missing fields in Beyond Compare. The sample data for this example can be downloaded here.

{% file src="https://1446155253-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LXUX-uoaZJ8T4qyEc-x%2F-LbddRQXx5bNlyesfQ3O%2F-LbddX872BFo422_gvrT%2Femployee-license-status-missing.zip?alt=media&token=e26f872c-4c16-4edb-9abf-db61995f0e64" %}

### In this example we will show

* how to set the key column&#x20;
* how to make column 2 in Table 1 align with column 4 in Table 2.&#x20;
* how to ignore columns
* how to summarize the differences in a report&#x20;
* spreadsheets are read-only in Beyond Compare (ou can neither edit nor save changes)

### How to set the key column

1\) Open two spreadsheets in Beyond Compare.  This looks terrible.  Nothing is lined up. This is useless right now:&#x20;

![](https://1446155253-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LXUX-uoaZJ8T4qyEc-x%2F-LbdcZphLSEuAn2ObOGJ%2F-Lbdcno60_JCN2ssF925%2Fimage.png?alt=media\&token=556e8ae4-8098-44b2-a9a9-0190c7ddc16c)

2\) By clicking `Rules->Columns->rightclick`:Edit (or rightclicking the column tops in main view), select an appropriate column to be the key. For our example here, ID is an appropriate key. A key should be a column that exists in both spreadsheets and is unique within its spreadsheet. Make other columns not the key, with rightclicking and unselecting Key.&#x20;

3\) To help the columns line up: `Rules->Columns->[arrow keys]`&#x20;

![](https://1446155253-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LXUX-uoaZJ8T4qyEc-x%2F-LbdcZphLSEuAn2ObOGJ%2F-LbdccOj_XbIeIZ3t_k0%2Fimage.png?alt=media\&token=bdd24921-8d8e-42d7-bbbf-4ea60dc1db43)

4\) Hide or remove columns you are not interested in (by doing more clicking). Don't worry, you are operating on temporary files. Your original spreadsheet is treated as read-only. At this point I would expect a lot of the lines to match up. Why are they pink?? They are pink because I hid the unwanted columns, when what I should have done is delete the unwanted columns.&#x20;

![](https://1446155253-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LXUX-uoaZJ8T4qyEc-x%2F-LbdbcYKTi1lTaIGcDbp%2F-LbdbqVX_8-EKinKiDBZ%2Fimage.png?alt=media\&token=e0d9df02-5a63-4e58-a3fa-99087c5dcf9d)

![](https://1446155253-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LXUX-uoaZJ8T4qyEc-x%2F-LbdbcYKTi1lTaIGcDbp%2F-LbdbfHT3cMPdlO0nVCe%2Fimage.png?alt=media\&token=ae688132-528d-422e-8b3d-2f5e80d458f6)

5\) Rightclick in the main view to unhide columns. Now remove them: `Rules->Columns->[remove]` Now the view looks much better.&#x20;

![](https://1446155253-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LXUX-uoaZJ8T4qyEc-x%2F-LbdbcYKTi1lTaIGcDbp%2F-LbdblMhhRX8z4I-etdS%2Fimage.png?alt=media\&token=bd804314-c72c-4a28-8034-36feab70bf8b)

The only colored rows are red letters on blue highlight (orphan rows that are entirely missing from one file) and pink highlight (missing field info).&#x20;

6\) The last thing you might want to do is export a list of the differences. Exporting can be done in Text (black and white, old school) or HTML (colored and formatted to look like your GUI). `Session->TableCompareReport`.
