I edited the authoryear.bbx for biblatex the following way:
\DeclareNameAlias{author}{sortname}
%\DeclareNameAlias{editor}{sortname} this I commented out
%\DeclareNameAlias{translator}{sortname} this I commented out
It works perfect for sorting the authors in "Lastname, Name and Name Lastname" etc. but now the books with no authors and only editors are still sorted in the "Name Lastname", but I want them to be formated in the same way as the authors. But only for books with no authors, not for incollection nor for inproceedings etc.
I try to do this, but obviously it doesn't work:
\DeclareNameAlias{author}{sortname}
\DeclareNameAlias{collection}{editor}{sortname}
%\DeclareNameAlias{translator}{sortname}
This is wanted and shall be kept:
Kahn, Douglas 2007: Between a Bach and a Bard Place: Productive Constraint in Early Computer Arts, in Oliver Grau (Ed.): MediaArtHistories, Cambridge, MA: MIT Press, S. 423–451.
But this not:
Carolyn Birdsall/Anthony Enns (Ed.) 2008: Sonic Mediations: Body Sound Technology, Newcastle upon Tyne: Cambridge Scholars Publishing.
This should be change into:
Birdsall, Carolyn/Anthony Enns (Ed.) 2008: Sonic Mediations: Body Sound Technology, Newcastle upon Tyne: Cambridge Scholars Publishing.
If I uncomment the \DeclareNameAlias{editor}{sortname}, this will happen:
Kahn, Douglas 2007: Between a Bach and a Bard Place: Productive Constraint in Early Computer Arts, in Grau, Oliver (Ed.): MediaArtHistories, Cambridge, MA: MIT Press, S. 423–451.
which is unwanted..
Here is the complete code for spread in three .bbx files.. sorry very chaotic.. I am a new into this. Thanks to all the authors of these codes. Since I don't know how to past correctly longer code scripts without manually indenting the code by 4 spaces.. I will link the two other files.
http://algorhythmics.com/latexstuff/sm-002.bbx http://algorhythmics.com/latexstuff/philosophy-standard.bbx
And here is the part of authoryear I changed:
\DeclareNameAlias{author}{sortname}
\DeclareNameAlias{editor}{sortname}
\DeclareNameAlias{default}{first-last}
\DeclareNameAlias{byeditor}{default}
%\DeclareNameAlias{translator}{sortname}
Please help me. Thanks!

authoryearwould printeditorusing thebyeditorformat, which is just an alias forfirst-last. So your problem is a result of other changes you've made to the style. – Audrey Apr 9 '12 at 19:46\DeclareNameAlias{byeditor}{default}and\DeclareNameAlias{default}{first-last}. Whatever bibliography macro you're using in place ofbyeditor+othersneeds to apply thefirst-lastformat. If you need help with this, edit your question to reflect all of the relevant style changes you've made. – Audrey Apr 9 '12 at 22:52