Table of Contents

Class SchemaVersion

Namespace
Tripous.Data
Assembly
Tripous.Data.dll

Represents a version of a database schema.

public class SchemaVersion
Inheritance
SchemaVersion
Inherited Members
Extension Methods

Constructors

SchemaVersion()

Constructor

public SchemaVersion()

Properties

StatementsAfter

A list of Sql statements to be executed after this schema execution

public List<string> StatementsAfter { get; set; }

Property Value

List<string>

StatementsBefore

A list of Sql statements to be executed before this schema execution

public List<string> StatementsBefore { get; set; }

Property Value

List<string>

Tables

A list of table items.

public List<SchemaItem> Tables { get; set; }

Property Value

List<SchemaItem>

Version

Gets or sets the version of the schema.

public int Version { get; set; }

Property Value

int

Views

A list of view items.

public List<SchemaItem> Views { get; set; }

Property Value

List<SchemaItem>

Methods

AddStatementAfter(string)

Adds a statement

public void AddStatementAfter(string SqlText)

Parameters

SqlText string

AddStatementBefore(string)

Adds a statement

public void AddStatementBefore(string SqlText)

Parameters

SqlText string

AddTable(string)

Adds a table

public void AddTable(string SqlText)

Parameters

SqlText string

AddView(string, string)

Adds a view

public void AddView(string Name, string SqlText)

Parameters

Name string
SqlText string

Execute(DbConnectionInfo)

Executes the schema. If no connection info is specified then the default connection is used.

CAUTION: This method does NOT record version number in the Db Ini.

public void Execute(DbConnectionInfo ConnectionInfo = null)

Parameters

ConnectionInfo DbConnectionInfo

ToString()

Override

public override string ToString()

Returns

string