1.1.1

Table Of Contents
12. By default, SQLFire replicates new tables that you create onto data store members. You can validate this
using the query:
sqlf> select tablename, datapolicy from sys.systables where
tablename='QUICKTABLE';
TABLENAME |DATAPOLICY
-----------------------------------------------------------------------------
QUICKTABLE |REPLICATE
1 row selected
13. Execute two SQL scripts to generate a schema that has both replicated and partitioned tables, and then load
the schema with data:
sqlf> run 'create_colocated_schema.sql';
sqlf> run 'loadTables.sql';
You see numerous messages as various SQL commands are executed. The rst script creates both replicated
and partitioned tables, as you can see using the query:
sqlf> select tablename, datapolicy from sys.systables where
tableschemaname='APP';
TABLENAME |DATAPOLICY
------------------------------------------------------------------------------
FLIGHTS_HISTORY |PARTITION
FLIGHTAVAILABILITY |PARTITION
FLIGHTS |PARTITION
MAPS |REPLICATE
CITIES |REPLICATE
COUNTRIES |REPLICATE
AIRLINES |REPLICATE
QUICKTABLE |REPLICATE
8 rows selected
14. To observe a benet of table partitioning, look at a query plan that involves one of the partitioned tables.
Use the EXPLAIN command with a query to generate a query execution plan:
sqlf> explain select * from flights;
The EXPLAIN command stores the query execution plan for the statement in STATEMENTPLANS system
table.
vFabric SQLFire User's Guide4