[db] added db script and test to get unique identifier