ssa_db_helper.c: making DB dump more generic

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>