Hello Richard,
thanks for the comment.

>-----Original Message-----
>From: Richard Barrington [mailto:[EMAIL PROTECTED]]
<cut>
>But the SAP DB Reference Manual says (VAR)CHAR is ok up to 8000

The length for (VAR)CHAR is 8000 this is also for Precompiler host variables valid.
We are actually rewrite the Precompiler manual and we will fix this.

>Also, what is the recommended means of dealing with large FIXED fields?
>I have code which uses an "unsigned long long" (8 bytes) for values, but
>the precompiler doesn't accept this type, and the built in DECIMAL type
>is only good for 15 integer places.

The type long long isn't supported by the precompiler. 8 bytes integers are only
possible with 64 bit versions.
If you use dynamic SQL with the descriptor SQLDA you can use the hostvartype 
sqlvint8=33 
for a binding to a 8 byte integer value. Otherwise you can extend the built in 
datatype 
DECIMAL by declaring a struct with the precision you need.

Example:
  EXEC SQL BEGIN DECLARE SECTION;
  struct {char arr[38];} col1;
  EXEC SQL END DECLARE SECTION;

  EXEC SQL SELECT 12345678901234567890123456789012345678 FROM DUAL;

  EXEC SQL FETCH INTO :col1;

Regards
Burkhard
_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general

Reply via email to