fixed status code bug. fixed bug on non existing db, dbname and table