You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by Mike Moser <mi...@timesearchinc.com> on 2007/06/08 20:45:15 UTC

ERROR XSCH6: The heap container with container id Container(-1, 1181324479199) is closed.

I am getting this error when I am iterating through a ResultSet. I make no
other calls to the db while this is running but after a certain number of
loops the result inexplicitly closes.

 

My code is as follows:

 

While (resultSet.next()) {

 

int eKey = resultSet.getInt("event_id");

Event event = loadEventMap.get(eKey);

if (event == null) {

                        event = new Event();

                        event.getEventSources().clear();

                        loadEventMap.put(eKey, event);

                        

                        event.setPrimaryKey(eKey);

 
event.setUuid(UUID.fromString(resultSet.getString(CONST_EVENT_UUID)));

                        event.setName(resultSet.getString(CONST_SUMMARY));

 
event.setContent(resultSet.getString(CONST_CONTENT));

 
event.setDescription(resultSet.getString(CONST_DESCRIPTION));

 

..........

 

// Continues adding fields from the query to the event object until ...

 

...........

 

eventSource.setEventLastSyncronized(resultSet.getDate("event_last_synchroniz
ed"));

 
eventSource.setSourceString(resultSet.getString("event_source"));

 
eventSource.setVisibility(Visibility.values()[resultSet.getInt("visibility")
]);

 
eventSource.setTransparency(Transparency.values()[resultSet.getInt("transpar
ency")]);

                        event.getEventSources().add(eventSource);

                  }

 

 

 

}

 

The problem is consistant in that it happens on the same query at the same
record but there is now data issues as when I run the query using squirrel
it return all rows successfully

 

 

Thanks for any advice,

 

Mike


No virus found in this outgoing message.
Checked by AVG Free Edition. 
Version: 7.5.472 / Virus Database: 269.8.13/840 - Release Date: 6/8/2007
3:15 PM
 

Re: ERROR XSCH6: The heap container with container id Container(-1, 1181324479199) is closed.

Posted by Kristian Waagan <Kr...@Sun.COM>.
Hello Mike,

I'm sorry I can't help with your problem, but I'm sure those who can 
would like to know which version of Derby you use when this happens, and 
if you run with the embedded or the client driver.
If you have a full stack trace (from your app and/or from derby.log), 
that might also help.


thanks,
-- 
Kristian

Mike Moser skrev:
>
> I am getting this error when I am iterating through a ResultSet. I 
> make no other calls to the db while this is running but after a 
> certain number of loops the result inexplicitly closes.
>
>  
>
> My code is as follows:
>
>  
>
> While (resultSet.next()) {
>
>  
>
> *int* eKey = resultSet.getInt("event_id");
>
> Event event = loadEventMap.get(eKey);**
>
> *if* (event == *null*) {
>
>                         event = *new* Event();
>
>                         event.getEventSources().clear();
>
>                         loadEventMap.put(eKey, event);
>
>                        
>
>                         event.setPrimaryKey(eKey);
>
>                         
> event.setUuid(UUID./fromString/(resultSet.getString(/CONST_EVENT_UUID/)));
>
>                         
> event.setName(resultSet.getString(/CONST_SUMMARY/));
>
>                         
> event.setContent(resultSet.getString(/CONST_CONTENT/));
>
>                         
> event.setDescription(resultSet.getString(/CONST_DESCRIPTION/));
>
>  
>
> ..........
>
>  
>
> // Continues adding fields from the query to the event object until ...
>
>  
>
> ...........
>
>  
>
> eventSource.setEventLastSyncronized(resultSet.getDate("event_last_synchronized"));
>
>                         
> eventSource.setSourceString(resultSet.getString("event_source"));
>
>                         
> eventSource.setVisibility(Visibility./values/()[resultSet.getInt("visibility")]);
>
>                         
> eventSource.setTransparency(Transparency./values/()[resultSet.getInt("transparency")]);
>
>                         event.getEventSources().add(eventSource);
>
>                   }**
>
> * *
>
> * *
>
> * *
>
> *}*
>
> * *
>
> The problem is consistant in that it happens on the same query at the 
> same record but there is now data issues as when I run the query using 
> squirrel it return all rows successfully
>
>  
>
>  
>
> Thanks for any advice,
>
>  
>
> Mike
>
>
> No virus found in this outgoing message.
> Checked by AVG Free Edition.
> Version: 7.5.472 / Virus Database: 269.8.13/840 - Release Date: 
> 6/8/2007 3:15 PM
>