37.13 SDO_WFS_PROCESS.RegisterMTableView
Format
SDO_WFS_PROCESS.RegisterMTableView( ftNsUrl IN VARCHAR2, ftName IN VARCHAR2, viewTableList IN MDSYS.STRINGLIST, viewTablePkeyColList IN MDSYS.STRINGLIST, tablePkeyColList IN MDSYS.STRINGLIST);
or
SDO_WFS_PROCESS.RegisterMTableView( ftNsUrl IN VARCHAR2, ftName IN VARCHAR2, viewTableList IN MDSYS.STRINGLIST, viewTablePkeyColList IN MDSYS.STRINGLIST, formattedViewTableColList IN MDSYS.STRINGLISTLIST, tablePkeyColList IN MDSYS.STRINGLIST);
Description
Enables the publishing of content from a multitable view as a feature instance.
Parameters
- ftNsUrl
-
Uniform resource locator (URL) of the namespace for the feature type.
- ftName
-
Name of the feature type.
- viewTableList
-
List of tables in the view. To specify table names, use the MDSYS.STRINGLIST type constructor as in the following example:
MDSYS.STRINGLIST('MYUSER.ROADS', 'MYUSER.ROADS_DESC')
- viewTablePkeyColList
-
List of view columns that correspond to the primary key columns in the tables in the view, in the order that corresponds to the order of the tables in
viewTableList
. To specify column names, use the MDSYS.STRINGLIST type constructor as in the following example:MDSYS.STRINGLIST('ROAD_ID', 'ROAD_ID')
, where both the ROADS and ROAD_DESC table have ROAD_ID as primary key.If the view has columns that correspond to table columns in a multicolumn primary key, use a semicolon to separate the columns in the primary key. For example:
'COL1;COL2'
- formattedViewTableColList
-
A list of string formatted table primary key columns that correspond to the string formatted primary key columns in the view, in the order that corresponds to the order of the tables in
viewTableList
. To specify column names, use the MDSYS.STRINGLISTLIST type constructor as in the following example:MDSYS.STRINGLISTLIST(MDSYS.STRINGLIST('to_char(ROAD_ID)'), MDSYS.STRINGLIST('to_char(ROAD_ID)'))
The list of string formatted primary key columns for each table should be specified in the same order as the primary key columns for each table specified in
tablePkeyColList
parameter. - tablePkeyColList
-
List of the primary key columns in the tables, in the order that corresponds to the order of the tables in
viewTableList
. For each table the primary key columns should be specified in the order that correspond to the key columns in the view as specified inviewTablePkeyColList
parameter. To specify column names, use the MDSYS.STRINGLIST type constructor as in the following example:MDSYS.STRINGLIST('ROAD_ID', 'ROAD_ID')
If a table has a multicolumn primary key, use a semicolon to separate the columns in the primary key. For example :
'COL1;COL2'
Usage Notes
If you need to publish content from a multitable view as a feature instance, you must call this procedure after calling the SDO_WFS_PROCESS.PublishFeatureType procedure.
To disable the publishing of content from a multitable view as a feature instance, use the SDO_WFS_PROCESS.UnRegisterMTableView procedure.
For information about support for Web Feature Services, see Web Feature Service (WFS) Support.
Examples
The following example creates two feature tables, creates a view based on these tables. publishes a feature type, and registers the multitable view to enable the publishing of content from the view.
CREATE TABLE cola_markets_cs ( mkt_id NUMBER PRIMARY KEY, name VARCHAR2(32), shape MDSYS.SDO_GEOMETRY); CREATE TABLE cola_markets_cs_details ( mkt_id NUMBER PRIMARY KEY, description VARCHAR2(400)); create view cola_markets_view as select t1.mkt_id, t1.name, t1.shape, t2.description from cola_markets_cs t1, cola_markets_cs_details t2 where t1.mkt_id = t2.mkt_id; DECLARE cm MDSYS.StringList := MDSYS.StringList('PolygonMemberType'); BEGIN SDO_WFS_PROCESS.publishFeatureType( 'WFS_USER.COLA_MARKETS_VIEW', 'http://www.example.com/myns', 'COLA', 'myns', xmltype(bfilename('WFSUSERDIR', 'featuredesct.xml'), nls_charset_id('AL32UTF8')), null, 'MKT_ID', cm, 'SHAPE', null, null, null, null); END; / BEGIN SDO_WFS_PROCESS.registerMTableView('http://www.example.com/myns', 'COLA', mdsys.StringList('WFS_USER.COLA_MARKETS_CS', 'WFS_USER.COLA_MARKETS_CS_DETAILS'), mdsys.StringList('MKT_ID', 'MKT_ID'), -- view keys per table mdsys.StringList('MKT_ID', 'MKT_ID'));-- corresponding table keys END; /
Parent topic: SDO_WFS_PROCESS Package (WFS Processing)