Class SqlScriptSaveOptions
Namespace: Aspose.Cells.Saving
Assembly: Aspose.Cells.dll (25.2.0)
Represents the options of saving sql.
public class SqlScriptSaveOptions : SaveOptions
Inheritance
object ← SaveOptions ← SqlScriptSaveOptions
Inherited Members
SaveOptions.m_SaveFormat, SaveOptions.SaveFormat, SaveOptions.ClearData, SaveOptions.CachedFileFolder, SaveOptions.ValidateMergedAreas, SaveOptions.MergeAreas, SaveOptions.CreateDirectory, SaveOptions.SortNames, SaveOptions.SortExternalNames, SaveOptions.RefreshChartCache, SaveOptions.WarningCallback, SaveOptions.CheckExcelRestriction, SaveOptions.UpdateSmartArt, SaveOptions.EncryptDocumentProperties, object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Constructors
SqlScriptSaveOptions()
Creates options for saving sql file.
public SqlScriptSaveOptions()
Properties
AddBlankLineBetweenRows
Insert blank line between each data.
public bool AddBlankLineBetweenRows { get; set; }
Property Value
Remarks
If Aspose.Cells.Saving.SqlScriptSaveOptions.Separator is ‘\n’ , it’s better to set this property as true to increase readability.
CheckAllDataForColumnType
Check all data to find columns’ data type.
public bool CheckAllDataForColumnType { get; set; }
Property Value
Remarks
The default value is false, we only check the first row for performance. If this property is true and the columns contains mixed value type, the columns’ type will be text.
CheckIfTableExists
Check if the table name exists before creating
public bool CheckIfTableExists { get; set; }
Property Value
ColumnTypeMap
Gets and sets the map of column type for different database.
public SqlScriptColumnTypeMap ColumnTypeMap { get; set; }
Property Value
CreateTable
Indicates whether exporting sql of creating table.
public bool CreateTable { get; set; }
Property Value
ExportArea
Gets or sets the exporting range.
public CellArea ExportArea { get; set; }
Property Value
ExportAsString
Indicates whether exporting all data as string value.
public bool ExportAsString { get; set; }
Property Value
HasHeaderRow
Indicates whether the range contains header row.
public bool HasHeaderRow { get; set; }
Property Value
IdName
Gets and sets the name of id column.
public string IdName { get; set; }
Property Value
Remarks
If this property is set , a column will be inserted with automatical increment int value.
OperatorType
Gets and sets the operator type of sql.
public SqlScriptOperatorType OperatorType { get; set; }
Property Value
PrimaryKey
Represents which column is primary key of the data table.
public int PrimaryKey { get; set; }
Property Value
Separator
Gets and sets character separator of sql script.
public char Separator { get; set; }
Property Value
Remarks
Only can be ’ ’ or ‘\n’. If the
SheetIndexes
Represents the indexes of exported sheets.
public int[] SheetIndexes { get; set; }
Property Value
int[]
StartId
Gets and sets the start id.
public int StartId { get; set; }
Property Value
Remarks
Only works when Aspose.Cells.Saving.SqlScriptSaveOptions.IdName is set.
TableName
Gets and sets the table name.
public string TableName { get; set; }