SQLColumnPrivileges
This feature is not supported on the Wolfram Cloud.

SQLColumnPrivileges[conn]
returns a table of access rights for the columns in an SQL connection.

SQLColumnPrivileges[conn,table]
returns a table pertaining to the columns in table.

SQLColumnPrivileges[conn,SQLTable[table]]
returns a table pertaining to the columns in table.

SQLColumnPrivileges[conn,{table,column}]
returns a table pertaining to the columns in table matching column.

SQLColumnPrivileges[conn,SQLColumn[{table,column}]]
returns a table pertaining to the columns in table matching column.

SQLColumnPrivileges[conn,SQLColumn[column]]
returns a table pertaining to the columns in any table matching column.

DetailsDetails

  • To use SQLColumnPrivileges, you first need to load DatabaseLink using Needs["DatabaseLink`"].
  • Table and column specifications may include SQL wildcards.
  • The following options can be given:
  • "Catalog"Nonedatabase catalog to use
    "Schema"Nonedatabase schema to use
    "ShowColumnHeadings"Falsewhether to return headings with the results

ExamplesExamplesopen allclose all

Basic Examples  (1)Basic Examples  (1)

In[1]:=
Click for copyable input

If you find that the examples in this section do not work as shown, you may need to install or restore the example database with the package, as described in Using the Example Databases.

Open a connection:

In[2]:=
Click for copyable input

Get pairs for a particular table:

In[3]:=
Click for copyable input
Out[3]=

Restrict results to a particular column:

In[4]:=
Click for copyable input
Out[4]=
In[5]:=
Click for copyable input