INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: How to combine libraries?  (Read 2698 times)

rar2667

  • Guest
How to combine libraries?
« on: July 10, 2004, 11:16:48 pm »

Can anyone give me a hint on combining 2 libraries? Some time ago I had split all my Christmas music into a separate library to keep it from syncing to my handheld player. Now that ther is a cool Dell DJ plug-in and I can manage what goes there with a smartlist, I would like to put all the Christmas music back in my default library.

I see the export to XML, but don't see an import.

I hope it's not right under my nose and I missed it...

Thanks
Logged

lalittle

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3964
Re:How to combine libraries?
« Reply #1 on: July 11, 2004, 12:50:01 am »

Bring up one of the libraries and make sure "all" is selected across the columns so that all songs are displayed in the song list.  Export an "mpl" playlist to the desktop with "all" in the output range (the default setting.)  Switch to the other library, then minimize MC.  Right click on the exported playlist and select "import."  The current library will now contain all the songs from both libraries.

Larry
Logged

Omni

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 827
Re:How to combine libraries?
« Reply #2 on: July 11, 2004, 02:54:19 am »

I'm curious.  Is this a genuine merge, or this just a quick hack to import a specific set of files?  (I am wondering about all track data which is in the library but not actually stored in the tags.)
Logged

lalittle

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3964
Re:How to combine libraries?
« Reply #3 on: July 11, 2004, 05:08:30 am »

In my experience, all the library data for each file gets exported/imported regardless of whether or not it's saved in the files' tags.  I say this because I've used this method to transfer the data for Audible files between systems, and MC is not able to save tag data to audible files -- i.e. the tag data for Audible files is only stored in the MC library while the files themselves remain unchanged.  When I do an mpl export and import of Audible files, all the information gets correctly transferred over, so the mpl export obviously contains the library data.  (Is that what you meant by "track data"?)

As to the question of whether or not this is a "genuine merge," this is not really a "merge" per se, but it's not a "hack" either, and the end result seems to me to be the same as what a "merge" would give you -- i.e. you end up with a library containing all the files from both libraries.

I'd suggest you simply backup your current libraries and try it -- it's not going to do anything to the files, it's simply going to give you a new library with all the files in it.  If it doesn't work as you want it to, you can simply restore the previous libraries.

That said, I believe that the result will be what you are looking for.  Once again, just make sure to backup the library, and don't make any changes to the tags after you try this procedure until you're sure it worked.

Larry
Logged

Omni

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 827
Re:How to combine libraries?
« Reply #4 on: July 11, 2004, 05:39:06 pm »

Well, by "track data," I was thinking along the lines of custom, user created fields that may or may not be stored in the tags.

It has been a long while, but I recall that at least at one time, if one tried to import a file with a custom field defined in its tags, that field had to be created in the library prior to the import, or else MC would just 1.) ignore it, and 2.) strip it off altogether if MC ever updated the tags after the import.

So I guess I should revise my above query to the following:  Will MC automatically create new custom library fields based on what it sees in the XML file?

Anyway, since you don't know, then yes, of course, I'll test it myself.  Sorry to bother you.  ;)
Logged

rar2667

  • Guest
Re:How to combine libraries?
« Reply #5 on: July 11, 2004, 07:12:52 pm »

Thanks to both...I'll give it a try.
Logged

hit_ny

  • Citizen of the Universe
  • *****
  • Posts: 3310
  • nothing more to say...
Re:How to combine libraries?
« Reply #6 on: July 12, 2004, 12:25:02 am »

This is quite intresting.

If one were to create a custom tag in MC and then export an mpl, modify that mpl and finally import the mpl back would the tag be updated.

eg create a custom tag called Album score in MC. export to mpl. calculate that tag using an external program and then import back into MC.
Logged

Jaguu

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1336
Re:How to combine libraries?
« Reply #7 on: July 12, 2004, 01:54:02 am »

Custom library fields:

