ae5au / gmrs.app-website

Lookup for amateur and GMRS radio licensees with cross-referencing between holders of both licenses
https://gmrs.app/
Apache License 2.0
11 stars 5 forks source link

Return "possible" matches #2

Closed ae5au closed 2 years ago

ae5au commented 2 years ago

Catch scenarios the same individual has multiple FRNs and also multiple amateurs at same addresses as a single GMRS license.

Records with exact match of street, city, and state:

sqlite> select count(*) from licenses AS gmrs INNER JOIN licenses AS amateur ON gmrs.service = 'ZA' AND amateur.service IN ('HA','HV') AND gmrs.frn != amateur.frn AND gmrs.street = amateur.street AND gmrs.city = amateur.city AND gmrs.state = amateur.state AND gmrs.street != '';
2695

Might have to pre-process these matches to make query more efficient.