Daniel Skiles wrote: > Dan, > Thanks for the tip. The strange thing about this is that it seems to > work fine if I use a different database, such as MS SQL Server or > Oracle. While I wouldn't be surprised if it was my code causing the > exception, the fact that it only happens with Derby makes me wonder. > I've included the full stack trace. Do you have any ideas about what > might be causing it? > > 38000-The exception 'java.lang.StackOverflowError' was thrown while > evaluating an expression. > ERROR 38000: The exception 'java.lang.StackOverflowError' was thrown > while evaluating an expression. > at > org.apache.derby.iapi.error.StandardException.newException(Unknown > Source) > at > org.apache.derby.iapi.error.StandardException.unexpectedUserException(Un > known Source) > at > org.apache.derby.impl.services.reflect.DirectCall.invoke(Unknown Source) > at > org.apache.derby.impl.sql.execute.ProjectRestrictResultSet.getNextRowCor > e(Unknown Source) > at > org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl.getNextRow(Unk > nown Source) > at > org.apache.derby.impl.jdbc.EmbedResultSet.movePosition(Unknown Source) > at org.apache.derby.impl.jdbc.EmbedResultSet.next(Unknown > Source) > at > com.docfinity.orphantracker.CommandLineMk2.main(CommandLineMk2.java:153) > XJ001-Java exception: ': java.lang.StackOverflowError'. > java.lang.StackOverflowError > at > org.apache.derby.impl.sql.execute.UnionResultSet.openCore(Unknown > Source) > at > org.apache.derby.impl.sql.execute.UnionResultSet.openCore(Unknown > Source) > at
Hmmm, indeed it looks like it is looping in Derby code. Are you using a function or procedure? Can you post the query you are using, and if a function/procedure is involved the source of that? Any reproducible case would allow this to be fixed much quicker. Dan.
