cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrus Adamchik <and...@objectstyle.org>
Subject Re: CayenneRuntimeException: Can't find id
Date Tue, 15 Jan 2008 10:38:20 GMT
Hi Dan,

Not even sure at this point that this is an issue of int vs. long... I  
wonder how the *new* object even appears in the paginated list that  
was created *before* the new object? Or did I misunderstand something  
about your scenario?

Maybe it would help if you could post the exception and the SQL log  
preceding it.

Thanks
Andrus



On Jan 14, 2008, at 10:07 PM, Daniel Kvasnička jr. wrote:

> Hi people,
> I've bumped into an error with cayenne 2.0.4 and the only similar
> things I found were this message
> (http://cayenne.markmail.org/message/elln5rjlgrsdinxm?q=paging+cache+type:users 
> )
> and the bug CAY-643 (and those linked to it).
>
> What I do is that I load a page with paginated query (list of
> articles, first 10), then I hit "new article" on the page, create and
> save the article and return back to the list.
> Then I paginate to find the newly added article and when I enter the
> page it is on and the page is the last page at the same time, I get
> the CayenneRuntimeException with "Can't find id for [the newly added
> article]" (i.e. when I set sorting to, let's say, by ID DESC -- which
> puts the new article to the first page -- everythong is OK on all
> pages)
>
> I understand there is the problem with long vs. int and that it will
> be fixed in 3.0, so how can I as a user prevent this error in 2.0.4?
> This seems to me like a very common scenario in listing records and
> doing CRUD operations, but it seems almost nobody encounters this. Do
> you guys adandon pagination and use raw sql?
>
> I wanted to try 3.0M2, but when using it Stripes couldn't find any
> ActionBeans url mappings -- strange.
>
> Thanks for all hints in advance,
> Dan
>
> -- 
> http://www.danielkvasnicka.net -- webdesign & corporate design,
> programování internetových a intranetových aplikací
>


Mime
View raw message