public function buildCreateTable(Query $query) {
        $schema = $query->getSchema();

        if (!$schema) {
            throw new InvalidSchemaException('Table creation requires a valid schema object');
        }

        return $this->renderStatement(Query::CREATE_TABLE, [
            'table' => $this->formatTable($schema->getTable()),
            'columns' => $this->formatColumns($schema),
            'keys' => $this->formatTableKeys($schema),
            'options' => $this->formatTableOptions($schema->getOptions())
        ] + $this->formatAttributes($query->getAttributes()));
    }