PowerTip: Convert to Upper Case with PowerShell

Summary: Learn how to use Windows PowerShell to easily capitalize a string.

Hey, Scripting Guy! Question How can I use Window PowerShell to make all the text upper case so it is all in the
          same form prior to writing to a database?

Hey, Scripting Guy! Answer Use the ToUpper method from the String class:


Comments (5)

  1. Some of these tips appear simple but they come in handy when you need them. Thanks Ed

  2. @Jon

    I had to do some data cleanup in the past few months for a client and was using "tolower()" on a regular basis to see if names matched up. Some were all UPPER, some were MiXeD and some were lower.

    I love the fact that this sits in the Console and I can just test with it live too 🙂


  3. Anonymous says:

    The ToUpper() and ToLower() methods on Strings are great for ensuring consistency. I have also found that converting to Proper Case can be useful.


Skip to main content