Calculated fields is in my opinion, one of the least used or even understood features of SharePoint. It could be because it’s not easy finding examples or information on how to build calculated fields in SharePoint. A good starting point for anyone wanting to get comfortable using calculated fields is available directly from the Office Online web site located here or the WSS 2.0 Help located here. Disregard the fact that it’s a WSS 2.0 resource, the calculated fields haven’t changed all that much and I find that most of these forumulas work in WSS 3.0 instances as well.
The formula below will start from the left of the First Name column and grab the first letter.
The formula below will calculate the difference in days between two dates. This can be particularly useful if you want to calculate how long something took to complete.
=DATEDIF([Start Date], [End Date],”d”)
Please note that if your column name has any spaces between it, you will have to use square brackets as indicated in my examples above. If there is no space, you can simply replace Column1 that you’ll find in most examples, with the name of your column.
I encourage everyone to take a few minutes and experiment with these fields to get a good handle on what’s possible. If you’re working on building a calculated field that you’re having trouble with, please drop me a note and I’ll see if I can help.