斯潘8
斯潘4
You've already been loading data into different alternatives or versions of the Smallworld Cambridge database using the Smallworld writer.In the previous sections,你更新了剑桥电力网。
GE Smallworld Reader还可以从不同的备选方案中读取数据,just set the Alternative parameter on the Smallworld reader in the workbench Navigator.此外,to reading all the selected objects from an alternative,or you can configure the reader to return only the deltas (changes) between alternatives (and/or checkpoints).如果要将smallworld虚拟机与另一个数据库同步,并且只导出增量更改,那么这非常有用。
以下示例要求小世界中的数据库操作article have been loaded successfully into your Smallworld database.If that didn't work,您可以使用预先配置了变更的FME替代方案。
在对一个小世界的替代方案进行了电网更新之后,you can examine just the differences (deltas) between the baseline and the alternative.此示例将导出这些差异以供检查。
1)添加smallworld阅读器
Open FME Workbench.Start with a Blank workspace on the Main tab of FME Workbench.
添加此读卡器:
Reader Format: | 小世界4/5 |
Reader Dataset: | 本地主机:30000 |
读者库德。系统: | OSGB-GPS-2015 |
Parameters > Service: | FMENOFACTORY |
参数>表列表: |
|
取消选中smallworld 4/5参数对话框中的“使用搜索信封”。
2)连接检查员
将Inspector Transformer连接到每个读卡器功能类型。
3) Run and Inspect
运行工作区。您将看到来自***顶部***选项的所有对象。您将看不到在上一个练习中对数据库所做的任何更改。
4)选择替代方案
在工作区导航器中,under the Smallworld reader,选择备选方案并设置:
5)运行和检查
运行工作区。You'll see all the objects from the ‘fme_updates' alternative.你应该看看电网,including the changes you made to the database in the previous exercise.
6) Export Changes
回到工作区导航器,under the Smallworld reader,select set the following reader parameters:
Export Changes from Baseline: | 是的 |
基线备选方案: | | |
Note the '|' or pipe character represents the ***top*** alternative.
or you can use:
Export Changes from Baseline: | 是的 |
基线备选方案: | | FME_更新 |
检查点: | 开始 |
“begin”检查点是添加任何更改之前fme_更新选项中的第一个检查点。
7) Run and Inspect
运行工作区。您将只看到“***顶部***”选项和“FME U更新”选项之间的差值。
注释:smallworld阅读器自动添加和设置 故障模式与后果分析属性,以便使用这些功能更新FME支持的其他数据库。
8) Save Workspace
保存工作区:smallworld7-完成.fmw
以这种方式导出增量更改可用于将smallworld vmds与Oracle、SQL Server或ESRI geodatabase同步。
smallworld阅读器允许您提取备选方案和检查点之间的差异。The reader also set the 'fme_db_operation' attribute to the appropriate value: INSERT,更新,删除。This makes it relatively straight forward to write to other databases and only add the changes - incremental updates.有关使用“fme_db_operation”进行增量更新的更多信息,请参见Tutorial: Updating Databases.下面是两个示例工作区:第一个“种子”数据库,第二种方法从smallworld中提取差异,并使用fme-db-u操作更新目标数据库。这些应该有助于您理解增量更新过程。
smallworld读卡器支持可用于选择数据子集的WHERE谓词。
In the Workbench Navigator pane,locate the parameters for the Smallworld reader.
设置这些参数以仅选择状态为“已接受”的电缆:
WHERE子句:[电力]状态为“已接受”的电缆
Export Changes from Baseline:不
运行工作区。检查输出。仅导出“已接受”的电缆。
Summary
本文说明如何通过比较当前替代方案与基线替代方案或检查点从SmallWorld数据库中提取增量。这将自动设置fme_db_operation属性,并允许您将smallworld vmds与另一个数据库同步。有关使用fme_db_操作的更多信息,请参阅文章Updating Databases.
您还了解了如何在Smallworld阅读器上包含简单的where谓词。
?2019安全亚搏在线软件公司|合法的