Re: get number of rows selected
От | Andrei Kovalevski |
---|---|
Тема | Re: get number of rows selected |
Дата | |
Msg-id | 47F97928.6010905@commandprompt.com обсуждение исходный текст |
Ответ на | Re: get number of rows selected ("Adam M" <gnuman1@gmail.com>) |
Список | pgsql-odbc |
Hello,
Take a look at SQLRowCount( http://msdn2.microsoft.com/en-us/library//ms711835.aspx ). You may note:
For other statements and functions, the driver may define the value returned in *RowCountPtr. For example, some data sources may be able to return the number of rows returned by a SELECT statement or a catalog function before fetching the rows.
You may rely on this when using psqlODBC or ODBCng with buffering mode ON (default).
Adam M wrote:
Take a look at SQLRowCount( http://msdn2.microsoft.com/en-us/library//ms711835.aspx ). You may note:
For other statements and functions, the driver may define the value returned in *RowCountPtr. For example, some data sources may be able to return the number of rows returned by a SELECT statement or a catalog function before fetching the rows.
You may rely on this when using psqlODBC or ODBCng with buffering mode ON (default).
Adam M wrote:
Generally you would do that with a count function instead of relying on something else. "select * from layer where visible = 1" so I guess "SELECT COUNT(*) FROM layer WHERE visible=1" would give you the answer. - Adam
-- Andrei Kovalevski PostgreSQL Replication, Consulting, Custom Development, 24x7 support Managed Services, Shared and Dedicated Hosting Co-Authors: plPHP, ODBCng - http://www.commandprompt.com/
В списке pgsql-odbc по дате отправления: