Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » BIRT 4.2 Default Value for Dataset Input parameter is not working
BIRT 4.2 Default Value for Dataset Input parameter is not working [message #896081] Tue, 17 July 2012 08:21 Go to next message
Rama Krishna is currently offline Rama Krishna
Messages: 8
Registered: July 2012
Junior Member
Im using the latest version of the BIRT All in one 4.2. The below query for the data set works fine with the value for SITE_CODE as '230'.

select SITE_CODE, TRANSACTION_ID, SERIAL_NUMBER from status_header
where STATUS = '120'
and COMPLETE_DATE = '20120716'
and SITE_CODE = '230'

However when the query is modified as below to receive the SITE_CODE as Input by adding he Dataset Input parameter of String type with the same Default Value as 230, the Preview Results of the data set is not showing any results

select SITE_CODE, TRANSACTION_ID, SERIAL_NUMBER from status_header
where STATUS = '120'
and COMPLETE_DATE = '20120716'
and SITE_CODE = '?'

I'm not linking the parameter to any Report Parameter as the basic feature of default value is not working.

Please let me know the issue. Im not able to use Dynamic queries linking the Data Set parameters with Report Parameters as Default value for Data set parameter itself is not working.

Appreciate your help.
Re: BIRT 4.2 Default Value for Dataset Input parameter is not working [message #896234 is a reply to message #896081] Tue, 17 July 2012 16:28 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason Weathersby
Messages: 9167
Registered: July 2009
Senior Member

Try changing this:
and SITE_CODE = '?'
to
and SITE_CODE = ?

Jason

On 7/17/2012 4:21 AM, Rama Krishna wrote:
> Im using the latest version of the BIRT All in one 4.2. The below query for the data set works fine with the value for SITE_CODE as '230'.
>
> select SITE_CODE, TRANSACTION_ID, SERIAL_NUMBER from status_header
> where STATUS = '120'
> and COMPLETE_DATE = '20120716'
> and SITE_CODE = '230'
>
> However when the query is modified as below to receive the SITE_CODE as Input by adding he Dataset Input parameter of String type with the same Default Value as 230, the Preview Results of the data set is not showing any results
>
> select SITE_CODE, TRANSACTION_ID, SERIAL_NUMBER from status_header
> where STATUS = '120'
> and COMPLETE_DATE = '20120716'
> and SITE_CODE = '?'
>
> I'm not linking the parameter to any Report Parameter as the basic feature of default value is not working.
>
> Please let me know the issue. Im not able to use Dynamic queries linking the Data Set parameters with Report Parameters as Default value for Data set parameter itself is not working.
>
> Appreciate your help.
>
Re: BIRT 4.2 Default Value for Dataset Input parameter is not working [message #896240 is a reply to message #896234] Tue, 17 July 2012 16:55 Go to previous messageGo to next message
Rama Krishna is currently offline Rama Krishna
Messages: 8
Registered: July 2012
Junior Member
I changed '?' to ? removing the quotes in the query but now it gives sql error (Cannot get parameter type, Unsupported feature) :

org.eclipse.birt.report.data.adapter.api.AdapterException: An exception occurred during processing. Please see the following message for details:
Failed to prepare the query execution for the data set: Outbound Site Data Set
Cannot get the type for parameter: 1.
org.eclipse.birt.report.data.oda.jdbc.JDBCException: Cannot get parameter type.
SQL error #1:Unsupported feature ;
java.sql.SQLException: Unsupported feature at org.eclipse.birt.report.data.adapter.impl.DataRequestSessionImpl.execute(DataRequestSessionImpl.java:644)


Please find the detailed error message attached.

Are String types for dynamic parameters not supported by BIRT?
Re: BIRT 4.2 Default Value for Dataset Input parameter is not working [message #896245 is a reply to message #896240] Tue, 17 July 2012 17:03 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason Weathersby
Messages: 9167
Registered: July 2009
Senior Member

Yes they are supported. What data source are you using?

Jason


On 7/17/2012 12:55 PM, Rama Krishna wrote:
> I changed '?' to ? removing the quotes in the query but now it gives sql error (Cannot get parameter type, Unsupported feature) :
>
> org.eclipse.birt.report.data.adapter.api.AdapterException: An exception occurred during processing. Please see the following message for details:
> Failed to prepare the query execution for the data set: Outbound Site Data Set
> Cannot get the type for parameter: 1.
> org.eclipse.birt.report.data.oda.jdbc.JDBCException: Cannot get parameter type.
> SQL error #1:Unsupported feature ;
> java.sql.SQLException: Unsupported feature at org.eclipse.birt.report.data.adapter.impl.DataRequestSessionImpl.execute(DataRequestSessionImpl.java:644)
>
> Please find the detailed error message attached.
>
> Are String types for dynamic parameters not supported by BIRT?
>
Re: BIRT 4.2 Default Value for Dataset Input parameter is not working [message #896255 is a reply to message #896245] Tue, 17 July 2012 18:06 Go to previous messageGo to next message
Rama Krishna is currently offline Rama Krishna
Messages: 8
Registered: July 2012
Junior Member
I tried with both Oracle 10g & Oracle 11g and nothing worked.
And the issue is not specific to datatype as it is not working with Integer type either.

Looks like the latest version of BIRT is not supporting dynamic parameters this way for Oracle datasources as per the below topic:
http://www.eclipse.org/forums/index.php/mv/msg/367290/894990/

Shall I switch to previous version - 3.7.2?
Re: BIRT 4.2 Default Value for Dataset Input parameter is not working [message #896273 is a reply to message #896255] Tue, 17 July 2012 20:02 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason Weathersby
Messages: 9167
Registered: July 2009
Senior Member

You can use a script work around, but I would give a day or two to see
if the bug:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=384925
gets updated.

Jason

On 7/17/2012 2:06 PM, Rama Krishna wrote:
> I tried with both Oracle 10g & Oracle 11g and nothing worked. And the
> issue is not specific to datatype as it is not working with Integer type
> either.
> Looks like the latest version of BIRT is not supporting dynamic
> parameters this way for Oracle datasources as per the below topic:
> http://www.eclipse.org/forums/index.php/mv/msg/367290/894990/
>
> Shall I switch to previous version - 3.7.2?
Re: BIRT 4.2 Default Value for Dataset Input parameter is not working [message #896291 is a reply to message #896255] Tue, 17 July 2012 21:56 Go to previous message
Rama Krishna is currently offline Rama Krishna
Messages: 8
Registered: July 2012
Junior Member
I tried with BIRT 3.7.2 and it works fine now.
Previous Topic:Editable Chart in BIRT doc file
Next Topic:BIRT temporary files cleanup
Goto Forum:
  


Current Time: Mon Sep 22 12:24:41 GMT 2014

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

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