[postgis-tickets] [PostGIS] #5299: The address_standardizer_data_us missing lexers

PostGIS trac at osgeo.org
Thu Dec 8 14:41:53 PST 2022


#5299: The address_standardizer_data_us missing lexers
------------------------------------------+---------------------------
 Reporter:  robe                          |      Owner:  robe
     Type:  defect                        |     Status:  new
 Priority:  medium                        |  Milestone:  PostGIS 3.3.3
Component:  pagc_address_parser           |    Version:  3.3.x
 Keywords:  address_standardizer_data_us  |
------------------------------------------+---------------------------
 The address_standardizer_data_us is missing some lexer entries that
 prevents it from parsing correctly addresses such as:


 {{{
 SELECT * FROM
 standardize_address('us_lex',  'us_gaz', 'us_rules',
 '1 Timepiece POINT',
 'Boston, MA, 02220');
 }}}

 it should be treating POINT as a suffix, but instead it returns


 {{{
  building | house_num | predir | qual | pretype |      name       |
 suftype | sufdir | ruralroute | extra |  city   |     state     | country
 | postcode | box | unit
 ----------+-----------+--------+------+---------+-----------------+---------+--------+------------+-------+---------+---------------+---------+----------+-----+------
           | 1         |        |      |         | TIMEPIECE POINT |
 |        |            |       | BOSTON | MASSACHUSETTS |         | 02220
 |     |
 (1 row)
 }}}

 instead of:

 {{{
 building | house_num | predir | qual | pretype |   name    | suftype |
 sufdir | ruralroute | extra |  city  |     state     | country | postcode
 | box | unit
 ----------+-----------+--------+------+---------+-----------+---------+--------+------------+-------+--------+---------------+---------+----------+-----+------
           | 1         |        |      |         | TIMEPIECE | POINT   |
 |            |       | BOSTON | MASSACHUSETTS |         | 02220    |     |
 (1 row)
 }}}


 Similarly has issue with PIECE as a street name


 {{{
 SELECT * FROM
 standardize_address('us_lex',  'us_gaz', 'us_rules',
 '50 Gold Piece Drive',
 'Boston, MA, 02020') as std1;

 }}}
 resolves to nothing:

 {{{
  building | house_num | predir | qual | pretype | name | suftype | sufdir
 | ruralroute | extra | city | state | country | postcode | box | unit
 ----------+-----------+--------+------+---------+------+---------+--------+------------+-------+------+-------+---------+----------+-----+------
           |           |        |      |         |      |         |
 |            |       |      |       |         |          |     |
 (1 row)
 }}}

 When it should give:


 {{{
 building | house_num | predir | qual | pretype |    name    | suftype |
 sufdir | ruralroute | extra |  city  |     state     | country | postcode
 | box | unit
 ----------+-----------+--------+------+---------+------------+---------+--------+------------+-------+--------+---------------+---------+----------+-----+------
           | 50        |        |      |         | GOLD PIECE | DRIVE   |
 |            |       | BOSTON | MASSACHUSETTS |         | 02020    |     |
 (1 row)
 }}}



 I'm still getting a list of these issues and will add them to this ticket.
-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/5299>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list