Fix mssql ref + test

Signed-off-by: Laurent Laville <laurent.laville@gmail.com>