Adresse erfassen mittels RegEx
-
Hello all, I have a question regarding regex address capture. I have the following address: Harald Sturm Schönstrasse 18a 60311 Frankfurt am Main I want to split this string into 4 components with 4 different regex to do that. Name: Harald Sturm. (The whole first line) Street: Schönstrasse 18a (The whole second line) ZIP CODE: 60311 (First digital part of the sentence ) Location: Frankfurt am Main (Last part of the sentence) Question for the regex experts: What would each regex expression for this look like ? Many thanks in advance.
-
Hello all, I have a question regarding regex address capture. I have the following address: Harald Sturm Schönstrasse 18a 60311 Frankfurt am Main I want to split this string into 4 components with 4 different regex to do that. Name: Harald Sturm. (The whole first line) Street: Schönstrasse 18a (The whole second line) ZIP CODE: 60311 (First digital part of the sentence ) Location: Frankfurt am Main (Last part of the sentence) Question for the regex experts: What would each regex expression for this look like ? Many thanks in advance.
To be honest, unless your addresses are pretty rigidly controlled, you are probably on a loser even trying: Extract addressline, state, city, zipcode into different columns from one single column called “adress” with space as delimeter using posgresql[^] But ...
(?.+?)\r\n(?.+?)\r\n(?\d+?)\s+(?.+)
May do it ... I needed to play with regex options Mutiline = true, SingleLine = true and change "$" to "\r\n" to get it working in Expresso.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!
-
To be honest, unless your addresses are pretty rigidly controlled, you are probably on a loser even trying: Extract addressline, state, city, zipcode into different columns from one single column called “adress” with space as delimeter using posgresql[^] But ...
(?.+?)\r\n(?.+?)\r\n(?\d+?)\s+(?.+)
May do it ... I needed to play with regex options Mutiline = true, SingleLine = true and change "$" to "\r\n" to get it working in Expresso.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!
I don't have a label like name, street etc- I just always have three lines. The first line always records the full name. The second line records the street including the house number. The third line consists of a postal code and city. Thereby the postal code and the city should be extracted separately. I would need four single regex rules at last. Thanks a lot in advance
-
I don't have a label like name, street etc- I just always have three lines. The first line always records the full name. The second line records the street including the house number. The third line consists of a postal code and city. Thereby the postal code and the city should be extracted separately. I would need four single regex rules at last. Thanks a lot in advance
Did you try the regex I supplied? At all?
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!
-
Hello all, I have a question regarding regex address capture. I have the following address: Harald Sturm Schönstrasse 18a 60311 Frankfurt am Main I want to split this string into 4 components with 4 different regex to do that. Name: Harald Sturm. (The whole first line) Street: Schönstrasse 18a (The whole second line) ZIP CODE: 60311 (First digital part of the sentence ) Location: Frankfurt am Main (Last part of the sentence) Question for the regex experts: What would each regex expression for this look like ? Many thanks in advance.
-
A few lines of code including one call to
String.Split
would do that much quicker than a regex.You may right, but im using it for a rpa tool, that accept only a regex confirm formula for extracting operations.