Skip to content

TQueryTableExtensions_OverrideTable_ux07CAUjqhPGv+UWwptSKQ

Jacob Spitzer edited this page Aug 28, 2022 · 2 revisions

TQueryTableExtensions.OverrideTable<Table>(DbEc<Table>) Method

Overrides a Table on the server database, based on the code table properties. Caution! This action will DELETE the current table on the Server with all the records, and then create a new blank Table with the current code properties. Supported attributes are: [Key] for Primary Key, [AutoIncrement] for Auto Increment property, [Required] for Not Null property.

public static int OverrideTable<Table>(this DbEasyConnect.DbEc<Table> tQuery);

Type parameters

Table
The type of the records of table class. need to be a class with the [Table("")] attribute.

Parameters

tQuery DbEasyConnect.DbEc<Table>
An DbEc<T> to perform the Create Table command.

Returns

System.Int32

Clone this wiki locally