Hi John, thanks for confirming this. To be honest, I think using the C API as a foundation for the Java API is not ideal. I'd rather prefer the JNIs being based on the C++ implementation because it is much more powerful than the C API.
I know switching the API from C to C++ would cause compatibility issues for existing users and involve significant development time. However, it would be interesting to know if there are any plans for further developing the Java API and into what direction the Java API will evolve (if any). Thank you for info and best regards J -----Original Message----- From: K. John Wu [mailto:[email protected]] Sent: Monday, July 12, 2010 5:54 PM To: FastBit Users Cc: Jan Steemann Subject: Re: [FastBit-users] Aggregate function results and C API Hi, Jan, You are right that the C and Java API does not currently support aggregation functions. At this moment, we are doing some final testing for the next release (ibis1.1.9), therefore, we will not have time to expose the support for aggregation function for the next release. However, we will put in on the list of things to do for the release after the next one. While we are working on implementing the C and Java API for supporting the aggregation function, please feel free to let us know if you have any suggestions on how we should precede. Thanks. John On 7/12/2010 7:55 AM, Jan Steemann wrote: > Hi John, > > we have recently done some tests with the Java bindings for Fastbit. > The Java bindings seem to use the Fastbit C API internally. > > When trying to get simple SELECTs to work with it, I didn't find a way to > select using any aggregate functions. > The select seems to run through well, and the C API has some functions to > return the number of rows matched or the values for the result set of > non-aggregate columns, however, I haven't found a way to access the results > for any aggregate functions. > > Example: > when selecting col1,COUNT(*) using the Java bindings or the C API, I can use > getQualifiedLongs() or fastbit_get_qualified_longs() and friends to access > the results. > getQualifiedLongs() however needs a column name. Aggregate functions do not > have a regular column name, and using an alias (e.g. "COUNT(*) AS n") does > not help. I think the problem is that the C API called by the Java bindings > will look for the column name in ibis::part which is the partition persistent > on disk. > The partition of course does not have any aggregate values, just the result > set has them. However, using the API, there seems to be no access to the > actual column names of the result set and so there is no way to retrieve any > aggregate functions' values using the C API (and thus the Java bindings). > Trying to access the result of an aggregate function will always fail in > src/capi.cpp when calling ibis::part::getColumn(const char *att) in > fastbit_get_qualified_*. > > My perception is that accessing aggregate functions' results using the Java > bindings/C API is yet unimplemented. > Or am I getting something wrong here? > If not, are there any plans to support this in the future? > > Thank you for info on this and best regards > Jan > > > -- > Jan Steemann > Team Manager Development Panel | [email protected] Phone +49 2233 > 7933 752 | Fax +49 2233 7933 788 > > Globalpark AG | Kalscheurener Str. 19a | 50354 Huerth | Germany > Vorstand/Chief Executive Officer (CEO) | Dr. Lorenz Graef > Vorsitzender d. Aufsichtsrats/Chairperson of the Supervisory Board | Dr. > Richard C. Geibel > HRG Amtsgericht Koeln/Entered on Cologne Local Court Commercial Register | > HRB 64032 > > GLOBALPARK - manage what matters | http://www.globalpark.de > > > _______________________________________________ > FastBit-users mailing list > [email protected] > https://hpcrdm.lbl.gov/cgi-bin/mailman/listinfo/fastbit-users _______________________________________________ FastBit-users mailing list [email protected] https://hpcrdm.lbl.gov/cgi-bin/mailman/listinfo/fastbit-users
