Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics AX (Archived)

Identifying source of a journal block

Posted on by 70

Working with AX 2012 R3, we've seen instances of the Cash and bank managementJournalsBank reconciliation form showing journals as In use with the Blocking tab identifying the Used by user as a user who has no permissions in the Cash and bank management module.  Those users who need to access the journal have been able to clear the block, a conclusion reached elsewhere, but I'm curious if anyone else has seen this behaviour, and if so, what you've done about it.  I could turn on database auditing for \Tables\BankReconciliationHeader\Fields\InUseBy, or go further & put an insert/update trigger event handler on the field to custom-capture a stack trace, but that feels like it might be overkill.

I can see the In use checkbox displays a method on the form datasource that calls \Classes\BankReconciliationHeaderFormView\inUseBlockReconciliation, which calls \Classes\BankReconciliationHeaderViewModel\dsReconciliationMethodInUseBlock, ultimately referencing \Tables\BankReconciliationHeader\SessionId, so I can see when the relevant user session started or ended, which allows us to have more confidence that the blocking user hasn't had their roles changed recently, so their ability to access journals hasn't changed since they apparently blocked the journal.  If it wasn't for the fact that both the SessionId and InUseBy fields live directly on the header record, I would wonder whether re-use of a session ID could lead to the Blocked by field showing the wrong user, but I don't think that theory holds water.

Any thoughts welcome. 

*This post is locked for comments

  • RichHims Profile Picture
    RichHims 70 on at
    RE: Identifying source of a journal block

    André,

    Thanks for that.  I ruled out that idea on the basis that the table field InUseBy name & data type suggests it will hold the user ID of the user who has the journal in use, but you've made me revisit & I see that the form datasource method populates the user-visible control using the SessionID.  Hence, the InUseBy field appears somewhat redundant...  Appreciate you completing the picture where my incomplete knowledge led me to discard the 'obvious' stale pointer theory.

  • Verified answer
    André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 291,280 Super User 2024 Season 2 on at
    RE: Identifying source of a journal block

    Hi RichHims,

    The SessionId field can indeed cause a wrong user name shown as person who blocks the journal. This can be caused if the session was killed by the user or the system. If then another new user will get the same session ID, it will find this user instead of the one who had the journal in use before.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans