Could you update the docuemntation - I know OQL is going out of fashion but in quite a few instances LINQ just can't do the job (especially dynamically generated queries, dynamic LINQ is not usable either).
ETA: ANd the origianl response does not make sense - what is the proper syntax for a DEFINE statement?

PetarP

Can you please share with us which documentation exactly are you referring? We have revised all the examples in the OQL chapter some months ago and they were all working. Maybe you are looking at an old version of our pdf documentation ?
The correct syntax for a define statement in OQL would be like this:

Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items.

Hi
The docuemntation at:
http://www.telerik.com/help/openaccess-orm/oql-the-define-statement.html
This is identical to the documentation in the CHM file that comes with the product and the Visual Studio help - the followign statement is totally different from your sample:
DEFINE cheapProducts AS
SELECT *
FROM ProductExtent AS product
WHERE product.unitPrice < 1.0;
SELECT *
FROM s IN nineties
WHERE cheapProducts.name LIKE "Bug*"

Your sample seems to simply define a synonym for an Extent or something like that - in fact in your sample is confusing:DEFINE EXTENT scrap FOR Employee
IN this context what ius Employee - a persisted class? Why would I not use EmployeeExtent? And is it possible to actually define a statement e.g "DEFINE EXTENT scrap FOR employee where employee.status = "Retired""

PetarP

I am sorry for the late response but we were busy with the preparation of the Q1 release.
The DEFINE EXTENT command is used to define a shorter allies for a fully qualified class name ([namespace].[classname]) for projects where classes with the same name exists in different namespaces. You can see examples of that in all our QSF sampels that are using OQL. Those samples are shipped with the product.

All the best,
Petar
the Telerik team

Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items.

PetarP

We are going to release a completely new and restructured documentation. However we have not made any changes in the OQL section of the documentation as we thought it is pretty much completed. That is why we will be happy if we can address any issues you might have found so please share them with us.

Kind regards,
Petar
the Telerik team

Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items.

The issue is that DEFINE documetnation seems completely wrong - it refers to using DEFINE to write a reuable query but all DEFINE does is create an alias for an extent. The code sample in the documentation or an equivalent rewritten for our own purposes simply does not work.

PetarP

We will update the documentation to reflect the information I have provided in this topic. Apart from the Define topic have you found any other inconsistencies that you would like to be changed? We will greatly appreciate any feedback that you might have.

Regards,
Petar
the Telerik team

Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks or appropriate markings.