Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Download and get help for different MediaMonkey for Windows 4 Addons.

Moderators: Peke, Gurus

MoDementia
Posts: 1321
Joined: Thu Jun 15, 2006 3:26 pm
Location: Geelong, Victoria, Australia

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by MoDementia »

This adds played history for the last played date that are missing
So it will reduce the discrepencey by 1 for tracks played on the ipod
The rest need to be fixed with one of the other scripts mentioned :(
It's the code that will included in Add/Remove PlayStat 1.1.1 (2008-10-09) [MM3] soon

...Scripts\Scripts.ini

Code: Select all

[CheckPlaycountVSPlayed]
Filename=CheckPlaycountVSPlayed.vbs
Procname=CheckPlaycountVSPlayed
Order=100
DisplayName=CheckPlaycount VS Played
Description=CheckPlaycount VS Played
Language=VBScript
ScriptType=0
Scripts\CheckPlaycountVSPlayed.vbs

Code: Select all

Sub CheckPlaycountVSPlayed
  xCounter = 0
  Set iter = SDB.DataBase.OpenSQL("SELECT ID,LastTimePlayed FROM Songs LEFT JOIN Played ON Songs.ID=Played.IDSong WHERE PlayCounter>0 GROUP BY Songs.ID HAVING PlayCounter>COUNT(IDSong)")
  Do While NOT iter.EOF
    ID = iter.ValueByIndex(0)
    LastTimePlayed = iter.StringByIndex(1)
    PlayedCount = SDB.DataBase.OpenSQL("SELECT COUNT(*) FROM Played WHERE IDSong=" & ID & " AND Playdate=" & LastTimePlayed).ValueByIndex(0)
    If PlayedCount = 0 Then
      SDB.DataBase.ExecSQL("INSERT INTO Played (IDSong,PlayDate) VALUES(" & ID & "," & LastTimePlayed & ")")
    End If
    xCounter = xCounter + 1
  iter.next
  Loop
End Sub
RobSpook
Posts: 28
Joined: Wed Oct 15, 2008 12:10 am

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by RobSpook »

yep, that does it! That is awesome :)
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by nynaevelan »

MoD:

I've been getting some strange behavior in the last couple of days, when I try to run a export sync the directory box stays visible even though the export file is created. But whether I hit ok, cancel or the red x it will not go away. The only way to get rid of it is to kill my mm session. Any ideas what could be causing this?

Nyn
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
MoDementia
Posts: 1321
Joined: Thu Jun 15, 2006 3:26 pm
Location: Geelong, Victoria, Australia

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by MoDementia »

There might be an error message behind the export form, next time you export a sync, drag it to the top right, bottom left, where ever before clicking ok

Sometimes alt tab between MM and something else, or show desktop will unhide such an error message
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by nynaevelan »

Thanks I'll look for that...

Nyn
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by nynaevelan »

MoD:

I tried your suggestion but it is still happening with no error boxes, it must be something with XP or my computer because it doesn't happen on my home computer.

Nyn
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
RobSpook
Posts: 28
Joined: Wed Oct 15, 2008 12:10 am

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by RobSpook »

I should add that I have experienced the same problem occasionally when using DEISync on my laptop. I was unable to find a specific scenario that causes it though which is why I never reported it.
MoDementia
Posts: 1321
Joined: Thu Jun 15, 2006 3:26 pm
Location: Geelong, Victoria, Australia

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by MoDementia »

What can I say, there isn't alot of code to look at after you click ok

It copies the live database to the export directory and then is "supposed" to hide the form before it starts modifying the exported database :(
unnicorn
Posts: 18
Joined: Fri Mar 09, 2007 12:21 am

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by unnicorn »

Hello,

I need your help please:

I have recently moved out of my house and realised that I would have to take all the songs with me. I have copied all of that to my laptop. I also have a copy of the MM DB folder.

On my laptop I have installed MM3 and the script to sync it.

Can you please advice whats the next step for syncing the songs....

Please note I havent imported the mp3s on my laptop yet.

Thanks.
Scripts I use: Advanced Report
MoDementia
Posts: 1321
Joined: Thu Jun 15, 2006 3:26 pm
Location: Geelong, Victoria, Australia

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by MoDementia »

Not exactly what the script is for (although it could have been used before you moved out)

Here is a guide to help out http://www.mediamonkey.com/wiki/index.p ... w_computer
unnicorn
Posts: 18
Joined: Fri Mar 09, 2007 12:21 am

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by unnicorn »

Ok thanks for your help.
Scripts I use: Advanced Report
MoDementia
Posts: 1321
Joined: Thu Jun 15, 2006 3:26 pm
Location: Geelong, Victoria, Australia

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by MoDementia »

I have been thinking with all the "beta" testing going on that I might add another option to import values from a backup DB that would be missing from a fresh install add/rescan

i.e. Just
Date Added
And all the play history

I think that is all that is missing from the mp3 files themselves?
Other formats would need additional fields though? :(

[EDIT] And maybe Nyn's Playlists :P
[EDIT] Hmmm I think it can already do that via m3us?
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by nynaevelan »

MoDementia wrote:I have been thinking with all the "beta" testing going on that I might add another option to import values from a backup DB that would be missing from a fresh install add/rescan

i.e. Just
Date Added
And all the play history

I think that is all that is missing from the mp3 files themselves?
Other formats would need additional fields though? :(
That would be cool. :D
MoDementia wrote: [EDIT] And maybe Nyn's Playlists :P
[EDIT] Hmmm I think it can already do that via m3us?
This would be unnecessary since the import m3us is already included.

Are all five custom fields and the classicifation (if multi-values exist) fields saved to the tag? Also, I do not know how critical it would be to include the portable sync info. It wouldn't be necessary for a testing environment but if you wanted to go live with a clean install but keep all your device info? :-? Or if you really want to complicate it what about filter settings?? That's enough thinking for one day.

Nyn
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
gron
Posts: 2
Joined: Tue Feb 05, 2008 6:13 pm

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by gron »

nynaevelan wrote:I have been thinking with all the "beta" testing going on that I might add another option to import values from a backup DB that would be missing from a fresh install add/rescan

i.e. Just
Date Added
And all the play history

I think that is all that is missing from the mp3 files themselves?
Yes, this would really help get me out of a jam. There's some "error" in my database. (Difficult to explain.) The only way I can get rid of it is to rebuild mm.db from scratch, but that would mean I would lose the tag data that isn't in the track files.
(Note: I link all my files to folder.jpg artwork and these links disappear when I rebuild mm.db. Not sure if that could be added to your list...?)
seppo
Posts: 8
Joined: Sat Jun 04, 2005 1:25 pm

Re: Database Export\Import\Sync(DEISync) v2.3.5 (09-10-08) [MM3]

Post by seppo »

Hi,

I recently found this topic by suggestion to my question, but none of the links for the script didn't work.. how could the scriot be obtained, is there a new link somewhere, which I maybe missed?
Post Reply