Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - SQL Reference » System Procedures » System procedures

sp_remote_primary_keys system procedure Next Page

sp_remote_tables system procedure

Returns a list of the tables on a server.

The server must be defined with the CREATE SERVER statement to use this system procedure.


[, @table_name
[, @table_owner
[, @table_qualifier
[, @with_table_type ] ] ] ]

Result set
Column nameData typeDescription
database CHAR(128)The name of the remote database.
ownerCHAR(128)The name of the remote database owner.
table-nameCHAR(128)The remote table.
table-typeCHAR(128)Specifies the table type. The value of this field depends on the type of remote server. For example, TABLE, VIEW, SYS, and GBL TEMP are possible values.

It may be helpful when you are configuring your database server to get a list of the remote tables available on a particular server. This procedure returns a list of the tables on a server.

The procedure accepts five parameters. If a table, owner, or database name is given, the list of tables will be limited to only those that match the arguments.

Standards and compatibility


Side effects


See also

To get a list of all of the Microsoft Excel worksheets available from an ODBC data source referenced by a server named excel:

CALL sp_remote_tables( 'excel' );

To get a list of all of the tables owned by fred in the production database in an Adaptive Server Enterprise server named asetest:

CALL sp_remote_tables( 'asetest', null, 'fred', 'production' );