cancel
Showing results for 
Search instead for 
Did you mean: 

EVLCK in BPC 5.1

Former Member
0 Kudos

Hello!

It seems impossible to use the EVLCK function in a report so that a user can

see the workstatus of all entities even though the user hasn´t got the

access to the entities in the member access profile?

Does anyone have an idea how to work around this to create this kind of report? Beacause we want our user to change workstatus on their own entities and be able to see the worksstatus on all other entities.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Daniel,

I know that Joost Hoppenbrouwers recently did this in V5.

@JOOST; hope you can post the trigger code you are using.

Below some code I used in the 4.2 days, the difference with V5 is that each application had his own locking table now, so it needs some adjustments:

CREATE TRIGGER STATUSDUMMY ON dbo.tbllckfinance FOR INSERT, UPDATE, DELETE AS INSERT INTO tblStatusHistory SELECT a.category, a.entity, a.Status, a.Lastupdate, a.UpdateBy, a.Time, a.TimeName FROM tblStatus a WHERE a.Lastupdate not in (SELECT LastUpdate from tbllckfinancedummy)

Alwin

Edited by: Alwin Berkhout on Jul 4, 2008 2:22 PM

Former Member
0 Kudos

Yes here is the code I used to lock both finance and intercompany when I update the finance status:

-


--Trigger for Insert Queries

CREATE TRIGGER [dbo].[T_tblFinanceLock_Ins] ON [dbo].[tblFinanceLock]

FOR INSERT

AS

INSERT INTO tblIntercompanyLock (Category,Entity,Statuscode,LastUpdate,UpdateBy,[Time])

SELECT Category,Entity,Statuscode,LastUpdate,UpdateBy, [Time]

FROM inserted I

--Trigger for delete queries

CREATE TRIGGER [dbo].[T_tblFinanceLock_Del] ON [dbo].[tblFinanceLock]

FOR DELETE

AS

DELETE

FROM tblIntercompanyLock

FROM tblIntercompanyLock S INNER JOIN deleted D ON

S.Category = D.Category AND S.Entity = D.Entity AND S.[Time] = D.[Time]

-


-Joost

Former Member
0 Kudos

In addition to my previous post: of course the dimension names might be different in your application, based on which dimensions you use for the workstatus. In this case just rename the dimensions in the trigger code. If you take a look at the design of the tblfinancelock table first you will see which dimensions you need.

-Joost

Answers (2)

Answers (2)

Former Member
0 Kudos

It worked fine! Thank you!

Former Member
0 Kudos

Daniel,

Standard this is not possible because you need authorization to see an entity, to see the workstatus.

Possible solution might be:

- Create an extra cube with the same dimensionality

- set the security in this cube for the entity dimension so that everyone is allowed to see all entities

- create a trigger on the lock table of the original cube to update automatically the lock table of this new cube

Hope this helps,

Alwin

Former Member
0 Kudos

Forgot to mention in my last post the last step:

- you can now create an evlck formula to query the work status in this other cube, if you set up the trigger correct, the records must be exactly the same.

Alwin

Former Member
0 Kudos

Thanks! This solution may work for us, but how do I set up the trigger to move the locktable from from one application to an other, any suggestion?