I was wondering if somebody might be able to sched some light for me on
handling text types in stored procedures. We are trying to build
a library of similar procedures to perform specific operations for
each table in our database. These routines would be called from
4GL applications and ESQL/C.
The problem is that (IMHO), Sybase doesn't handle text types very well.
You cannot pass a variable of type text to a stored procedure and
you cannot operate on variables of type text inside. You have
to do it using text pointers which is a major pain and very awkward.
For instance, how would a user pass in a piece of text for insertion
into a table? Seems to me he would have to create a temporary table,
store the text in there and pass the textptr to that row to be read.
The writetext statement does not appear to accept variables as
the last parameter containing the actual text to be written, only
constants. Huh??? Am I missing something here?