You are viewing limited content. For full access, please sign in.

Question

Question

Pattern Matching Issue

asked on October 30, 2015

Hello everyone,

I'm trying to create a pattern matching rule that will capture a suite number from an address.

Example 1: 100 W Balboa Ave, Suite 1/2  pattern   ,.(.+)>

Example 2: 100 W Balboa Ave. #1/2

 

 

Since i'm u sing Zone OCR in quickfields to capture the address on some documents instead of giving me a comma it gives me period which them makes my pattern matching not work. How do i make pattern matching that look for either a comma or period and break up the address.

 

 

 

0 0

Answer

SELECTED ANSWER
replied on November 2, 2015

Hi Ivan,

In your pattern above, you are capturing only the "(.,)"

Also, by using "\w*" at the end, you aren't accounting for a "#" or "/", as in your Example 1 and Example 2.

Try out [.,]\s?(.+)

This will ignore the [.,] and a possible whitespace after it, giving you only "Suite10".

Let me know if this works for you!

1 0

Replies

replied on October 30, 2015

[.,] would match any character in the specified range. As far as breaking it up goes, you want to use the pattern matching process, not in-line pattern matching for more control.

0 0
replied on October 30, 2015

Hi, Miruna

I got a pattern to give me a result [(.,)].\w*  

I'm missing the part to get rid of the period or the comma for the result and format field to edge?

250 Civic Center. Suite10  

  . Suite10

 

250 Civic Center, Suite10

, Suite10

0 0
SELECTED ANSWER
replied on November 2, 2015

Hi Ivan,

In your pattern above, you are capturing only the "(.,)"

Also, by using "\w*" at the end, you aren't accounting for a "#" or "/", as in your Example 1 and Example 2.

Try out [.,]\s?(.+)

This will ignore the [.,] and a possible whitespace after it, giving you only "Suite10".

Let me know if this works for you!

1 0
replied on November 3, 2015

Hi, Alexander

 

Looks like that pattern did exactly what I needed.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.