Re: Pro*C/C++, __FILE__ and __LINE__

From: Alex Vinokur <alexander.vinokur_at_telrad.co.il>
Date: Sun, 10 Oct 1999 09:18:10 GMT
Message-ID: <7tplkd$pch$1_at_nnrp1.deja.com>


[Quoted] In article <37FDD08D.E0306F37_at_deutsche.post.de>,   Arndt Binninger <a.binninger2_at_deutsche.post.de> wrote:
> Hi Alex,
>
> try Precompiler-Option: LINES=YES.
>
> In my error-code I use:
>
> printf("\tin Zeile %d of %.*s.\n\n", oraca.oraslnr,
> oraca.orasfnm.orasfnml,
> oraca.orasfnm.orasfnmc);
>

Thank you very much for your answer.
Using Precompiler-Option: LINES=YES

   I have got a desirable result
   with __LINE__ and __FILE__.

   But I didn't have a desirable result

   with oraca.oraslnr,
        oraca.orasfnm.orasfnml,
        oraca.orasfnm.orasfnmc.

   What is wrong?
        Thanks in advance,
        Alex



//#########################################################
//------------------- Pro*C/C++ code : BEGIN --------------
#include <stdio.h>

#include <sqlca.h>
[Quoted] #include <oraca.h>
EXEC ORACLE OPTION (ORACA=YES);
int main()
{
        printf ("\t%s %d\n", __FILE__, __LINE__); /* ttt.pc, Line#7 */
        printf("\tin Zeile %d of %.*s.\n\n", oraca.oraslnr,
                 oraca.orasfnm.orasfnml,
                 oraca.orasfnm.orasfnmc);


        return 0;

}
//------------------- Pro*C/C++ code : END ----------------



//#########################################################
//------------------- Compilation : BEGIN -----------------

proc iname=ttt LINES=YES

Pro*C/C++: Release 8.0.5.0.0 - Production on Sun Oct 10 9:48:35 1999

(c) Copyright 1998 Oracle Corporation. All rights reserved.

System default option values taken from: [Quoted] /home/u01/app/oracle/product/8.0.5/precomp/admin/pcscfg.cfg

[snip]

//------------------- Compilation : END -------------------



//#########################################################
//------------------- Running Results : BEGIN -------------

        ttt.pc 7
        in Zeile 0 of .


//------------------- Running Results : END ---------------


//#########################################################
//------------------- System ------------------------------

=== Oracle 8.0.5

=== Pro*C/C++ : Release 8.0.5.0.0
=== SunOS 5.6
//---------------------------------------------------------

//#########################################################




Sent via Deja.com http://www.deja.com/
Before you buy. Received on Sun Oct 10 1999 - 11:18:10 CEST

Original text of this message