As I requested automatic creation of custom library fields at import time many times, Matt always responded that it is very difficult to implement :( The difficulty comes from the fact that a MPL playlist stores only the user defined field name, but no field attributes, eg. whether it is a list field or not!

So we have to live up with that situation and create  the custom library fields of a new library by hand first. Importing from an *.mpl playlist does not create missing fields either. They are simply ignored.

The easiest way to recreate user defined fields is cloning a library with Library Manager. You just create an identical library with a  new name and delete the library content. What will be left is an exact copy of the existing database structure.

So, exporting to *.mpl and reimporting as described above is the way to go. Good luck!

I think simply importing all files should also work as MC always detects whether a file is already in a library or not, so that only new files will be imported! But not 100% sure about that. Better try out with just a few files!
Logged

lalittle

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3964
Re:How to combine libraries?
« Reply #8 on: July 12, 2004, 03:26:59 am »

I think simply importing all files should also work as MC always detects whether a file is already in a library or not, so that only new files will be imported! But not 100% sure about that. Better try out with just a few files!

Actually, this does not work in certain circumstances.  With Audible files, for example, simply reimporting files looks at the tag data, which MC does not store in the files themselves.  You therefore sacrifice any tag changes you have made to these files if you simply do a regular import.  Given this behavior, I would tend to assume that if you choose not to store custom fields in the files, you will lose this data as well.  Using the mpl export, on the other hand, will bring this data over.  Apparently you need to make sure to set up the custom fields in the new library first, but I believe that as long as this is done, you'll end up with all the data, including custom fields, after the mpl import.

Larry
Logged

Jaguu

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1336
Re:How to combine libraries?
« Reply #9 on: July 12, 2004, 03:37:30 am »

Larry,

you are right. Importing only works properly if all tags are stored in the files, user defined fields included. Thanks for pointing that out!

As I do this for all my audio / image files I forgot that this might not always be the case. Don't even know if tagging of video files is possible such as divx videos!
Logged

hit_ny

  • Citizen of the Universe
  • *****
  • Posts: 3310
  • nothing more to say...
Re:How to combine libraries?
« Reply #10 on: July 14, 2004, 07:33:19 am »

Quote
Using the mpl export, on the other hand, will bring this data over.  Apparently you need to make sure to set up the custom fields in the new library first, but I believe that as long as this is done, you'll end up with all the data, including custom fields, after the mpl import.

Quote
Importing only works properly if all tags are stored in the files, user defined fields included

I'm a bit confused here.

let's say i have only the default tags stored in the mp3 files. AA info is stored in the library only.

i create a custom field called album rating. i export to mpl a playlist of files. i run an external program to calculate the album rating which is written to the mpl.

According to what was discussed above, on import of the mpl file :
- will the calculated album rating successfully import into MC, (It was created in MC before export to mpl) ?
- will i lose data for fields that were only stored in the library for the files but not in the files ? I'm under the impression that if the exported MPL captures all fields (default+custom) associated with a file, this won't result in any loss.
Logged

Jaguu

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1336
Re:How to combine libraries?
« Reply #11 on: July 14, 2004, 08:02:02 am »

As far as I noticed, importing from an mpl-file does not change any existing data, but only adds missing data.

So in my case, when I edited an mpl file externally, I delete all the specific data in the library before importing. This worked well for me as I exported and imported all fields of specfic images, but it you export data selectively this may be more difficult to achieve.

Maybe J River can give some more details how it works exactly.
Logged

IlPadrino

  • MC Beta Team
  • Galactic Citizen
  • *****
  • Posts: 496
Re:How to combine libraries?
« Reply #12 on: July 14, 2004, 10:54:10 am »

As far as I noticed, importing from an mpl-file does not change any existing data, but only adds missing data.

So in my case, when I edited an mpl file externally, I delete all the specific data in the library before importing. This worked well for me as I exported and imported all fields of specfic images, but it you export data selectively this may be more difficult to achieve.

Maybe J River can give some more details how it works exactly.

It used to work (and I think still does)  that MC only imports items that did *not* exist in the library - i.e. if an MPL item (based on filename) was already in the library, it would pass over it.  This means that there is no way to "update" the library with an MPL.  Scott_r was going to make an MC XML Import (to go along with his great MC XML Export), but that hasn't happened yet.  I was hoping J River would see the value of this an add it as a new future - but so far, no luck.

Jaguu's process of deleting all the items first is the only way to do this - but I understand why some people would consider this a bit risky.  Although, so long as you export everything before deleting, you should be safe and sound.
Logged

Jaguu

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1336
Re:How to combine libraries?
« Reply #13 on: July 14, 2004, 11:25:49 am »

And backup the Library first...
Logged
Pages: [1]   Go Up