cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Custom Report for Operators

Hi,

I have created a custom report in FNMS UI. I am facing problem to customize the report according to the operators. I had gone trough a solution where someone has used ComputerByOperatorlogIn Function and that did work for me as well. 

Can anyone please guide me again, how to use it in my view.

 

Thanks,

Deb

(1) Solution

Hi,

Thanks for the response.

This was helpful. I just replaced the parameter as NULL and it worked :). As the NULL parameter automatically detects the logged in user.

SELECT * FROM ComputerByOperatorLogin(NULL)

 

View solution in original post

(3) Replies
bheadley
By Level 5 Flexeran
Level 5 Flexeran

If you are talking about a SQL View then I think that you could use something like this to retrieve the data using the logged in operator:

---------------

DECLARE @OperatorLogin NVARCHAR(256)

-- Retrieve the OperatorLogin value based on the Operator who is logged in to FNMS currently

SELECT @OperatorLogin = co.OperatorLogin
FROM CurrentOperator op
INNER JOIN ComplianceOperator co
ON op.ComplianceOperatorID = co.ComplianceOperatorID

SELECT * FROM ComputerByOperatorLogin(@OperatorLogin)

--------------------

I am not certain if this is what you are looking for or not. If not, please add any detail you can for where you have seen ComputerByOperatorLogin used previously.

Thanks,

Bill

 

 

Hi,

Thanks for the response.

This was helpful. I just replaced the parameter as NULL and it worked :). As the NULL parameter automatically detects the logged in user.

SELECT * FROM ComputerByOperatorLogin(NULL)

 

That was a very good catch! It does retrieve a ComplianceOperator based on the session context. This happens about 10 layers deep in a call to the table function 'TableGetSessionOperatorID' when the parameter for Operator login is set to NULL as you discovered. Thanks for finding this and for pointing it out as well. Good luck with custom report!