home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.3 (Developer) / NeXT_Developer-3.3.iso / NextLibrary / Documentation / Sybase / DBLIB / Section2 / dbsqlsend.nr < prev    next >
Encoding:
Text File  |  1993-04-22  |  2.1 KB  |  67 lines

  1. .Na "dbsqlsend" 
  2. .Aa
  3. .Fu
  4. Send a command batch to \*S and do not wait for a response.
  5. .Ih "command batch, executing"
  6. .Ih "command batch, sending to \*S"
  7. .Sy
  8. .Sf "RETCODE dbsqlsend(dbproc)"
  9. .Sp "DBPROCESS" "*dbproc"
  10. .Co
  11. .Bl
  12. This routine sends SQL commands, stored in the
  13. command buffer, to \*S.
  14. The application can add commands
  15. to the command buffer by calling
  16. \f2dbcmd()\f1 or \f2dbfcmd()\f1.
  17. .Bl
  18. Once \f2dbsqlsend()\f1 returns SUCCEED,
  19. the application must call
  20. \f2dbsqlok()\f1 to verify the accuracy
  21. of the command batch.
  22. The application can then call
  23. \f2dbresults()\f1 to process the results.
  24. .Bl
  25. \f2dbsqlexec()\f1 is equivalent to \f2dbsqlsend()\f1 followed by \f2dbsqlok()\f1.
  26. .Bl
  27. The use of \f2dbsqlsend()\f1 with \f2dbsqlok()\f1 is of particular value in UNIX
  28. applications.
  29. After sending a query to \*S, \f2dbsqlexec()\f1 waits until
  30. a response is received or until the timeout period has elapsed.
  31. By substituting \f2dbsqlsend()\f1 and \f2dbsqlok()\f1 for \f2dbsqlexec()\f1,
  32. you can sometimes provide a way for a UNIX application
  33. to respond more effectively to multiple input and output streams.
  34. The time between the request for
  35. information from \*S (made via a call to \f2dbsqlsend()\fP)
  36. and \*S's response (read by calling \f2dbsqlok()\fP)
  37. can be used, in conjunction with \f2DBIORDESC()\f1 or \f2DBIOWDESC()\f1, to
  38. service other parts of the application.
  39. \f2DBIORDESC()\f1 and \f2DBIOWDESC()\f1 are available for UNIX only.
  40. See the manual pages for those two routines for more information.
  41. .sp 0.5v
  42. For a UNIX example that illustrates the use of \f2dbsqlsend()\f1 with \f2dbsqlok()\f1,
  43. \f2DBIORDESC()\f1 and \f2DBIOWDESC()\f1, see the \f2\*L Reference Supplement\f1.
  44. .Bz
  45. .Pa
  46. .Pi dbproc
  47. A pointer to the DBPROCESS structure that provides the connection
  48. for a particular front-end/\*S process.  It contains all the
  49. information that \*L uses to manage communications and data between the
  50. front end and \*S.
  51. .in -.375i
  52. .Re
  53. .br
  54. SUCCEED or FAIL.
  55. \f2dbsqlsend()\f1 may fail if previous results had not been processed, or if
  56. the command buffer was empty.
  57. .Sa
  58. dbcmd, 
  59. dbfcmd, 
  60. DBIORDESC, 
  61. DBIOWDESC, 
  62. dbnextrow, 
  63. dbresults, 
  64. dbsettime, 
  65. dbsqlexec,
  66. dbsqlok
  67.