Re: MPW C++ and Pro*C on Macintosh

From: Keith Campbell <campbell_at_camis.stanford.edu>
Date: 20 Apr 1993 19:56:05 GMT
Message-ID: <1r1kgl$qot_at_morrow.stanford.edu>


In article <1993Apr20.154613.1_at_uqvax.cc.uq.oz.au> , ccvern_at_uqvax.cc.uq.oz.au writes:
>Has anyone out there used Pro*C with MPW C++ on the Macintosh?
Vern,

I use Pro*C with MPW C++ all the time (well sort of).

I program MacApp 3.0 in C++ and call Pro*C routines from the MacApp code all the time. The actual database routines are written in regular C, but get called from the C++ files. You just have to write a single file and header in C that contains all the Pro*C embeded SQL statements. Put the following in your C++ file to include the database routine that you wrote in C. Then use Pro*C on the C file and link them all together. It works great!

#ifndef __UDatabase__
extern "C" {
#include "UIvoryDatabase.h"
}
#endif  

Hope that helps.

Keith Campbell
Section on Medical Informatics
Stanford University School of Medicine
campbell_at_camis.stanford.edu Received on Tue Apr 20 1993 - 21:56:05 CEST

Original text of this message