[fdo-internals] Sorting in SDF?

Orest Halustchak orest.halustchak at autodesk.com
Tue Feb 6 12:19:37 EST 2007


Hi,

Docs for the SDF extended select and extended feature reader are here:
http://fdo.osgeo.org/files/fdo/docs/SDF/index.html
Have a look at the SdfIExtendedSelect and SdfIScrollableFeatureReader
classes.

There are two general extensions provided, the main one as Badreddine
mentioned is the scrollability and random access via the reader. The
other is additional ordering capabilities that are extended from the
ordering capabilities available in the core select command.

One concern that I have to roll this into the standard select is around
the SdfCompareHandler which is a call back function used during sorting
provide client-customizable comparisons between property values. Many
providers such as the rdbms-based providers just delegate filtering and
sorting to an underlying engine and supporting this type of call back
may not be possible in those cases. Options are to take out that
function and not provide a client-customizable compare, or if we keep
it, include a capability for providers that choose not to support it. Is
such a function useful enough for applications that you might write to
keep it? Do we want some other control over collating sequence at this
level that might be more generic?

Also, the scrolling ability would have to include both a capability (not
all providers would support this) as well as control at the select
command level whether you want a scrolling reader or not for the
particular select command. In many cases, there would be a performance
cost to providing a scrollable reader versus a non-scrollable reader and
the client would not need it in all situations.

Comments?

Thanks,
Orest.


-----Original Message-----
From: fdo-internals-bounces at lists.osgeo.org
[mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Badreddine
Karoui
Sent: Tuesday, February 06, 2007 9:14 AM
To: FDO Internals Mail List
Subject: RE: [fdo-internals] Sorting in SDF?

The main feature of this command is the scrollability and random access
of the reader. This was requested for the SDF provider and was decided
not to extent FDO for just one provider. Then it was needed for the SHP
provider. At that point we considered adding it to FDO but it was
decided that the timing was not ideal and it should be revisit it for
the next release. 

Once this functionality makes it to FDO, then one of the options would
be to just extent the existing FdoISelect command plus a new capability.

Badreddine

-----Original Message-----
From: fdo-internals-bounces at lists.osgeo.org
[mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Robert Bray
Sent: Monday, February 05, 2007 9:01 PM
To: FDO Internals Mail List
Subject: Re: [fdo-internals] Sorting in SDF?

Actually I am not sure we are finished with the conversation on this
list :)

I looked at the interface to SdfExtendedSelect which is almost, but not
quite, identical to FdoISelect. Why not implement the optimized sorting
in the standard command so that all clients can take advantage of it?

Turn that around for a minute. If every provider implements a
<ProviderName>ExtendedSelect command, doesn't that diminish the value of

FDO to client application developers? Why would I choose to use FDO if I

have to write custom code for each provider?

Maybe we should revisit this command and consider rolling the behavior
into the standard Select command implementation.

Bob


Jason Birch wrote:
> Ok, thanks, something to take up on the MapGuide list :)
> 
> -----Original Message-----
> From: fdo-internals-bounces at lists.osgeo.org
> [mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Badreddine

> Karoui
> Sent: Monday, February 05, 2007 11:35
> To: FDO Internals Mail List
> Subject: RE: [fdo-internals] Sorting in SDF?
> 
> I don't think it is. 
> 
> Badreddine
> 
> -----Original Message-----
> From: fdo-internals-bounces at lists.osgeo.org
> [mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Jason
Birch
> Sent: February 5, 2007 2:21 PM
> To: FDO Internals Mail List
> Subject: RE: [fdo-internals] Sorting in SDF?
> 
> Interesting.  
> 
> Any idea if this is supported through the MapGuide APIs?
> 
> Jason
> 
> -----Original Message-----
> From: fdo-internals-bounces at lists.osgeo.org
> [mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Badreddine

> Karoui
> Sent: Monday, February 05, 2007 11:17
> To: FDO Internals Mail List
> Subject: RE: [fdo-internals] Sorting in SDF?
> 
> It's actually not supported by the aggregate function and if it is 
> enabled, then it probably would not perform. However the SDF provider 
> has a custom command that supports sorting on multiple properties with

> different sorting parameter. This command is the SdfExtendedSelect 
> command. This command is designed to perform and use less memory than 
> the generic sorting algorithm provided in the FDO command.
> 
> Badreddine
> 
> -----Original Message-----
> From: fdo-internals-bounces at lists.osgeo.org
> [mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Pierre 
> Dalcourt
> Sent: February 5, 2007 2:07 PM
> To: FDO Internals Mail List
> Subject: RE: [fdo-internals] Sorting in SDF?
> 
> Hi Jason,
> 
> Although the SDF capabilities state that ordering is not supported, it

> actually is supported by SDF Provider's SelectAggregates command.
> It just isn't supported by the Select command, so there was a decision

> to set the capability to say its not supported.
> Also, I'm not sure if there a performance issues for large sets that 
> need to be sorted -- your mileage may vary.
> 
> Pierre
> 
> -----Original Message-----
> From: fdo-internals-bounces at lists.osgeo.org
> [mailto:fdo-internals-bounces at lists.osgeo.org] On Behalf Of Jason
Birch
> Sent: February 5, 2007 2:00 PM
> To: FDO Internals Mail List
> Subject: [fdo-internals] Sorting in SDF?
> 
> Hi,
> 
> It looks like ordering is not supported in SDF?
> 
> Any idea what it would take to add support for this?  It's pretty 
> important for a couple apps I'm working on where I need multi-key
sorts.
> 
> Jason
> _______________________________________________
> fdo-internals mailing list
> fdo-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fdo-internals
> _______________________________________________
> fdo-internals mailing list
> fdo-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fdo-internals
> 
> _______________________________________________
> fdo-internals mailing list
> fdo-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fdo-internals
> _______________________________________________
> fdo-internals mailing list
> fdo-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fdo-internals
> 
> _______________________________________________
> fdo-internals mailing list
> fdo-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fdo-internals
> _______________________________________________
> fdo-internals mailing list
> fdo-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fdo-internals
> 
_______________________________________________
fdo-internals mailing list
fdo-internals at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/fdo-internals


_______________________________________________
fdo-internals mailing list
fdo-internals at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/fdo-internals



More information about the fdo-internals mailing list