extracting database_name