Home » Developer & Programmer » Precompilers, OCI & OCCI » Free C++ Library for OCI Aggregate Functions
Free C++ Library for OCI Aggregate Functions [message #159192] Thu, 16 February 2006 11:18
Messages: 1
Registered: February 2006
Location: Toronto, ON
Junior Member
I am developing a C++ library to take care of some of the bookkeeping required when implementing aggregate functions using the ODCI interface. If you are implementing aggregate functions in C++ you may want to take a look at the library to see if it could be of use to you. It is available for download at http://www.daes.ca/library. Although it is a C++ library it only uses the OCI interface, it does not use OCCI. If you use the library I would be interested in your feedback. Thank you.

An example of a complete implementation of an aggregate function to calculate the skewness of a column of NUMBER values would be:

  class Skewness
   void Calculate(const std::deque<double>& data, double* result)
     *result = skewness(data.begin(), data.end());

  typedef AggregateCollect<Skewness> SkewAggr;

The library includes a tool for automatically generating the corresponding Oracle type and function. The library has been tested with Oracle 9i & 10g, and on Windows (32 & 64) using VS2003 & VS2005 and Linux (32 & 64) using GCC3 & GCC4.

David Taylor
DAES Software Development Incorporated
Previous Topic: Fast Application Notification with OCI based app?
Next Topic: How to compile multiple Pro*C programs in single C++ file
Goto Forum:

Current Time: Sat Apr 29 22:46:32 CDT 2017

Total time taken to generate the page: 0.16417 seconds