home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / database / sybase / 340 < prev    next >
Encoding:
Text File  |  1992-11-17  |  2.7 KB  |  67 lines

  1. Newsgroups: comp.databases.sybase
  2. Path: sparky!uunet!usc!rpi!psinntp!psinntp!bnlux1.bnl.gov!pmdb.sep.bnl.gov!lally
  3. From: lally@pmdb.sep.bnl.gov (Keith Lally)
  4. Subject: Re: APT and TEXT Fields
  5. Message-ID: <1992Nov17.185830.1520@bnlux1.bnl.gov>
  6. Sender: news@bnlux1.bnl.gov (Usenet news)
  7. Organization: Brookhaven National Laboratory
  8. References: <1992Nov13.162033.4728@bnlux1.bnl.gov> <1e8fvqINN250@gazette.bcm.tmc.edu>
  9. Distribution: usa
  10. Date: Tue, 17 Nov 1992 18:58:30 GMT
  11. Lines: 54
  12.  
  13. In article <1e8fvqINN250@gazette.bcm.tmc.edu> mparsons@fleming.csc.bcm.tmc.edu (Mark Parsons) writes:
  14. >
  15. >In article <1992Nov13.162033.4728@bnlux1.bnl.gov>, lally@pmdb.sep.bnl.gov (Keith Lally) writes:
  16. >|> 
  17. >|> I would like to display help screens throughout my APT 
  18. >|> application that are retrieved from a helptext table.
  19. >|> When a function key is pressed the help form execs a
  20. >|> stored procedure on the server that returns the help
  21. >|> text for the particular form.  Does anyone know how
  22. >|> to return a text field from the server into an APT 
  23. >|> form?  Is it possible?  
  24. >
  25. >Our on-line help function just retrieves the appropriate
  26. >help message from a table via a submit-sqlbegin-sqlend
  27. >statement.  Very easy . . .  
  28. >
  29. >When you say 'text', do you mean datatype TEXT, or just
  30. >a character string(char or varchar)?
  31. >
  32. >I can think of two ways to return text from a stored
  33. >procedure call.
  34. >
  35. >One is to send back a string as the error message for an
  36. >error that you generate via the raise-error command.  Of
  37. >course, you then have to 1) test for the occurrence of
  38. >the 'error' and then 2) parse the resulting error text to
  39. >pull out the 'overhead'.  Kinda messy for this situation.
  40. >
  41. >The other is to just pass it back as a return parameter.
  42. >
  43. >
  44. >Hmmmmm, that's 3 ways . . . . . or did I miss something in
  45. >the question? ;-)
  46. >
  47. >Mark
  48.  
  49. Mark,
  50.  
  51. I am referring to fields of the TEXT data type.  Some of my help messages
  52. will exceed 255 bytes so char and varchar are no help.  An entry field on
  53. the form can have a maximum length of 2048 chars or more but how do I 
  54. retrieve the TEXT data and stuff it into the entry field?  One way is to
  55. have the stored procedure read the first 255 bytes of the text, put it into
  56. parameter1 of type char, then read the next 255 bytes and stuff it into 
  57. another parameter.  On the APT side I could then concatenate the params
  58. together and put the result in the entry field.  This seems like a real
  59. kludgy way to do what should be an easy operation.  
  60.  
  61. I also remember reading in one of the manuals that parameters passed between
  62. the server and an apt application can only be 255 chars in length.  Has 
  63. anyone else had experience with this kind of problem?
  64.  
  65. Keith Lally
  66. are limited to 255 bytes and many of our help messagesAs I understand it 
  67.