Desktop version

Main > Forum > 1C:Enterprise Platform > 1C:Enterprise – Business applications platform > Scheduled Job Error calling context method: insufficient rights to use table

Forum

Search UsersRules
Scheduled Job Error calling context method: insufficient rights to use table
#1
Active user
Points:: 0
Joined:: Feb 9, 2016

Hi,

I created a scheduled job, assigned a method to run. Once run, I can see in the events log that it had execution error:
{CommonModule.MyModule.Module(31)}: Error calling context method (Execute)
reason: Insufficient rights to use table "Document.MyDocument"

Know that, in the method I'm running a query accessing myDocument and perform some updates.
My question is

what is the default role used by the scheduled tables? where can I grant it access to the documents that it needs to access.

Any help how to fix this issue?

thanks

Profile
#2
Active user
Points:: 0
Joined:: Feb 9, 2016

aparently, you need to use:

SetPrivilegedMode ( true );

before code

and

SetPrivilegedMode ( false );

after code, and it will do the trick

Profile
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)



© 1C LLC. All rights reserved
1C Company respects the privacy of our customers and visitors
to our Web-site.