stereoptic wrote: 
> I need to brush up on my SQL.
> What would be an example of listing the albumname, the sort album name ,
> album artist and sort album artist from the albums (?) table? 
> I would be using the database query function in LMS, I don't have any
> other SQL loaded on this PC right now.
> 
> Thanks!
I think something kinda like this should get you started:

Code:
--------------------
    SELECT TRIM(CAST(al.title AS CHAR(150))) AS "Album Name",
  al.titlesort AS "Sort Album Name",
  TRIM(CAST(co.name AS CHAR(150))) AS "Album Artist",
  co.namesort AS "Sort Album Artist"
  FROM albums al,
  contributor_album ca,
  contributors co
  WHERE ca.album = al.id
  AND co.id = ca.contributor
  ORDER BY 1, 3
--------------------


------------------------------------------------------------------------
Dogberry2's Profile: http://forums.slimdevices.com/member.php?userid=18883
View this thread: http://forums.slimdevices.com/showthread.php?t=101600

_______________________________________________
discuss mailing list
discuss@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/discuss

Reply via email to