Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id F3CB8B5DC13 for ; Thu, 26 May 2011 18:08:22 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 76990-07 for ; Thu, 26 May 2011 21:08:15 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from zebedee.cranntara.net (zebedee.cranntara.net [91.186.7.79]) by mail.postgresql.org (Postfix) with ESMTP id 903D5B5DC1B for ; Thu, 26 May 2011 18:08:15 -0300 (ADT) Received: from [88.210.188.180] (helo=bolek.coachhouse) by zebedee.cranntara.net with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.72) (envelope-from ) id 1QPhmu-0000nY-4T for pgsql-sql@postgresql.org; Thu, 26 May 2011 22:08:14 +0100 Received: from dick.coachhouse ([192.168.1.32] ident=tarlika) by bolek.coachhouse with esmtp (Exim 4.69) (envelope-from ) id 1QPhLo-0000B2-4M for pgsql-sql@postgresql.org; Thu, 26 May 2011 21:40:12 +0100 Date: Thu, 26 May 2011 21:40:12 +0100 From: Tarlika Elisabeth Schmitz To: pgsql-sql@postgresql.org Subject: Re: extracting location info from string Message-ID: <20110526214012.24213f0c@dick.coachhouse> In-Reply-To: References: <20110522210526.0f8b66fa@dick.coachhouse> <20110522230041.28d1bc35@dick.coachhouse> <4DD9BB87.7070000@postnewspapers.com.au> <20110523163341.56edb1aa@dick.coachhouse> <4DDD1F7C.5040008@gmail.com> <20110525221342.14e34046@dick.coachhouse> X-Mailer: Claws Mail 3.5.0 (GTK+ 2.20.1; i486-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201105/166 X-Sequence-Number: 35450 On Thu, 26 May 2011 10:15:50 +1200 Andrej wrote: >On 26 May 2011 09:13, Tarlika Elisabeth Schmitz > wrote: >> On Wed, 25 May 2011 09:25:48 -0600 >> Rob Sargent wrote: >> >>> >>> >>>On 05/24/2011 10:57 AM, Lew wrote: >>>> Tarlika Elisabeth Schmitz wrote: >>>> >>>>> CREATE TABLE person >>>>> ( >>>>> id integer NOT NULL, >>>>> "name" character varying(256) NOT NULL, >>>>> "location" character varying(256), >>>>> CONSTRAINT person_pkey PRIMARY KEY (id) >>>>> ); >>>>> >>>>> this was just a TEMPORARY table I created for quick analysis >>>>> of my CSV data (now renamed to temp_person). >> >> CREATE TABLE country >> ( >> =C2=A0id character varying(3) NOT NULL, -- alpha-3 code >> =C2=A0"name" character varying(50) NOT NULL, >> =C2=A0CONSTRAINT country_pkey PRIMARY KEY (id) >> ); >> >> >>>To minimize the ultimately quite necessary human adjudication, one >>>might make good use of what is often termed "crowd sourcing": =C2=A0Keep >>>all the distinct "hand entered" values and a map to the final human >>>assessment. >>[...] >> I could do with a concept for this problem, which applies to a lot of >> string-type info. > >I'd start w/ downloading a list as mentioned here: >http://answers.google.com/answers/threadview?id=3D596822 > >And run it through a wee perl script using >http://search.cpan.org/~maurice/Text-DoubleMetaphone-0.07/DoubleMetaphone.= pm >to make phonetic matches ... > >Then I'd run your own data through DoubleMetaphone, and clean up >matches if not too many false positives show up. Many thanks for all your suggestions. It will take me a while to work my way through these as I have several open ends. In a similar vein, the PERSONs names are 1) 2) (more common) 3) <initials>|<firstname> <surname> Where I have firstname and or title I'd be quite keen to determine sex as it would be interesting from a statistics point of view to distinguish. I am basically just interested in people from two countries, names mainly English. --=20 Best Regards, Tarlika Elisabeth Schmitz