Beginners Guide to Database Updating and Deleting

10
CONNECT. TRANSFORM. AUTOMATE. Beginners Guide to Database Updating and Deleting

description

See more FME World Tour 2014 presentations at www.safe.com/recap2014

Transcript of Beginners Guide to Database Updating and Deleting

Page 1: Beginners Guide to Database Updating and Deleting

CONNECT. TRANSFORM. AUTOMATE.

Beginners Guide to Database Updating and Deleting

Page 2: Beginners Guide to Database Updating and Deleting

Writing to Databases - Inserts

Easy to INSERT data Automatically INSERTs new data Creates a table if it doesn’t exist Appends to an existing table Simple settings for:

Drop Table or Truncate Table

Page 3: Beginners Guide to Database Updating and Deleting

Writing to Databases - Updating/Deleting

Updating/Deleting existing data isn’t so easy Requires multiple parameter settings Uses format attributes and writer ‘modes’ Might involve multiple transformers Can take some effort to get working

Prerequisites to incremental updates… You need to know which features to

insert / update / delete !

Page 4: Beginners Guide to Database Updating and Deleting

New Transformers

DatabaseUpdater Features enter the transformer and it updates

existing features

DatabaseDeleter Feature(s) enter the transformer and it deletes

existing features.

Page 5: Beginners Guide to Database Updating and Deleting

Formats Supported

Google Fusion Access SQL Server Oracle PostgreSQL/Postgis SQL Lite Windows Azure

Page 6: Beginners Guide to Database Updating and Deleting

Parameters

Attributes to Join on

Where clause option

Columns to Update

Page 7: Beginners Guide to Database Updating and Deleting

Pros

Very easy to configure

Great for relatively simple updates: a few feature types a small number of fields

Great for deleting based on an attribute value

Page 8: Beginners Guide to Database Updating and Deleting

Cautions

No Geodatabase support

No Transactioning or Commit/Rollback handling

Not so useful for updating lots of attributes

Not appropriate for Dynamic Workflows

Page 9: Beginners Guide to Database Updating and Deleting

Other Approaches

Use feature based updates fme_db_operation fme_where

See the KnowledgeBase article: http://

fmepedia.safe.com/articles/How_To/Using-Feature-Based-Attributes-for-Database-updates

Page 10: Beginners Guide to Database Updating and Deleting

Thank You!

Questions?

For more information: [email protected] www.safe.com