Yes, crossdjdb is syncronized with android media db, but after that all information you need are in the crossdjdb.
I know very well SQL so I do it last year, but to do it I had to root my device and it's not always possible nor recommended.
In db, the path of mp3 is in field "_data".
My mediastore was corrupted for pics and videos, I regenerated it cleaning media provider app. So all media was renumerated and CrossDj2 db erases all values.
Position of songs ("_data") are the same so I repopulate crossdj db from a backup (db2), coping db on Windows:
- Code: Select all
UPDATE main.collection
SET
bpm = (SELECT c2.bpm
FROM db2.collection as c2
WHERE c2._data = main.collection._data )
, harmonic_key = (SELECT c2.harmonic_key
FROM db2.collection as c2
WHERE c2._data = main.collection._data )
, cue_loops = (SELECT c2.cue_loops
FROM db2.collection as c2
WHERE c2._data = main.collection._data )
WHERE
EXISTS (
SELECT *
FROM db2.collection as c2
WHERE c2._data = main.collection._data
)
;
if paths change, a replace can be used in filter:
- Code: Select all
-- TEST
select
c1._data,
c2.bpm
from collection as c1,
db2.collection as c2
where
c2._data = replace(c1._data, '/sdcard1/','/sdcard0/')
limit 0,100
In a similar way I imported bpm from db of another application (just for sort songs) and it works.
Developers never accepts that user read nor write in db, but someone with the right skills may need it.