1、流水号表结构
CREATE TABLE [dbo].[BASE_Sequence](
[SeqCode] [varchar](60) NOT NULL,
[Desc] [nvarchar](150) NULL,
[NowSeqValue] [nchar](10) NULL,
[CreateTime] [datetime] NULL,
[DateMax] [varchar](10) NULL,
[MaxVlaue] [bigint] NULL,
[CreateBy] [varchar](50) NULL,
[Length] [int] NULL,
[Status] [varchar](1) NULL,
[InitValue] [varchar](10) NULL,
[ResetType] [varchar](50) NULL,
[IsRunning] [char](1) NULL,
CONSTRAINT [PK_BASE_Sequence] PRIMARY KEY CLUSTERED
(
[SeqCode] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
GO
INSERT [dbo].[BASE_Sequence] ([SeqCode], [Desc], [NowSeqValue], [CreateTime], [DateMax], [MaxVlaue], [CreateBy], [Length], [Status], [InitValue], [ResetType], [IsRunning]) VALUES (N'AGV_ActivePushMaterial', N'AGV配送', N'4 ', CAST(N'2023-10-16T15:37:00.000' AS DateTime), N'20231016', 99999999, N'CX', 4, N'1', N'1', N'2', N'1')
GO
INSERT [dbo].[BASE_Sequence] ([SeqCode], [Desc], [NowSeqValue], [CreateTime], [DateMax], [MaxVlaue], [CreateBy], [Length], [Status], [InitValue], [ResetType], [IsRunning]) VALUES (N'Operation_Siemens_S_700803909', N'工序目录(工序池)Nid流水号', N'575 ', CAST(N'2023-09-06T16:11:27.593' AS DateTime), N'20231218', 999999, N'Liz', 6, N'1', N'1', N'1', N'1')
GO
INSERT [dbo].[BASE_Sequence] ([SeqCode], [Desc], [NowSeqValue], [CreateTime], [DateMax], [MaxVlaue], [CreateBy], [Length], [Status], [InitValue], [ResetType], [IsRunning]) VALUES (N'PR_ReworkTask', N'返工任务单流水号', N'9 ', CAST(N'2023-10-07T11:19:00.000' AS DateTime), N'20231225', 99999999, N'CX', 4, N'1', N'1', N'4', N'1')
GO
INSERT [dbo].[BASE_Sequence] ([SeqCode], [Desc], [NowSeqValue], [CreateTime], [DateMax], [MaxVlaue], [CreateBy], [Length], [Status], [InitValue], [ResetType], [IsRunning]) VALUES (N'PR_WorkOrder_WorkingHours', N'工时上报流水号', N'14 ', CAST(N'2023-09-20T11:34:00.00