When I lost my database, but my files were still on drive D on Windows, I did the following:
I imported all tracks from drive D into Engine DJ Desktop (= ED).
Since most work is setting again all the hot cues and loops. Getting the hot cues back was the most important to me. I think recreating all the playlists is not the most amount of work.
If you want to do the same you can do the following:
– Download DB Browser for SQLite. Link: Downloads - DB Browser for SQLite
The following step is not necessary but to keep it clean and avoid mistakes.
– Create a work folder e.g. EngineTemp
– inside this folder create two sub folders “local” and “prime4”
– copy the m.db file from your D drive Engine Dj folder to the local folder
– copy the m.db file from your Prime 4 to the prime folder
– Start DB Browser for SQLite
– In the file menu choose open database and open select the m.db from the local folder
– Go again to the file menu and choose attach database, but this time select m.db from the prime4 folder.
– You will get a pop up asking for a name under which you want to acces the attached database, you can give any name, but in this case use the following name “mprime4”
Go to the tab “Database structure” here you you should now see both database structures m and mprime4
Now click on the tab “execute SQL”
And paste the following script:
create table TrackP as select * from mprime4.Track
This will copy the track table from the prime database to the local ED database.
Than execute the following script to copy all the data like hot cues, loops etc to the local database for matching file names.
UPDATE Track
SET (
bpm,
--bitrate,
bpmAnalyzed,
isAnalyzed,
dateCreated,
dateAdded,
isBeatGridLocked,
trackData,
overviewWaveFormData,
beatData,
quickCues,
loops,
activeOnLoadLoops
)
= (
SELECT bpm,
--bitrate,
bpmAnalyzed,
isAnalyzed,
dateCreated,
dateAdded,
isBeatGridLocked,
trackData,
overviewWaveFormData,
beatData,
quickCues,
loops,
activeOnLoadLoops
FROM TrackP
WHERE TrackP.filename = Track.filename
AND TrackP.quickCues <> x'00000081789C636000030E86FD1F181080761C381BC6000010B010DF'
)
WHERE Track.filename IN (
SELECT TP.filename
FROM TrackP TP
WHERE TP.isAnalyzed = 1 AND
TP.quickCues <> x'00000081789C636000030E86FD1F181080761C381BC6000010B010DF'
)
AND
Track.quickCues = x'00000081789C636000030E86FD1F181080761C381BC6000010B010DF'
Just to be sure that the database is not corrupt:
PRAGMA integrity_check;
Some other helpful script:
List files which will be updated by the query above:
SELECT T.filename,
T.quickCues,
hex(T.quickCues),
TP2.ID,
TP2.quickCues AS PrimeCue,
hex(TP2.quickCues) AS PrimeCueHex,
TP2.ID AS PrimeID
FROM Track T
INNER JOIN
TrackP TP2 ON T.filename = TP2.filename
WHERE TP2.isAnalyzed = 1 AND
TP2.quickCues <> X'00000081789c636000030e86fd1f181080761c381bc6000010b010df' AND
T.quickCues = X'00000081789c636000030e86fd1f181080761c381bc6000010b010df';
Copy the local database m.db back to Engine Dj folder on drive D.
If you need a script to relocate a lot of files to another folder let me know.
I hope that this helps…