[Info-vax] COBOL PIC format for a 64 bit unsigned int ("long long") ?

Bob Koehler koehler at eisner.nospam.encompasserve.org
Tue Oct 13 09:52:39 EDT 2009


In article <QgNAm.12209$U5.166948 at newsb.telia.net>, =?ISO-8859-1?Q?Jan-Erik_S=F6derholm?= writes:
> I am trying to call some COBOL code from a piece of C...
> 
> The call from C looks like this :
> 
>   char cob_inart[16];
>   unsigned long long cob_insernr;
>   char cob_utben[16];
>   char cob_utordnr[16];
>   int rc;
> 
>   rc = MES101(cob_inart, cob_insernr, cob_utben, cob_utordnr);
> 
> I get a ACCVIO when trying to use the "unsigned long long"
> paramater on the COBOL side. I have probably not got the
> right PIC clause to match the "unsigned long long", I guess.
> 

   It's not the "unsigned long long" that is causing the problem.  It's
   C's way of passing scalars.  You might be able to compensate in the
   COBOL, but it's easier to fix it this way in C:

   rc = MES101(cob_inart, &cob_insernr, cob_utben, cob_utordnr);





More information about the Info-vax mailing list