Hello I copied your example from HowToModel.xmi.zip and created: context TaskChunk::findChunkBetweenDays(userId:String,fromDay:Date,toDay:Date):Collection(TaskChunk) body findChunkBetweenDays : allInstances->select(task_chunk | task_chunk.start_time < fromDay and task_chunk.owner.user_account_id = userId and (task_chunk.stop_time = null or task_chunk.stop_time > toDay) )
(just testcode yet so ignore any logical errors ;-) but when trying to call this function I get the following error: 17:43:29,703 INFO [STDOUT] Hibernate: select from where (task_chunk.start_time<? )and(task_chunk.owner.user_account_id=? )and((task_chunk.stop_time=null )or(task_chunk.stop_time>? )) 17:43:29,953 WARN [JDBCExceptionReporter] SQL Error: 0, SQLState: 42601 17:43:29,953 ERROR [JDBCExceptionReporter] ERROR: syntax error at or near "from" 17:43:30,000 WARN [JDBCExceptionReporter] SQL Error: 0, SQLState: 42601 17:43:30,000 ERROR [JDBCExceptionReporter] ERROR: syntax error at or near "from" It seems as though the table name & what I am selecting (*) is missing from the HQL ! Any ideas about this óne ? Also does anyone have a good OCL link, for the syntax of this ? // Mikael _________________________________________________________ Reply to the post : http://galaxy.andromda.org/forum/viewtopic.php?p=475#475 Posting to http://forum.andromda.org/ is preferred over posting to the mailing list! ------------------------------------------------------- This SF.Net email is sponsored by Yahoo. Introducing Yahoo! Search Developer Network - Create apps using Yahoo! Search APIs Find out how you can build Yahoo! directly into your own Applications - visit http://developer.yahoo.net/?fr=offad-ysdn-ostg-q22005 _______________________________________________ Andromda-user mailing list Andromda-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/andromda-user