That is really strange, I would try the following:
Make sure you are building a new widget with the new data item, you might want to make sure the new item has a different name from the original.
See if you can control the data type in the properties of your new item.
Possibly - use a native Oracle function to do the casting, maybe the to_date function?
------------------------------
Albert Valdez
albert@intelalytics.com------------------------------
Original Message:
Sent: Thu May 28, 2020 09:55 AM
From: Dagur Egonsson
Subject: Date slicer on dashboard
Hmmm...
...tried creating a calculated column in the data module using cast ({query item}, date) but the new calculated column is still of data type timestamp and the filter widget shows timestamp
...tried using the split functionality, splitting the date from the date part of the new calculated column but still I have the data type timestamp and no change to the filter widget
------------------------------
Dagur Egonsson
Original Message:
Sent: Tue May 26, 2020 08:13 PM
From: IAN HENDERSON
Subject: Date slicer on dashboard
Oracle date data types include the timestamp.
You can cast it to date using cast ({query item}, date) or use the split functionality.
------------------------------
IAN HENDERSON
Original Message:
Sent: Tue May 26, 2020 07:36 PM
From: Albert Valdez
Subject: Date slicer on dashboard
Dagur, I would cast the data item to Date in a calculation, you can definitely do that in the data module. I am not sure why Cognos is reading it as datetime, but this can happen for various reasons. The bottom line is that troubleshooting that issue vs. just casting the data type is likely not productive.
Hope this helps!
------------------------------
Albert Valdez
albert@intelalytics.com
Original Message:
Sent: Mon May 25, 2020 07:17 AM
From: Dagur Egonsson
Subject: Date slicer on dashboard
Thanks Brennan using the filter widget work ok.
However I am having two problems with this. The filter shows datetime but I would like it to be date only.
The field in the data module is Timestamp but on db side its Date (Oracle). The data module does not give the option of changing to date.
The other thing is that I would like to change the date format to dd.mm.yyyy but changing Format data... on the data module has no affect.
------------------------------
Dagur Egonsson
Original Message:
Sent: Wed May 20, 2020 09:01 AM
From: Brennan Fox
Subject: Date slicer on dashboard
Hi Dagur, thanks for your question.
In Cognos Analytics Dashboards you can achieve a similar outcome by using filter widgets. Here is how to create a filter widget.
If your data type is a 'date', the filter widget will provide a calendar picker for you to select a date range. If your data type is 'time', it will show a time picker to select a time range. And if your data type is 'dateTime', it will show a calendar picker and a time picker to select both a date and time range.
In Dashboards you can also 'brush' and 'slice' other visualizations on the same tab by selecting one or more data points on a visualization. Buddhi's suggestion of the Data player and List are examples of this 'brushing' and 'slicing'. As another example, if you have a Column visualization that has columns for each date, and you multi-select the columns you want (manually or use the Select tool to select multiple columns), then it will instantly 'brush' across the dashboard to highlight those dates any other visualization on your tab that is showing the same dates. Additionally, it will also 'slice' out data on other visualizations where the date data is not being used, and will show only the data that is related to the dates you selected on the Column visualization.
Hope this helps.
------------------------------
Brennan Fox
Original Message:
Sent: Tue May 19, 2020 11:04 AM
From: Dagur Egonsson
Subject: Date slicer on dashboard
In Power BI you can use a slicer visualization to filter on dates.
Is there anything similar in Cognos Analytics?
There is the possibility to add a filter, add the filter to canvas and filter from there but it is not the same.
------------------------------
Dagur Egonsson
------------------------------
#CognosAnalyticswithWatson