Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help Converting UPPERCASE to Proper Case in Table??? 1

Status
Not open for further replies.

Nelz

Programmer
Sep 27, 2001
50
US
I read a couple of posts about this but I still can't figure out how to do it. I'm a bit of a novice but I follow instructions very well!!! X-)

I have a contacts table with firstname lastname address and city and all 73,000 records are upper case. I want to permanently change them all to Proper Case, and I need to know the procedure.

I realize there is some VB code that does this but I dont know how or where to apply it to the table. (Like do I need to create a button somewhere???)It's really just a one shot thing, since once its converted thats it...unless at some future time I upload a lot of new data thats the same way. HELP PLEASE???
 
The four fields you wish to convert to "proper case", in which the first letter of each word is capitalized and the other letters are lower case, are easily converted using the "StrConv" function. Simply build a query using the following SQL:

UPDATE tblContact SET FirstName = StrConv(FirstName,3), LastName = StrConv(LastName,3), Address = StrConv(Address,3), City = StrConv(City,3);

Recall that you mentioned that all of your data is already in UPPERCASE. If you have any doubts about the current status of the data, you might want to include a UCase function around each fieldname prior to executing the StrConv function.

 
It worked beautifully! Thank you SO MUCH. Now I'll have to figure out a way to prevent them from entering it any other way as they add new contacts. I think theres a setting for that within the input form?

That was extremely helpful though, I havent found an easier solution in my search within this site. I hope others will benefit from your answer as well.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top