Hi Abhilash
Your answer fit perfectly in the scenario I'm trying to implement.
I didn't know that filters can be implemented within a Data Foundation just like you suggested.
Although your suggestion was indeed very helpful on getting this doubt solved, I had to figure out some other issues which I'd like to point out, so that anyone having the same issue could have a more accurate solution.
I'm showing the next image which depicts the elements which I created on the Business View Manager tool
It is important to notice that the filter could be applied in the Business Element too, but I guess it all depends on specifically how you want to solve your own scenario.
Once I did this, I didn't get the correct results immediately, since my report kept displaying all the records regardless of the filter I just set up. Searching the web, I found this post:
http://www.tek-tips.com/viewthread.cfm?qid=1099357
So, besides creating the filter you still have to define that users have over it. Go to the filter definition in the Objects Explorer panel and right click on it.
Then select the users for which the filter should apply for:
After that, I could see the correct report output in my report, showing just the records the Current CEUser (the one running the report) has privileges to see:
Moreover, I created a List of Values within the Business View Manager, based on the same set of objects (Data Foundation, Data Element, Business View) in order to set a Prompt inside my report, so when it runs, the User can choose which data he'd like the report to display.
Then a Parameter must be created inside Crystal Reports , and then in the Select Expert Section, the actual filter based on this parameter can be done:
The Prompt, then, will only show data based on the data set he/she is allowed to see:
So the reports displays like this:
I just have to do a next step and see if passing this Parameter down to a Subreport,, would help me to complete the whole scenario I have to work with.
Meanwhile, thanks a lot for your help Abhilash.
Best regards