Best Practices for Working with Column Names in SharePoint
When creating a column in MOSS 2007, SharePoint stores the name you entered as a display name AND an internal name. The internal name is created by escaping out special character like this:
Display Name: My Column Name
Internal Name: My_%20_Column_%20_Name
Even worse, when you edit the column name and change it to something totally different, the internal name doesn't change:
Display Name: New Name
Internal Name: My_%20_Column_%20_Name
Now, at first you might think "who cares what the internal name is". When you are working with DataViews, some third party controls, and custom Webparts - you must use the internal name. The potential for confusion is enormous.
Best Practice
When creating new columns, name them without any specail characters or spaces. After the column is created, rename it with the special characters or spaces. This way the internal name is "clean":
Display Name: My Column Name
Internal Name: MyColumnName
When renaming a column, create a new column (using the best practice above), copy the data to the new column, and then delete the old column. This will eliminate any confusion down the road.
-Joe