Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Row Level Security - CRXI Server 2

Status
Not open for further replies.

davida37

IS-IT--Management
May 10, 2006
113
GB
Hi,

I need to implement row level security. I need to be able to limit rows of data a user can see by their NTlogon.

I am using CRXI Server and the reports would be viewed via teh Infoview client. I am not familiar with Business Views but I am hoping this can do it? and if so please provide a
very basic explanation of how this is achieved.

Thanks
David
 
thanks. I didnt think so.

Is it then possible to pass currentCEUsername into a SQL Server 2000 stored procedure from CRXI? when a report is published on Crystal Server XI?

I tried this via a command in CRXI but didnt work. ie.
exec stored_proceedure currentCEUsername

Please advise.
thanks
 
Probably not.

You might write a custom page to do so though, I don't have an example of one, someone else might.

-k
 
Hi,
Since the CurrentCEUsername is only 'known' to Crystal, it cannot be passed in a Command Object ( as far as I know)..
The CR report will 'lookup' the CurrentCEUsername from the
CMS database and then filter the results of the query/command AFTER the data has been returned...
( It will, in effect, apply row-level restrictions on the returned data rows, so the user still only sees the allowed data..But, since all the data otherwise requested is returned for further filtering at the client end, performance may be slow)





[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
This would be a good temporary solution whilst I figure out business views etc..

Where and how do I do this filtering? Can I use an sql server 2000 SP to return a recordset then how do I then filter after the rs has been returned?

i.e the where clause

where CurrentCEUsername = salesperson

thanks in advance
david
 
Hi,
In the Report's Record Selection Formula section:
Code:
{command.salesperson} = CurrentCEUsername



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Thanks. Yes. Now time to get into the Business views which I'm not looking forward to!
 
You should be able to cheat this by placing the SP in a subreport and creating a formula of:

currentceusername in the main report and then joining the main report formula to the SP parameter.

-k
 
synapsevampire,

a bit of a belated thankyou - but this works great.

Thanks
 
Another way to do this if you are using NT or AD authentication on the database side and you have a table in the database with the login name, then it can be done using the login name stored in the database. I believe in sql server it is suser_sname().

For example.
where yourtable.loginname = suser_sname()

The downside is that on the crystal server this would need to be on-demand (a crystal folder with on the "view lastest instance" option).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top