Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BIRT » String based parameters in ODA OCL
String based parameters in ODA OCL [message #776829] Mon, 09 January 2012 10:30 Go to next message
Nigel Daniels is currently offline Nigel DanielsFriend
Messages: 66
Registered: July 2009
Member
Hi,

I have been looking at using sub-reports in a report based on and EMF
model. I found that the following dataset query:

self.objectives->select(id='O1').issues

returns all of the issues contained by the objectives. So I would now
like to replace the 'O1' (a string) with a parameter. To do this I edit
the first Parameter to be the following:

Name: ObjectiveId
Native Name : @target (this seems to be the default)
Data Type: String
Direction: Input
Default Value: 'O1' (type Constant)
Linked to Report Parameter : None

I also change my query to be:

self.objectives->select(id='?').issues

Here is where the problems start for me :( When I now run my query it
does not return anything.

I also note that the name I changed in the parameter fails to 'stick'
and it reverts to @target?

I tried changing the Default Value to be O1 without quotes and I get an
exception:

org.eclipse.birt.data.engine.odaconsumer.OdaDataException: Cannot
execute the statement.
org.eclipse.datatools.connectivity.oda.OdaException: @target:
Unrecognized variable: (O1)
at
org.eclipse.birt.data.engine.odaconsumer.ExceptionHandler.newException(ExceptionHandler.java:52)
....


BTW The reason I edit the @target in the first place is due to the
problem I face if I add a parameter. When I do this I get a parameter
where I cannot set the Native Name, this appears empty. When I run the
query I get the exception:

org.eclipse.birt.data.engine.odaconsumer.OdaDataException: Cannot
execute the statement.
org.eclipse.datatools.connectivity.oda.OdaException: Extra argument
expression (ObjectiveId)
at
org.eclipse.birt.data.engine.odaconsumer.ExceptionHandler.newException(ExceptionHandler.java:52)
....

Any help with what is causing these problems is very welcome.

Best regards,

Nigel.
Re: String based parameters in ODA OCL [message #1745643 is a reply to message #776829] Thu, 13 October 2016 19:02 Go to previous message
Maged Elaasar is currently offline Maged ElaasarFriend
Messages: 23
Registered: September 2013
Junior Member
Did you figure out what was the problem with adding a parameter in the EMF datasets? I also get "Extra argument expression"

Maged
Previous Topic:duplicate
Next Topic:Birt viewer on a Standalone java application whitout server
Goto Forum:
  


Current Time: Mon Sep 23 22:01:38 GMT 2024

Powered by FUDForum. Page generated in 0.03834 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top