My model is:
(generalization)
Destination 1 ---------------- * Stuff <-----------------------------
Route
and my ocl expression is : "Route.allInstances->select(m |
m.Destination.Name.toUpper()='INDIA')"
I successfully retrieve objects using OclService, but when I want to
run it using
OclPsService, I receive this error:
Borland.Eco.Persistence.Connection.DatabaseOperationFailedException:
Error
executing SQL: SELECT Route_1.ECO_ID
FROM Route Route_1 JOIN Stuff Stuff_1 ON (Stuff_1.ECO_ID =
Route_1.ECO_ID)
WHERE ((UPPER(Destinatio_1.Name)) = @Param0)
The column prefix 'Destinatio_1' does not match with a table name or
alias
name used in the query. ---> System.Data.SqlClient.SqlException: The
column
prefix 'Destinatio_1' does not match with a table name or alias name
used in
the query.
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior
cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
at System.Data.SqlClient.SqlCommand.ExecuteReader()
at
System.Data.SqlClient.SqlCommand.System.Data.IDbCommand.ExecuteReader
()
at
Borland.Eco.Persistence.Connection.AbstractIQueryImpl.CreateReader()
I am using ECO 3 and MS-SQL 2000 as DBMS.
Is this a known issue or I am doing something wrong?
By the way, how can I use SQL functions through ocl? and how can I get
help on the list of native supported functions in OclPs.
Thanks