add query, db, fix