When using the title method, can it only be used on a string or can it run through an entire field and update Names to proper case in a table?


I have tried the following and it did not work;

  • The only difference between this question and the duplicate seems to be that it uses title rather than upper method. – PolyGeo Mar 28 '17 at 22:43

It can be used on table field/values that are data type string/text. Use either Field Calculator, Calculate Field, or arcpy da update cursor.

eg. Field Calculator and Calculate Field:


eg. arcpy da update cursor:

with arcpy.da.UpdateCursor(fc, 'myFieldName') as cursor:
  for row in cursor:
    if row[0]:  # check for value
      row[0] = row[0].title()
| improve this answer | |
  • When testing this script I get the following error row[0] = row[0].title() AttributeError: 'NoneType' object has no attribute 'title' – Purplepeopleeater Mar 28 '17 at 21:14
  • @winscott68, I'm guessing it is because it is trying to perform the .title() method on a NULL value which is not a string. I've updated my answer to check for this. – artwork21 Mar 29 '17 at 12:27

Not the answer you're looking for? Browse other questions tagged or ask your own question.