BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
user34567
Obsidian | Level 7

Hi all,

I would like to connect a (year) date filter to multiple dates in the same datasource. When I map the data in the "Object links" (Actions menu) I can only map the filter to one date instead of multiple.

 

For instance:

When in the year filter "Date_1" 2022 is selected, 2022 should also be selected for Date_2, Date_3 and Date_4 that are being used in the report. All dates are from the same data source.

 

Do I need to create a parameter and how should I do this?

 

Many thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
Sam_SAS
SAS Employee

Hello,

 

A filter action coming from a regular graph or table object will always filter on the specific data crossing that you selected.

 

For example, if you have a grouped bar chart of Sales * Month grouped by Region and you click the South bar for JAN2023, then the filter will be (REGION=South AND Month = JAN2023)

 

If you want to make a filter that is based on a parameter, you will need to:

1. Create a control such as a drop-down list or a button bar.

2. Assign a parameter to the control.

3. Create an advanced filter on the objects that you want to be affected by the parameter value. If you want this to be applied to multiple date columns, you can make a filter like 

 

('Date'n = 'Parameter'p) OR ('Date2'n = 'Parameter'p)

 

 

You can add additional OR statements to cover 4 date columns if you want.

 

Let us know if that helps,

Sam

View solution in original post

2 REPLIES 2
Sam_SAS
SAS Employee

Hello,

 

A filter action coming from a regular graph or table object will always filter on the specific data crossing that you selected.

 

For example, if you have a grouped bar chart of Sales * Month grouped by Region and you click the South bar for JAN2023, then the filter will be (REGION=South AND Month = JAN2023)

 

If you want to make a filter that is based on a parameter, you will need to:

1. Create a control such as a drop-down list or a button bar.

2. Assign a parameter to the control.

3. Create an advanced filter on the objects that you want to be affected by the parameter value. If you want this to be applied to multiple date columns, you can make a filter like 

 

('Date'n = 'Parameter'p) OR ('Date2'n = 'Parameter'p)

 

 

You can add additional OR statements to cover 4 date columns if you want.

 

Let us know if that helps,

Sam

user34567
Obsidian | Level 7
Hi Sam, This was very helpful, it finally works now. Many thanks!!

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
Tips for filtering data sources in SAS Visual Analytics

See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 501 views
  • 1 like
  • 2 in conversation