* <code>OPEN factbook; CREATE INDEX fulltext</code>: Open database; create full-text index
* <code>OPEN factbook; INFO INDEX TOKEN</code>: Open database; show info on token index
* <code>SET ATTRINDEX true; SET ATTRINCLUDE id name; CREATE DB factbook.xml</code>: Enable attribute index; only index 'id' and 'name' attributes; create database
* <code>OPEN factbook; INFO INDEX TOKEN</code>: Open database; show info on token index
* <code>OPEN factbook; SET FTINDEX true; OPTIMIZE</code>: Open database; enable full-text indexing; optimize database
With XQuery, index structures can be created and dropped via [[Database Module#db:optimize|db:optimize]]: