Jody is correct, we decided to not implement this (unless there is a real transaction), because the only posible implementation for 1.0 is a feature-scan ... so left it up to the user.
I don't think we defined an action for AUTO_COMMIT, but -1 sounds correct as a default value for unknown.
I can take a look at this, or you can add the two lines (will need to do an instanceof check for the
TransactionStateDiff, and when there is a failure return a -1 count). It will work for real transactions, because at that time we have a fid-set, which is countable.
TransactionStateDiff, and when there is a failure return a -1 count). It will work for real transactions, because at that time we have a fid-set, which is countable.
David
On 2/1/06, Jody Garnett <[EMAIL PROTECTED]> wrote:
The answer is that WFS only works from a transaction - not for
Transaction AUTO_COMMIT
> Howdy,
>
> http://jira.codehaus.org/browse/GEOT-804
>
> I'm having trouble with getCount for WFS. It's throwing a class cast
> exception in AbstractDataStore.diff (Transaction) because the state of
> the transaction is not an instance of TransactionStateDiff. The
> problem is that the WFSFeatureStore doesn't have its own
> implementation of getCount(Query) yet.
>
> David, do you have a moment to look at this, or should I submit a
> quick patch which returns a "-1" result?
>
> Thanks,
> Cory.
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc. Do you grep through log
> files
> for problems? Stop! Download the new AJAX search engine that makes
> searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
> _______________________________________________
> Geotools-devel mailing list
> Geotools-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geotools-devel