home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.1 (Developer) [x86] / NeXT Step 3.1 Intel dev.cdr.dmg / usr / sybase / doc / dbcancel.man < prev    next >
Encoding:
Text File  |  1993-04-22  |  2.2 KB  |  67 lines

  1.  
  2.   1                       Version 4.0 -- 5/1/89                 dbcancel
  3.   ______________________________________________________________________
  4.  
  5.   NAME:  dbcancel
  6.  
  7.   FUNCTION:
  8.        Cancel the current command batch.
  9.  
  10.   SYNTAX:
  11.        RETCODE dbcancel(dbproc)
  12.  
  13.        DBPROCESS *dbproc;
  14.  
  15.   COMMENTS:
  16.  
  17.        o This routine cancels execution of the current command batch  on
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.   dbcancel                Version 4.0 -- 5/1/89                        2
  25.   ______________________________________________________________________
  26.          SQL Server and flushes any pending  results.   The  application
  27.          can  call it after calling dbsqlexec(), dbsqlsend(), dbsqlok(),
  28.          dbresults(), or dbnextrow().   dbcancel()  sends  an  attention
  29.          packet  to  SQL Server, which causes SQL Server to cease execu-
  30.          tion of the command batch.  Any pending results  are  read  and
  31.          discarded.
  32.  
  33.        o dbcancel() cancels all the  commands  in  the  current  command
  34.          batch.  To  cancel  only  the results from the current command,
  35.          call dbcanquery() instead.
  36.        o If you have set your own interrupt  handler  using  dbsetinter-
  37.          rupt(),  you  can't  call dbcancel() in your interrupt handler.
  38.          This would cause output from SQL Server to DB-Library to become
  39.          out  of  sync.  If you want to cancel the current command batch
  40.          from your interrupt handler, the interrupt handler should set a
  41.          flag  that you can check before the next call to dbresults() or
  42.          dbnextrow().
  43.  
  44.  
  45.  
  46.   3                       Version 4.0 -- 5/1/89                 dbcancel
  47.   ______________________________________________________________________
  48.  
  49.  
  50.  
  51.  
  52.   PARAMETERS:
  53.        dbproc -  A pointer to the DBPROCESS structure that provides  the
  54.            connection for a particular front-end/SQL Server process.  It
  55.            contains all the information that DB-Library uses  to  manage
  56.            communications and data between the front end and SQL Server.
  57.  
  58.   RETURNS:
  59.        SUCCEED or FAIL.  The most common reasons for failure are a  dead
  60.        DBPROCESS or a network error.
  61.  
  62.   SEE ALSO:
  63.        dbcancel_a,  dbcanquery,  dbnextrow,  dbresults,  dbsetinterrupt,
  64.        dbsqlexec, dbsqlok, dbsqlsend
  65.  
  66.  
  67.