gharris999;243389 Wrote: 
> 
> > JJZolx Wrote: 
> > 
> > You could probably just take the existing database, and add a table
> > called 'libraries' with name, music and playlist folder settings. Then
> > most of the other tables get an additional field referencing the
> > library number. A scan could either do a single library, or it could
> > scan all of them. All queries would need to use the library number to
> > which the player is currently attached. The remote, web and cli
> > interfaces would need functions to switch a player between libraries.
> > > > 
> That would work.

The Multi Library plugin pretty much does it this way. It has a
multilibrary_libraries table that contains a single row for each
library and a multilibrary_tracks table that contains a single row for
each library/track combination. The multilibrary_tracks table is just a
relation table that refers to the library id and track id, so it doesn't
contain any data.

I'm not sure it's a good idea to add a library column to the existing
tables, because it would mean that a specific music file and its
corresponding data would exist twice in the database, at least if we
allow several libraries to share files. This could result in
consistency problem.

The problem with support for multiple libraries in SlimServer is really
not about adding a new table or column, the big work will be to change
all the existing logic so it uses that column. I have a feeling this
potentially can affect a lot of different parts of SlimServer. 

Another big part is if you like to be a able to define a library in
advanced ways. If each libraries files is stored in a separate folder
this part is simple, bit if you also like to be able to share files it
gets a bit more complex.


-- 
erland

Erland Isaksson
'My homepage' (http://erland.homeip.net) 'My download page'
(http://erland.homeip.net/download)
(Developer of 'TrackStat, SQLPlayList, DynamicPlayList, Custom Browse,
Custom Scan,  Custom Skip, Multi Library and Database Query plugins'
(http://wiki.erland.homeip.net/index.php/Category:SlimServer))
------------------------------------------------------------------------
erland's Profile: http://forums.slimdevices.com/member.php?userid=3124
View this thread: http://forums.slimdevices.com/showthread.php?t=31431

_______________________________________________
beta mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/beta

Reply via email to