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)
parameter
siraj_farooq
<p>i am using a online DB......i have set parameters earlier in differnt db....but i am having problem now with online db...any one knows how....???????????</p><p> </p>
Find more posts tagged with
Comments
kclark
<p>What kind of database are you working with? You'd add the parameter in the query. If you using mysql it'd look something like this</p><pre class="_prettyXprint">select customernumber, paymentdate, amountfrom paymentswhere customernumber = ?</pre><p>Then in the "parameters" section of the data set UI you can link that to a report parameter. Let me know if I'm understanding what your requirements are
</p><p> </p><p>Also, here's a <a data-ipb='nomediaparse' href='
http://www.birt-exchange.org/devshare/_/designing-birt-reports/969-birt-cascading-parameter-example'>link
to a devshare</a> that shows how to setup a cascading parameter.</p>
siraj_farooq
<p>thanks kclark</p><p> </p><p>i am using a online database.....i already know the method you have described...but it is not working in my case.when i add a it in query paramater is not defined automatically in parameter colum.......is there any other way to do it...... :unsure:</p>
kclark
<p>Is your online database mysql, mongodb, etc?</p>
BRM
<blockquote class="ipsBlockquote" data-author="siraj_farooq" data-cid="120074" data-time="1378813385"><div><p>......is there any other way to do it...... :unsure:</p></div></blockquote><p> </p><p>There is always another way to do it but, in my experience and I am pretty sure that of others, running a parameterized query against an online database works the same as it does when the database is local. If you'll describe the error you are getting (and attach screenshots if you can) we might be able to help you figure out what the problem is.</p>
siraj_farooq
<p>i have added screen shot of my problem......see if you have any solution to this problem</p>
siraj_farooq
<p><a data-ipb='nomediaparse' href='
http://www.birt-exchange.org/forum/index.php?/topic/29016-adding-new-drop-down-in-birt-report-and-changing-query-parameter-based-on-value-from-dropdown/'>http://www.birt-exchange.org/forum/index.php?/topic/29016-adding-new-drop-down-in-birt-report-and-changing-query-parameter-based-on-value-from-dropdown/</a></p><p> </p><p><strong
class='bbc'>if</strong> (params["Country"] != "All"){</p><p><strong class='bbc'>this</strong>.queryText = <strong class='bbc'>this</strong>.queryText + " and CLASSICMODELS.CUSTOMERS.COUNTRY = '" + params["Country"] + "'";</p><p>}</p><p>can i add parameter by this method ?????????</p>
siraj_farooq
<blockquote class="ipsBlockquote" data-author="siraj_farooq" data-cid="120134" data-time="1378884134"><div><p><a data-ipb='nomediaparse' href='
http://www.birt-exchange.org/forum/index.php?/topic/29016-adding-new-drop-down-in-birt-report-and-changing-query-parameter-based-on-value-from-dropdown/'>http://www.birt-exchange.org/forum/index.php?/topic/29016-adding-new-drop-down-in-birt-report-and-changing-query-parameter-based-on-value-from-dropdown/</a></p><p> </p><p><strong
class='bbc'>if</strong> (params["Country"] != "All"){</p><p><strong class='bbc'>this</strong>.queryText = <strong class='bbc'>this</strong>.queryText + " and CLASSICMODELS.CUSTOMERS.COUNTRY = '" + params["Country"] + "'";</p><p>}</p><p>can i add parameter by this method ?????????</p></div></blockquote><p> </p><p>here is the error displayed in preview menu when i add a query.....e,g costumer.numeber = ?</p><p>(data type is bidint)</p><p> </p><p>or can it have any thing to do with schema</p>
Hans_vd
<p>If you add a "?" to your query, you need to somehow provide a value.</p><p> </p><p>So did you bind the data set parameter to a report parameter?</p><p>Or did you provide a default value?</p>
siraj_farooq
<p>han_vd thanks,my problem is solved......it was problem in the driver..last figured it out</p>