Hi, John, Further question would be how the `estimate` function works. For example, if I have bin boundaries, such as: 0, 10 , 20, 30, 40, and 50 , six bin boundaries for column A( bin 1: [0, 10), bin 2: [10, 20), bin 3: [20, 30), bin 4 [30, 40), bin 5 [40, 50) ) . The where clause has 21<= A <= 35. In such as, all bit positions/RIDs in bin 3 and bin 4 are retrieved, no matter whether the actual value is in the query range or not. Do I understand it correctly? Thanks. nan > Date: Wed, 8 May 2013 10:52:06 -0700 > From: [email protected] > To: [email protected] > CC: [email protected] > Subject: Re: [FastBit-users] How to enable fastbit to answer the query > without touching raw data > > Hi, Nan, > > The class ibis::query does support a function called estimate. You > will need to update your copy of FastBit source code from the SVN > repository (give it some time, the web site hosting the repository is > currently down). > > The sequence of function call should be something like > > 1. bis::query aquery(ibis::util::userName(), &table); > 2. aquery.setWhereClause (wc.str().c_str()); > 3. aquery.estimate(); > 4. vector <uint32_t> RIDs; > 5. aquery.getCandidateRows(RIDs); > > Let us know if you have any questions. > > John > > > On 5/8/13 9:45 AM, nan zhou wrote: > > Dear author, > > > > Is that possible we can enable fastbit to answer the query ( says, > > 1 < a < 10 AND 2< b < 5 ) only by looking up index? I don't need the > > exact answer now, only approximate answer will be fine. Currently, I > > have codes like following: > > > > 1. bis::query aquery(ibis::util::userName(), &table); > > 2. aquery.setWhereClause (wc.str().c_str()); > > 3. aquery.evaluate (); > > 4. vector <uint32_t> RIDs; > > 5. aquery.getHitRows (RIDs); > > > > But I found out for some queries, fastbit need to retrieve data from > > raw data. I verified this by following : > > 1. remove the raw data under fastbit folder > > 2. do the query > > 3. if there is no error, it means fastbit does not touch the data > > 4. otherwise (fastbit complains missing raw data), it means fastbit > > touches the raw data > > > > is there some APIs which allow me to do that ? > > > > thanks > > > > nan > > > > > > _______________________________________________ > > 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
