Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Creating dataset parameters for an oracle datasource
KHANNAA
Hi All,<br />
<br />
I am new to BIRT reporting tool.<br />
I am using oracle.jdbc.driver.OracleDriver (v11.1) to connect to my database from birt.<br />
The report connects fine and run good. I am able to see the data in the previewer.<br />
The problem occurs when I try to add parameters in my query<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
select
from case_member
WHERE id_case = ?</pre>
<br />
I get the following error message<br />
I expect to see a parameter created when I use the query above. But no parameter is created.<br />
and I get the following error message<br />
<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>A BIRT exception occurred.
Plug-in Provider:Eclipse.org
Plug-in Name:BIRT Data Engine
Plug-in ID:org.eclipse.birt.data
Version:2.6.2.r262_v20110215
Error Code:odaconsumer.CannotGetResultSetMetaData
Error Message:Cannot get the result set metadata.
org.eclipse.birt.report.data.oda.jdbc.JDBCException: SQL statement does not return a ResultSet object.
SQL error #1:Missing IN or OUT parameter at index:: 1
;
java.sql.SQLException: Missing IN or OUT parameter at index:: 1</pre>
<br />
When I create the parameter myself and give the parameter a default value, the query does not return rows in the preview Results tab.<br />
<br />
Plz help!<br />
<br />
Abhishek
Find more posts tagged with
Comments
mwilliams
After entering the above query in your dataSet, when you go to the "parameters" section in the dataSet editor, there isn't a parameter created?
KHANNAA
<blockquote class='ipsBlockquote' data-author="'mwilliams'" data-cid="78867" data-time="1308690746" data-date="21 June 2011 - 02:12 PM"><p>
After entering the above query in your dataSet, when you go to the "parameters" section in the dataSet editor, there isn't a parameter created?<br /></p></blockquote>
<br />
No parameter is created.
mwilliams
Try deleting the dataSet and starting over. If it still doesn't work, you can get around this by adding the where clause in your beforeOpen script of your dataSet.
KHANNAA
Thanks a lot!
The scripting workaround worked.
mwilliams
Great to hear. Glad to help! Let us know whenever you have questions!
KHANNAA
<blockquote class='ipsBlockquote' data-author="'mwilliams'" data-cid="78900" data-time="1308755002" data-date="22 June 2011 - 08:03 AM"><p>
Great to hear. Glad to help! Let us know whenever you have questions!
<br /></p></blockquote>
<br />
I have one more Issue.<br />
I have a Gird on the master page which I am using as a header.<br />
Now when I use the HTML output the whole header is getting displayed but when I view the report as a PDF file only have of the header is visible.<br />
Could you tell me why is this happening and how I can resolve this issue?
KHANNAA
I figured it out.<br />
Had to change the layout preference from <strong class='bbc'>Fixed</strong> layout to <strong class='bbc'>Auto</strong> layout.
mwilliams
Glad you found it! Let us know whenever you have questions!
stephan.uzzell
<blockquote class="ipsBlockquote" data-author="mwilliams" data-cid="78869" data-time="1308693300"><div><p>Try deleting the dataSet and starting over. If it still doesn't work, you can get around this by adding the where clause in your beforeOpen script of your dataSet.</p></div></blockquote><p>I'm having this same struggle - every time I try to add a parameter, I get a ridiculously long error stack that starts with</p><div> </div><div>org.eclipse.birt.data.engine.odaconsumer.OdaDataException: Cannot get the result set metadata.</div><div> org.eclipse.birt.report.data.oda.jdbc.JDBCException: SQL statement does not return a ResultSet object.</div><div>SQL error #1:Missing IN or OUT parameter at index:: 1</div><div> ;</div><div> java.sql.SQLException: Missing IN or OUT parameter at index:: 1</div><div> </div><div>I've recreated the dataSet a couple times, so I may need to add that part of the where clause to the beforeOpen script - but I'm not sure how to go about that, not finding much documentation on it. What part of my query goes in there?</div><div> </div><div>Thanks...</div>