> Your function definition looks sound. SIDEEFFECTS is a synonym for
> EXTERNAL ACTION. I think you have done what you can here.
[quoted text clipped - 6 lines]
> Cheers
> Serge
> > Your function definition looks sound. SIDEEFFECTS is a synonym for
> > EXTERNAL ACTION. I think you have done what you can here.
[quoted text clipped - 25 lines]
> --
> Karl Hanson
@Karl: thanks for you suggestion. It works, but it's unfortunately not
what we're looking for. Perhaps it's a good idea to tell a bit more
about what we're doing. We're building a Java EE application on top of
an existing database on the AS/400 / iSeries system. We need some sort
of pagination mechanism, because our dataset s are really large. The
ORM framework we use (JPA / EclipseLink) does have pagination, but it
does not know how to paginate for DB2 databases. This means that our
Java programs can set pagination parameters ("Only return records
starting from record 30 and return no more than 15 records.") The
framework will return the requested records, but under the hood
fetches ALL records from the database. Of course, this is very bad for
the performance. So what I'm trying to do is extend that framework so
that it knows how to get just the records it needs from the database.
Since the application server uses connection pooling, we don't have a
guarantee that a certain connection is only to be used to serve a
given user. So we can't rely on temporary tables stored on a session.
Re-creating the temporary tables for every request is also not an
option, since this it takes the AS/400 several seconds to create the
temporary tables...
@Serge: Does "next step is support" mean that you suspect this to be a
bug? If so, is there any chance it can be fixed on V5R3, or will the
advise be to upgrade to V5R4 or something like that? The thing is,
upgrading is not an option for us (at least at the moment). The reason
we're building a Java EE application is that we have to replace an
application that's written in Delphi. And that's because as of V5R4
that Delphi application won't work anymore. Given the size of the
application, there's no chance we can do a "big bang" scenario,
switching from the Delphi app. to the Java app. overnight. So there
will be a period of several months (or perhaps even years) where both
application will be used...
@all: Thanks for your help so far. I'll keep you posted when I make
progress with this. Please let me know if anyone has a smart
suggestion for a work around...
Best regards,
Bart Kummel
Bart Kummel - 26 Feb 2008 07:28 GMT
> > > Your function definition looks sound. SIDEEFFECTS is a synonym for
> > > EXTERNAL ACTION. I think you have done what you can here.
[quoted text clipped - 64 lines]
> Best regards,
> Bart Kummel
Hi all,
I contacted IBM support last week. The problem has to do something
with the query engine. I'm not really into AS/400 stuff, but it turns
out that the CQE engine is used because we have indexes (logicals in
AS/400 terms) on our tables. IBM support was not able to reproduce our
problem on the latest PTF level of V5R3 and we're somewhat behind on
PTF level. So our administrator has ordered a CD with the latest
cumulative patches. When our machine is on the latest patch level
we'll see if this solves the problem. (In the meantime, we can remove
the indexes/logicals temporarily.) Thank you all for you support!
Best regards,
Bart Kummel