0

I'm trying to parse a column of ~175,000 street names. Some of them are just one word (Jamaicaway), and some are multiple words (St. Edwards Pl). I want just the street body (Jamaicaway and St. Edwards, respectively).

I found the address_standardizer package and installed it, but when I run the example below I get the error relation "us_lex" does not exist.

    SELECT house_num, name, suftype, city, country, state, unit
    FROM standardize_address('us_lex', 'us_gaz', 'us_rules', 'One 
        Devonshire Place, PH 301, Boston, MA 02109');

I'd expect to get back just "Devonshire," but I'm getting the error instead. There doesn't seem to be much about this on the package page. Any insight?

Chris Stephens
  • 201
  • 2
  • 7
  • have you also installed the data extension? `CREATE EXTENSION address_standardizer_data_us;` – JGH Aug 02 '19 at 13:49

1 Answers1

0

You will also have to run:

CREATE EXTENSION address_standardizer_data_us;

Which creates the us_lex and other data tables

SimonP
  • 1
  • Please reserve the Answer field for a complete solution that is also useful for other users of the site. If you have additions, or suggestions, post them as a comment instead. – Ronald Jul 24 '20 at 17:31
  • Sorry, if I don’t understand, but isn’t what I posted above a complete solution to the user’s problem? – SimonP Jul 25 '20 at 18:13