CREATE EXISTING TABLE 文を実行する前に、リモートテーブルのカラムのリストを取得すると便利な場合があります。sp_remote_columns システムプロシージャーは、リモートテーブルにあるカラムのリストとそのデータ型の説明を生成します。sp_remote_columns システムプロシージャーの構文は次のとおりです。
sp_remote_columns servername, tablename [, owner ] [, database] |
テーブル名、所有者、またはデータベース名を指定すると、カラムのリストはその指定に当てはまるものだけに限定されます。
たとえば、asetest という名前の Adaptive Server Enterprise サーバーの production データベースにある sysobjects テーブルのカラムのリストを取得するには、次のように指定します。
CALL sp_remote_columns ('asetest, 'sysobjects', null, 'production'); |
![]() |
DocCommentXchange で意見交換できます
|
Copyright © 2012, iAnywhere Solutions, Inc. - SQL Anywhere 12.0.1 |