Need a row count after SELECT statement: what's the optimal SQL approach?

后端 未结 10 1098
悲哀的现实
悲哀的现实 2020-12-05 02:19

I\'m trying to select a column from a single table (no joins) and I need the count of the number of rows, ideally before I begin retrieving the rows. I have come to two app

10条回答
  •  忘掉有多难
    2020-12-05 02:33

    Why don't you put your results into a vector? That way you don't have to know the size before hand.

提交回复
热议问题