Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Need to find an algorithm
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00744852
Message ID:
00744855
Views:
17
Nadya
FWIW, SOUNDEX returns the same value for both options you mentioned...You could also use it in your logic i think, as a way to eliminate some misspells.

Jaime

>Hi everybody,
>
>I'm trying to find a solution for the following problem: Each year (or within other reasonable period) we receive data from Assessor. We then have to process these data and put into main database. One of the processes, we're doing, is street standardization. We usually receive unparsed address from Assessor and a special application then called and performs parsing and standardizing of addresses. (My application, BTW). So far, so good. Now, obviously property address is unlikely to change, so if we done some work with addresses in the previous year, there is no need to repeat this work next year unless it's a new property or something was wrong in the database...
>
>So, another application comes to play, called ADC (my manager calls it "Save the whales" :)). This application determines, which records we don't have to process, since they were already processed in the previous year.
>
>We found cases, there address, received from assessor didn't correspond to address, we have in our database. There could be lots of weird reasons for that, but these cases should be processed.
>
>So, here is the logic, I put in the method:
>
>select SiteMstr
>		** Fixed a bug 08/21/02
>		if SiteMstr.Prefcode<>"P" && What if we are on Alternative address
>		    locate for PropID = BldMstr.PropID and Prefcode = "P" && Each record has a primary address - make sure
>		endif	
>			
>		scatter memvar
>		&& Updated:NN: 10/03/02 - added new logic
>		do case
>		   case proper(left(m.Street,3))='Zzz' 		
>    		  ** This case should be parsed - Bad Address in the Live database
>    		
>    	   case empty(m.StNum) and left(m.lcCompP1,1) $ "123456789"
>    	      ** There is a chance to improve Street Number
>    	
>		   && Updated:NN: 10/16/02
>		   case not isdigit(m.Street) and not upper(left(m.Street,at(" ",m.Street)-1)) $ m.lcCompP1
>		        ** Streets don't match
>		
>		   case m.StNum>0 and not alltrim(str(m.StNum)) $ m.lcCompP1
>		   * StNum is incorrect	- logic fixed && Updated:NN: 10/16/02
>
>SiteMstr is a Live address and lcCompP1 is the incoming data.
>
>Note the case number 3. Basically, I check, if the part of Street is in the unparsed street and if it is not, I mark this record as needed to review.
>--------------------------------------
>Here is a situation:
>In file from Assessor we have Lily Pond Rd in unparsed street. In the Live database we have Lilly Pond Rd (note 2 ll in the middle). Live database has correct spelling, because addresses were checked against Postal office database. However, my program marks these records as needed to process (see case 3).
>
>So, I have to somehow make into account difference in the spelling...
>
>Hopefully I explained the problem well.
>
>Do you have suggestions?
>
>Thanks a lot in advance.
Why do programs stop working correctly as soon as you leave the Fox?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform