Changes

Jump to navigation Jump to search
200 bytes added ,  00:22, 2 February 2016
|
* {{Code|user:create('John', '7e$j#!1', 'admin')}} creates a new user 'John' with admin permissions.
* {{Code|user:create('Jack', 'top!secret', 'read', 'index*')}} creates a new user 'Jack' with no permissions, but write permissions for databases starting with the letters 'index'.
|-
| '''Errors'''
|-
| width='120' | '''Signatures'''
|{{Func|user:grant|$name as xs:string, $permission permissions as xs:string*|empty-sequence()}}<br/>{{Func|user:grant|$name as xs:string, $permissions as xs:string*, $patterns as xs:string*|empty-sequence()}}
|-
| '''Summary'''
|Grants the specified global or local {{Code|$permissionpermissions}} to a user with the specified {{Code|$name}}. If Local permissions are granted with non-empty glob {{Code|$patterns}} are specified, the permissions will only be applied to databases matching that pattern.
|-
| '''Examples'''
|
* {{Code|user:grant('John', 'create')}} grants create permissions to the user 'John'.
* {{Code|user:grant('John', ('read', 'write'), ('index*', 'unit*'))}} allows John to read all databases starting with the letters 'index', and to write to all databases starting with the letters 'unit'.
|-
| '''Errors'''
Bureaucrats, editor, reviewer, Administrators
13,550

edits

Navigation menu