Opened 7 years ago

Last modified 6 years ago

#3791 new defect

PostGIS tiger geocoder should use cousub in addition to place for non-specific

Reported by: robe Owned by: robe
Priority: medium Milestone: PostGIS Fund Me
Component: tiger geocoder Version: 2.3.x
Keywords: Cc:

Description (last modified by robe)

Seems if you do:

  SELECT pprint_addy(addy), ST_AsText(geomout), rating FROM geocode('Brooklyn, NY',1);

you get no answer back although Brooklyn is listed in tiger_data.ny_cousub.

However if you use a value that is in ny_place such as

  SELECT pprint_addy(addy), ST_AsText(geomout), rating FROM geocode('Bronxvilled, NY',1);

it works.

tiger should try to use tiger.cousub as well as tiger.place.

I think cousub might currently only be used for some joins.

this ticket was instigated by this stack exchange post:

https://gis.stackexchange.com/questions/247928/postgis-not-geocoding-counties

Change History (6)

comment:1 by robe, 7 years ago

Description: modified (diff)

comment:2 by dbaston, 7 years ago

Need to be careful about the priorities of the two data sets. (Maybe Place can always supersede MCD?) For example, NY State has a Rochester (Place) and Rochester (MCD) that are a couple hundred miles apart. A user entering "Rochester, NY" would be pretty surprised to end up with the MCD of that name.

comment:3 by robe, 7 years ago

yah I was going to have place always supercede cousub check.

Though I wonder if I had thought about doing this before and decided against it.

comment:4 by woodbri, 7 years ago

One problem with cousub is that names in some regions are like "1", "2", etc or other equally useless names.

In my geocoder, for a given TLID, I duplicate the record for each street name and for each potential place name (which includes cousub) and each zipcode combination.

This makes it much easier to find addresses when there are multiple aliases, and my actual query is pretty simple.

comment:5 by robe, 7 years ago

Milestone: PostGIS 2.4.0PostGIS 2.5.0

comment:6 by komzpa, 6 years ago

Milestone: PostGIS 2.5.0PostGIS Fund Me
Note: See TracTickets for help on using tickets.