Skip to content
schambers edited this page Sep 14, 2010 · 27 revisions

The FM fluent api allows you to create tables, columns, indexes and (nearly) every construct you need to manipulate your database structure.

Behind the scenes, the fluent api populates a semantic model that FM uses to analyze and apply migrations in batch. The fluent api that is available in your Migration class starts with five main root expressions as follows:

Create Expression
Allows you to create a table, column, index, foreign key and schema.

Delete Expression
Allows you to delete a table, column, foreign key and schema.

Execute Expression
Allows you to execute a block of sql, or a script by name (ie. myscript.sql)

Insert Expression
Allows you to insert a row into a table using an anonymous type for the rows contents

Rename Expression
Allows you to rename a column or table.

Migration Runners explains how to run your migrations to apply changes to your database

Clone this wiki locally