refractor user and added table name

Signed-off-by: Mauro Scomparin <scompo@gmail.com>