Change merge script to handle the application table (it can have dups) and allow for hyphens in DB names.
Bug fix: if the kind code wasn't found in the lookup the script would fail.

Changed so the title would be NULL.