Show Navigation | Hide Navigation
You are here:
Geoprocessing tool reference > Data Management toolbox > Table toolset > Tools

Change Privileges (Data Management) (ArcInfo and ArcEditor only)

Release 9.2
Last modified November 29, 2010
E-mail This Topic Printable Version Give Us Feedback

Print all topics in : "Tools"


Related Topics

Establishes or changes user access privileges to the input ArcSDE dataset, stand alone feature class, or table.


Usage tips

Command line syntax
An overview of the Command Line window
ChangePrivileges_management <in_dataset> <user> {AS_IS | GRANT | REVOKE} {AS_IS | GRANT | REVOKE }

Parameter Explanation Data Type
<in_dataset>

The dataset, feature class, or table whose access privileges will be changed.

Layer | Table View | Dataset
<user>

The database username whose privileges are being modified.

String
{AS_IS | GRANT | REVOKE}

Establishes the users View privileges.

  • AS_IS - No change to the users existing view privilege. If the user has view privileges they will continue to have view privileges. If the user doesn't have view privileges they will continue to not have view privileges. This is the default.
  • GRANT - Allows the user to view the Input dataset.
  • REVOKE - Removes all user privileges, including edit privileges. The user will not be able to view or edit the Input dataset.

String
{AS_IS | GRANT | REVOKE }

Establishes the users Edit privileges.

  • AS_IS - No change to the users existing edit privilege. If the user has edit privileges they will continue to have edit privileges. If the user doesn't have edit privileges they will continue to not have edit privileges. This is the default.
  • GRANT - Allows the user to edit the Input dataset. The database must be versioned, and the user must also have View privileges.
  • REVOKE - Removes the user's edit privileges. The user may still view the Input dataset.

String
Data types for geoprocessing tool parameters


Command line example

workspace "Database Connections/Connection to Redlands.sde"
ChangePrivileges c_williams.landuse j_smith GRANT GRANT

Scripting syntax
About getting started with writing geoprocessing scripts
ChangePrivileges_management (in_dataset, user, view, edit)

Parameter Explanation Data Type
in_dataset (Required)

The dataset, feature class, or table whose access privileges will be changed.

Layer | Table View | Dataset
user (Required)

The database username whose privileges are being modified.

String
view (Optional)

Establishes the users View privileges.

  • AS_IS - No change to the users existing view privilege. If the user has view privileges they will continue to have view privileges. If the user doesn't have view privileges they will continue to not have view privileges. This is the default.
  • GRANT - Allows the user to view the Input dataset.
  • REVOKE - Removes all user privileges, including edit privileges. The user will not be able to view or edit the Input dataset.

String
edit (Optional)

Establishes the users Edit privileges.

  • AS_IS - No change to the users existing edit privilege. If the user has edit privileges they will continue to have edit privileges. If the user doesn't have edit privileges they will continue to not have edit privileges. This is the default.
  • GRANT - Allows the user to edit the Input dataset. The database must be versioned, and the user must also have View privileges.
  • REVOKE - Removes the user's edit privileges. The user may still view the Input dataset.

String

Data types for geoprocessing tool parameters


Script example

# Purpose: Change user privileges on a dataset

# Create the Geoprocessor object
import arcgisscripting
gp = arcgisscripting.create()

try:
    # Set the workspace (to avoid having to type in the full path to the data every time)
    gp.Workspace = "Database Connections/Connection to Redlands.sde"

    # Process: Update user privileges
    gp.ChangePrivileges("c_williams.landuse", "j_smith", "AS_IS", "GRANT")

except:
    # If an error occurred while running a tool print the messages
    print gp.GetMessages()

Please visit the Feedback page to comment or give suggestions on ArcGIS Desktop Help.
Copyright © Environmental Systems Research Institute, Inc.