This doesn't make much sense to me, but that may just be my lack of understanding your requirements.
But in any case, the answer is: No, there is nothing in iBATIS that will help you do this...and you may want to rethink your logic on this. A stored procedure to do a calculation on 16k rows in a database will be almost instantaneous, but pulling that data into Java to do the same calculation will be orders of magnitude slower. If you want the calculated data to be as accurate as possible then pulling it into Java will 100% guarantee that it *isn't* always accurate - the database has the most current data, and by the time it gets to Java, it may have changed. In the context of a web application, this is even more pronounced, because you may get the most current data, do your calculation, then discard it because no requests came in for that data. That seems really inefficient to me... Larry On 6/11/07, Ashish Kulkarni <[EMAIL PROTECTED]> wrote:
Hi I can use stored procedure to read this data, but i would like to store it in java( basically this is a web application ) so store this in a ServletContext or some where and update it when ever there is change in this data. if was wondering if ibatis can be any help in doing so On 6/10/07, Larry Meadors <[EMAIL PROTECTED]> wrote: > I'd look for a way to make the database do this - any solution on the > Java side will be inherently out-of-date. > > Can you do this in a stored procedure? > > Larry > > > On 6/10/07, Ashish Kulkarni <[EMAIL PROTECTED]> wrote: > > Hi > > I have a situation where i have a table of about 16,000. rows, which i need > > to use for mathematical calculation. > > i want to cache the data and this data should update as soon as the database > > is updated. > > > > Database is updated by external process, so Java program does not know if > > there is update by some other process. > > > > Is it possible to do this requirement using ibatis, any suggestions > > > > Ashish > > > > > > > > >
