Closed (won't fix)
Project:
Views (for Drupal 7)
Version:
6.x-2.6
Component:
node data
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
28 Oct 2009 at 22:03 UTC
Updated:
11 Oct 2011 at 17:07 UTC
Comments
Comment #1
merlinofchaos commentedSorry, Views only sorts on the data you have. Your best bet might be to use something like CCK computed field to calculate what the last name is and create a hidden field for sorting. But Views can't do this without placing the data in the database.
Comment #2
jack_ruby commentedThanks for in the advice,
What I'm wondering: is there not a way to tell views to sort the Name field (firstname lastname) so that it sorts by everything after the "space" character ?
I'll check into using CCK to do that, too.
Thanks
JR
Comment #3
merlinofchaos commentedSorry, SQL can't do that, and Views just creates SQL queries, ultimately.
Comment #4
jack_ruby commentedThanks, I found this node
http://drupal.org/node/559618
which seems helpful
JR
Comment #5
ilw commentedHello,
Could you lease share with me, Did you find a solution for that?
Comment #6
jack_ruby commentedI was able to solve the problem only by separating the "name" field into "first name" and "last name". It can be tedious, but it's the only way I can see to do it. If you have the sql skills, you can just write a query to break the field up into two new fields. then just build the view with the two new fields. Hope that helps!
JR