Home of the Squeezebox™ & Transporter® network music players.
Page 1 of 3 123 LastLast
Results 1 to 10 of 25
  1. #1
    Senior Member davep's Avatar
    Join Date
    Apr 2005
    Location
    Singapore
    Posts
    630

    Accessing slimserversql.db contents

    I would really like to be able to generate up to date lists - excel, pdf, etc - of the albums I have in my slimserversql.db. There used to be a pearl script which did this but as AFAIK this was before the change to the sqlite backend.

    I have looked into the db using one or two sqlite front ends and can see that the info is there but not in readily accessible form (i.e. seperate lists of albums, tracks and contributors but not linked in an immediately usable way). I am not really interested in learning SQL syntax to construct a way of generating such a list so was wondering if anybody else had done such a thing. Goal would ideally be to have a complete list of albums, sorted by artist, on my PDA so that it could be checked during shopping binges.

    davep

  2. #2
    Senior Member max.spicer's Avatar
    Join Date
    Apr 2005
    Location
    York, United Kingdom
    Posts
    1,661
    This is really trivial to do in SQL.

    Max
    This is trivial to do in SQL. SQL is a really easy language to pick up the basics of so it would really be worth your while learning it. Do a search for SQL Tutorial in Google. In the meantime, here's something I've just hacked up in a couple of minutes:

    Code:
    select a.title, c.name
    from albums a, contributor_album ca, contributors c
    where a.id = ca.album
    and ca.contributor = c.id
    and a.compilation = 0
    union
    select a.title, 'Various Artists'
    from albums a
    where a.compilation = 1
    order by c.name
    Max
    Quote Originally Posted by davep
    I would really like to be able to generate up to date lists - excel, pdf, etc - of the albums I have in my slimserversql.db. There used to be a pearl script which did this but as AFAIK this was before the change to the sqlite backend.

    I have looked into the db using one or two sqlite front ends and can see that the info is there but not in readily accessible form (i.e. seperate lists of albums, tracks and contributors but not linked in an immediately usable way). I am not really interested in learning SQL syntax to construct a way of generating such a list so was wondering if anybody else had done such a thing. Goal would ideally be to have a complete list of albums, sorted by artist, on my PDA so that it could be checked during shopping binges.

    davep
    Some people think the title of this song is irrelevant,
    but it's not irrelevant - it's a hippopotamus.

  3. #3
    Senior Member davep's Avatar
    Join Date
    Apr 2005
    Location
    Singapore
    Posts
    630
    Max,
    many thanks for taking the trouble to address my question. I agree that the smart thing would be to learn the rudiments of SQL and be able to construct my own queries. I did try pasting your query script into the (Windows) front end I have been playing with and it did indeed generate output - a list of a seeming random selection of 13 albums. I am sure that this could be tinkered with to ultimately produce what I am looking for - a table containing a list of artists and their albums. Then there is the problem of getting this data out of SQL into something (for me) usable and transferrable such as Excel.

    I was hoping that there was somebody out there who had knocked up a nifty plugin that I hadn't seen that would do just this. I can't help feeling that I am not alone in this and that many people would like to be able to generate a neat printed list of artists and albums from their SS database.

    I guess it is time to learn SQL...

    davep

  4. #4
    Member
    Join Date
    Oct 2005
    Location
    Pangbourne, Berks, UK
    Posts
    64
    I would really appreciate something like this as well. I'd like to print out an album list (to check that Ive ripped all my CDs amongst other reasons). If someone could tell us how to generate a csv file, Id be happy to format it in Excel or similar

    Kevin Walsh has a pdf creating script, (see http://www.slimp3.rtfm.info/downloads/index.html )
    but having no idea about PERL I couldnt make this work

    Nigel

  5. #5
    Senior Member ceejay's Avatar
    Join Date
    Apr 2005
    Location
    Reading, UK
    Posts
    2,312
    Quote Originally Posted by NigelC

    Kevin Walsh has a pdf creating script, (see http://www.slimp3.rtfm.info/downloads/index.html )
    but having no idea about PERL I couldnt make this work

    Nigel
    This appears not to have been updated since May 04 so I guess is unlikely to work with the current Slimserver... May be time to get that SQL book out after all...

    Ceejay

  6. #6
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    20,326

    Re: Accessing slimserversql.db contents

    > I would really appreciate something like this as well. I'd like to print
    > out an album list (to check that Ive ripped all my CDs amongst other
    > reasons). If someone could tell us how to generate a csv file, Id be
    > happy to format it in Excel or similar


    There are ODBC drivers available for SQLite
    (http://www.ch-werner.de/sqliteodbc/). You could access the db directly
    from Access or Excel. But please: read-only!

    --

    Michael

    -----------------------------------------------------------
    Help translate SlimServer by using the
    SlimString Translation Helper (http://www.herger.net/slim/)


  7. #7
    Senior Member ceejay's Avatar
    Join Date
    Apr 2005
    Location
    Reading, UK
    Posts
    2,312
    minor glitch in that URL...

    http://www.ch-werner.de/sqliteodbc/

    Ceejay

  8. #8
    Senior Member pfarrell's Avatar
    Join Date
    Apr 2005
    Location
    Wayne, PA
    Posts
    4,251

    Re: Accessing slimserversql.db contents

    NigelC said:
    > I would really appreciate something like this as well. I'd like to print
    > out an album list (to check that Ive ripped all my CDs amongst other
    > reasons).


    Let me back up just a bit.
    There are Sqlite clients, I assume they pass Sql to the database
    and get the usual results.

    I've had wandering arround for this kinda stuff on my back burner
    for a while. But the first, and probably easilest to answer,
    question is: Where is the database? what's it called?
    Assuming that the sqlite client is installed, how do I do
    the equivlent to
    mysql slimdb

    Thx

    Pat
    http://www.pfarrell.com


  9. #9
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    20,326

    Re: Accessing slimserversql.db contents

    > minor glitch in that URL...
    > http://www.ch-werner.de/sqliteodbc/


    Depends on your browser ;-). Opera does not include closing bracket when
    linking.


    --

    Michael

    -----------------------------------------------------------
    Help translate SlimServer by using the
    SlimString Translation Helper (http://www.herger.net/slim/)


  10. #10
    Member
    Join Date
    Oct 2005
    Location
    Pangbourne, Berks, UK
    Posts
    64
    Thanks
    I'll see if I can remember how to use ODBC links

    N

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •