In one of my content type, we are storing names in the Title field. For example, title is "John Smith". Due to the recent requirement change we now need to sort results by last name.
But since the name is stored in Title how can I sort by last name in the view? Is there a way I can create a field which automatically gets the last word in the title? Or may be some other way that I am missing out?
hook_node_presave
or some similar hook. There you split up the title and store the last word in the new last name field. You could also use Computed Field for doing this. Then resave all existing nodes to have the logic kick in.