Jump to content
Sign in to follow this  
efcharvet

Global replace null values in « Country » field

Recommended Posts

I have a friend who uses TMG that has entered a « Country » throughout his TMG project for every place in his database outside of his home country, but not when places were within his home country. In these cases, he left the « Country » field blank. Now, he wants to fill these null value fields with his home country's name. (For this discussion, let's say he wants to put in « USA » in every « Country » field that is blank.)

 

Going into the Master Place List and replacing all of the blank fields with « USA » is a possibility, however it appears he has more than 1,500 home country locations that need the correction, so doing this manually would be tedious and time consuming.

 

Of course, using the « Replace » function in the Master Place List would be ideal, however, the search and replace operation does not work if one of the variables is a null value, e.g. the « search » field is blank and the « replace » field has « USA ».

 

What would be the fastest way to accomplish this task?

 

Thank you for your reply.

 

Earl

Share this post


Link to post
Share on other sites

John Cardinal's TMG utility will do the whole job in under a minute. Load the database, select "Places/Change Place parts," set the rules to If country equal [leave field blank], then add the filter. Under actions do "change country set to USA." Add the action and hit OK. Make sure that the first run has "log only" checked. Then press "Change Place Parts" and inspect the log. If all is well then uncheck the log only box and press change place parts again. Presto!

 

Hope this helps . . .

 

 

Robert

Edited by Robert Jacobs

Share this post


Link to post
Share on other sites

Thanks Robert, I don't know why the obvious solution didn't occur to me immediately!

 

What would TMG be without John Cardinal's TMG utility!?

 

Regards,

Earl

Edited by efcharvet

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×