add sql count(*) support