Javascript Get Count Of Values In Sql