
/****** Object:  Table [dbo].[ApiLines]    Script Date: 06.09.2021 19:52:42 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[ApiLines](
	[Id] [int] IDENTITY(1,1) NOT NULL,
	[lineId] [int] NOT NULL,
	[ErpId] [int] NOT NULL,
	[lp] [int] NOT NULL,
	[documentId] [int] NOT NULL,
	[IdDocId] [int] NOT NULL,
	[itemId] [int] NOT NULL,
	[itemName] [nvarchar](max) NULL,
	[itemCode] [nvarchar](max) NULL,
	[itemDescription] [nvarchar](max) NULL,
	[itemPrice] [decimal](18, 2) NOT NULL,
	[itemOrgPrice] [decimal](18, 2) NOT NULL,
	[discount] [decimal](18, 2) NOT NULL,
	[quantity] [decimal](16, 4) NOT NULL,
	[value] [decimal](18, 2) NOT NULL,
	[itemEAN] [nvarchar](max) NULL,
	[itemUM] [nvarchar](max) NULL,
	[itemUM2] [nvarchar](max) NULL,
	[veryfiedQuantity] [decimal](16, 4) NOT NULL,
	[LocationName] [nvarchar](max) NULL,
	[Batch] [nvarchar](max) NULL,
	[BatchId] [int] NOT NULL,
	[BatchEAN] [nvarchar](max) NULL,
	[CategoryId] [int] NOT NULL,
	[CategoryName] [nvarchar](max) NULL,
	[CategoryName2] [nvarchar](max) NULL,
	[VendorId] [int] NOT NULL,
	[Status] [int] NOT NULL,
	[ItemStatus] [int] NOT NULL,
	[lineStatus] [nvarchar](max) NULL,
	[lineChance] [int] NOT NULL,
	[lineType] [nvarchar](max) NULL,
	[Netto] [decimal](18, 2) NOT NULL,
	[Brutto] [decimal](18, 2) NOT NULL,
	[TaxRate] [decimal](18, 2) NOT NULL,
	[TaxDesc] [nvarchar](max) NULL,
	[ReservationType] [int] NULL,
	[Direction] [int] NULL,
	[RepositoryId] [int] NULL,
 CONSTRAINT [PK_dbo.ApiLines] PRIMARY KEY CLUSTERED 
(
	[Id] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO


