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)
cascade parameter with date restriction
GuB
Hi
I try to make a report using cascade parameters and wand to add a date specific parameter.
My only problem is, that if I add a date parameter and then use my cascade parameter group
(customer, product, ...) the date parameter value gets evaluated at the report start
, but if I want to change the date restriction in a second run, it stays the same, although I changed the date value.
Therefore I tried to add the date restriction to the cascade parameter group, but there I can only apply parameters which belong to a datasource!
Is there a way to assign a single parameter of type Date without assigning a datasource?
Rgds
Guenter
PS: I am using the beforeOpen methode in the datasets of my cascade parameters and added there the date restriction like the following:
this.queryText =
"select s.customer,
from dwh.scrap s
where s.error in ('"+ params["errors"].toString().replace(/,/g,"','") +"') and
s.startDay_scrap Between STR_TO_DATE(concat((DATE_FORMAT('"+ params["start"].value +"', '%Y/%m/%d')) ,' 06:00:00' ), '%Y/%m/%d %H:%i:%s') and STR_TO_DATE(concat((DATE_FORMAT('"+ params["end"].value +"', '%Y/%m/%d')) ,' 06:00:00' ), '%Y/%m/%d %H:%i:%s');";
Find more posts tagged with
Comments
averma
Hi Guenter,
You should be able to rerun the same report with new parameter values. I am attaching a sample report that uses a couple of cascading parameters along with a date parameter that is not tied to any data source. Parameter values are used to filter the data set. Let me know if I have a correct understanding of your issue.
Ashwini
GuB
Hi Ashwini <br />
<br />
Thanks for your reply, but my problem is a little bit different. I want to use the date restriction at first, and not at the end.<br />
Please find attached the modified example of yours, called (ProductSold_date_restriction_new.rptdesign)<br />
<br />
Here I put the date restriction on first place (default value: 02/10/2003) and added the date restriction to both datasets, so that according to the date restriction only the specific productline and product should be loaded into the comboboxes of the parameters.<br />
So the whole topic is working fine if using the date defaultvalue. In this case for productline contains "Vintage cars", "Ships" and "Planes".<br />
<br />
Please change now the date to 06/10/2003 during report parameter selection. In this case, the productline should now restrict to the new date inserted and should offer "Classic Cars", "Planes", "Ships" and "Vintage Cars". But this is not the case.<br />
And this i my initial problem. It seems that the refreshing of the date parameter happens when the report gets started, but not when the report is running and I want to change the date parameter in a new selection.<br />
<br />
Can you please help me?<br />
<br />
(maybe you have to change the format for the date default value. As I am using german version with date format 06-10-2003 you need to change it back to 2003/10/06)<br />
<br />
Rgds<br />
G?nter
averma
Hi Guenter,
I could not get your report running with the default parameters but I think I get a sense of what you are trying to achieve. I think you should make date parameter cascaded with other parameters. Take a look at the attached report design (modified) and see if it serves your purpose.
Ashwini
GuB
Hi Ashwini <br />
<br />
Fetching the date values out of a dataset would solve my problem, thanks.<br />
I will try it out in my report.<br />
<br />
Is it planned to add single parameters to the cascade parameter Ggoup,<br />
in order to use the date picker field instead of a constant growing combobox?<br />
<br />
Rgds<br />
<br />
G?nter<br />
<br />
<br />
<br />
<blockquote class='ipsBlockquote' data-author="'GuB'" data-cid="66544" data-time="1279542459" data-date="19 July 2010 - 05:27 AM"><p>
Hi Ashwini <br />
<br />
Thanks for your reply, but my problem is a little bit different. I want to use the date restriction at first, and not at the end.<br />
Please find attached the modified example of yours, called (ProductSold_date_restriction_new.rptdesign)<br />
<br />
Here I put the date restriction on first place (default value: 02/10/2003) and added the date restriction to both datasets, so that according to the date restriction only the specific productline and product should be loaded into the comboboxes of the parameters.<br />
So the whole topic is working fine if using the date defaultvalue. In this case for productline contains "Vintage cars", "Ships" and "Planes".<br />
<br />
Please change now the date to 06/10/2003 during report parameter selection. In this case, the productline should now restrict to the new date inserted and should offer "Classic Cars", "Planes", "Ships" and "Vintage Cars". But this is not the case.<br />
And this i my initial problem. It seems that the refreshing of the date parameter happens when the report gets started, but not when the report is running and I want to change the date parameter in a new selection.<br />
<br />
Can you please help me?<br />
<br />
(maybe you have to change the format for the date default value. As I am using german version with date format 06-10-2003 you need to change it back to 2003/10/06)<br />
<br />
Rgds<br />
G?nter
averma
Hi Guenter,
Date picker field is already available with Actuate BIRT. You can download and give it a try:
http://www.birt-exchange.com/be/downloads/
Ashwini
AlexS
hi all, can u tell me how to implament "DatePcker" in BIRT
??????
Thank's
averma
Hi Alex,
If you are using Actuate BIRT it is already available to you. Define a parameter of type "Date" and when you run the report, parameter collection screen presents a date picker for the input field.
Ashwini
Servtec
Hi,
I've actually the same problem but I am searching for a possibility without fetching the date values out of the dataset. My case is as follows: I would like to select the start and end date (not out of the dataset) and dependend on these values I would like to have a parameter in a dropdown menu, showing e.g. ordernumbers which are (were placed) between the mentioned start and end date. So more or less the same like cascading parameter.
Maybe someone could help me with that...
Thanks & regards,
Markus