|
|
using System;
|
|
|
using System.Collections.Generic;
|
|
|
using System.Linq;
|
|
|
using System.Text;
|
|
|
using FireBirdUtil.DataTypes;
|
|
|
using FireBirdUtil.SqlHelpers;
|
|
|
|
|
|
namespace WeighBusiness.BO.CreateTables
|
|
|
{
|
|
|
class CreateSynchronousLogTable : CreateBaseTable
|
|
|
{
|
|
|
public CreateSynchronousLogTable(string tableName) : base(tableName) { }
|
|
|
|
|
|
public override void AddFields(CreateTableHelper cth)
|
|
|
{
|
|
|
cth.AddField(new FieldInfo() { FieldName = "BillTypeID", FieldType = FBType.SmallInt, IsNotNull = true });
|
|
|
cth.AddField(new FieldInfo() { FieldName = "TerminalBillID", FieldType = FBType.Integer, IsNotNull = true });
|
|
|
cth.AddField(new FieldInfo() { FieldName = "RemoteBillID", FieldType = FBType.Integer, IsNotNull = true });
|
|
|
cth.AddField(new FieldInfo() { FieldName = "SynchronousMessage", FieldType = FBType.Varchar, FieldTypeParams = "(2000)" });
|
|
|
base.AddFields(cth);
|
|
|
}
|
|
|
//Sql server:
|
|
|
// private static string Sql_CreateSynchronousLogTable
|
|
|
// {
|
|
|
// get
|
|
|
// {
|
|
|
// return string.Format(@"
|
|
|
//CREATE TABLE [dbo].[{0}](
|
|
|
// [BillTypeID] [smallint] NOT NULL,
|
|
|
// [TerminalBillID] [bigint] NOT NULL,
|
|
|
// [RemoteBillID] [bigint] NOT NULL,
|
|
|
// [SynchronousMessage] [nvarchar](2000) NULL,
|
|
|
// [ID] [bigint] IDENTITY(1,1) NOT NULL,
|
|
|
//) ON [PRIMARY]
|
|
|
//", TableName.同步日志);
|
|
|
// }
|
|
|
// }
|
|
|
}
|
|
|
}
|