If you are using vfp 9 you can get this with one of the parameters in SQLEXEC. Prior to that I have returned a multiple record set as part of the SP (but since I have a scripting engine for this adding this code was pretty easy).

---------------------------------------------------------------------------------------------------------------------------------------------

/aCountInfo/

   Specifies the name of the array to populate with row count
   information. If the array doesn’t exist, it is created. The array
   has two columns: 1 – Alias, 2 –Count.
   Column       Array contents  Data type       Description

   Alias

        

   0

        

   Character

        

   Indicates that SQL command did not return any results. Either no
   records were returned or the SQL command failed before results could
   be returned. (final *SQLMORERESULTS* call) or execution failed
   before any result could be processed. Can be only on the first row.
   Count column for the row contains value -1.


        

   Non-empty uppercase string

        

   Character

        

   Alias of the cursor – target for the record fetch operation. The
   Count column for the row contains the number of fetched records or
   -1 if fetch failed. If Count is -1, cursor may not have been
   created. During asynchronous execution, the fetch process for a
   cursor can be split between multiple SQLMORERESULTS or SQLEXEC
   calls; each call returns its own fetch count for the cursor.


        

   Empty String

        

   Character

        

   Indicates that the SQL command (INSERT, UPDATE, or DELETE) did not
   return a result set.

   Count

        

   Number of affected or fetched records.

        

   Integer

        

   Indicates the number of affected records as returned by the ODBC
   SQLRowCount function. Returns -1 if the number of records is
   unavailable.

---------------------------------------------------------------------------------------------------------------------------------------------

Regards

--
Michael Hawksworth
Visual Fox Solutions

[EMAIL PROTECTED]
www.foxpro.co.uk





_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to