CREATE TABLE [import].[Sales_Header] (
   [timestamp] [timestamp] NOT NULL,
   [Document Type] [int] NOT NULL,
   [No_] [varchar](20) NOT NULL,
   [Sell-to Customer No_] [varchar](20) NOT NULL,
   [Bill-to Customer No_] [varchar](20) NOT NULL,
   [Bill-to Name] [varchar](50) NOT NULL,
   [Bill-to Name 2] [varchar](50) NOT NULL,
   [Bill-to Address] [varchar](50) NOT NULL,
   [Bill-to Address 2] [varchar](50) NOT NULL,
   [Bill-to City] [varchar](30) NOT NULL,
   [Bill-to Contact] [varchar](30) NOT NULL,
   [Your Reference] [varchar](30) NOT NULL,
   [Ship-to Code] [varchar](10) NOT NULL,
   [Ship-to Name] [varchar](50) NOT NULL,
   [Ship-to Name 2] [varchar](50) NOT NULL,
   [Ship-to Address] [varchar](50) NOT NULL,
   [Ship-to Address 2] [varchar](50) NOT NULL,
   [Ship-to City] [varchar](30) NOT NULL,
   [Ship-to Contact] [varchar](30) NOT NULL,
   [Order Date] [datetime] NOT NULL,
   [Posting Date] [datetime] NOT NULL,
   [Shipment Date] [datetime] NOT NULL,
   [Posting Description] [varchar](50) NOT NULL,
   [Payment Terms Code] [varchar](10) NOT NULL,
   [Due Date] [datetime] NOT NULL,
   [Payment Discount %] [decimal](38,20) NOT NULL,
   [Pmt_ Discount Date] [datetime] NOT NULL,
   [Shipment Method Code] [varchar](10) NOT NULL,
   [Location Code] [varchar](10) NOT NULL,
   [Department Code] [varchar](10) NOT NULL,
   [Make Code] [varchar](10) NOT NULL,
   [Customer Posting Group] [varchar](10) NOT NULL,
   [Currency Code] [varchar](10) NOT NULL,
   [Currency Factor] [decimal](38,20) NOT NULL,
   [Price Group Code] [varchar](10) NOT NULL,
   [Prices Including VAT] [tinyint] NOT NULL,
   [Allow Quantity Disc_] [tinyint] NOT NULL,
   [Invoice Disc_ Code] [varchar](20) NOT NULL,
   [Cust__Item Disc_ Gr_] [varchar](10) NOT NULL,
   [Language Code] [varchar](10) NOT NULL,
   [Salesperson Code] [varchar](10) NOT NULL,
   [Order Class] [varchar](10) NOT NULL,
   [No_ Printed] [int] NOT NULL,
   [On Hold] [varchar](3) NOT NULL,
   [Applies-to Doc_ Type] [int] NOT NULL,
   [Applies-to Doc_ No_] [varchar](20) NOT NULL,
   [Bal_ Account No_] [varchar](20) NOT NULL,
   [Job No_] [varchar](20) NOT NULL,
   [Ship] [tinyint] NOT NULL,
   [Invoice] [tinyint] NOT NULL,
   [Shipping No_] [varchar](20) NOT NULL,
   [Posting No_] [varchar](20) NOT NULL,
   [Last Shipping No_] [varchar](20) NOT NULL,
   [Last Posting No_] [varchar](20) NOT NULL,
   [VAT Registration No_] [varchar](20) NOT NULL,
   [Combine Shipments] [tinyint] NOT NULL,
   [Reason Code] [varchar](10) NOT NULL,
   [Gen_ Bus_ Posting Group] [varchar](10) NOT NULL,
   [EU 3-Party Trade] [tinyint] NOT NULL,
   [Transaction Type] [varchar](10) NOT NULL,
   [Transport Method] [varchar](10) NOT NULL,
   [VAT Country Code] [varchar](10) NOT NULL,
   [Sell-to Customer Name] [varchar](50) NOT NULL,
   [Sell-to Customer Name 2] [varchar](50) NOT NULL,
   [Sell-to Address] [varchar](50) NOT NULL,
   [Sell-to Address 2] [varchar](50) NOT NULL,
   [Sell-to City] [varchar](30) NOT NULL,
   [Sell-to Contact] [varchar](30) NOT NULL,
   [Bill-to Post Code] [varchar](20) NOT NULL,
   [Bill-to County] [varchar](30) NOT NULL,
   [Bill-to Country Code] [varchar](10) NOT NULL,
   [Sell-to Post Code] [varchar](20) NOT NULL,
   [Sell-to County] [varchar](30) NOT NULL,
   [Sell-to Country Code] [varchar](10) NOT NULL,
   [Ship-to Post Code] [varchar](20) NOT NULL,
   [Ship-to County] [varchar](30) NOT NULL,
   [Ship-to Country Code] [varchar](10) NOT NULL,
   [Bal_ Account Type] [int] NOT NULL,
   [Exit Point] [varchar](10) NOT NULL,
   [Correction] [tinyint] NOT NULL,
   [Document Date] [datetime] NOT NULL,
   [External Document No_] [varchar](20) NOT NULL,
   [Area] [varchar](10) NOT NULL,
   [Transaction Specification] [varchar](10) NOT NULL,
   [Payment Method Code] [varchar](10) NOT NULL,
   [Shipping Agent Code] [varchar](10) NOT NULL,
   [Package Tracking No_] [varchar](30) NOT NULL,
   [No_ Series] [varchar](10) NOT NULL,
   [Posting No_ Series] [varchar](10) NOT NULL,
   [Shipping No_ Series] [varchar](10) NOT NULL,
   [Tax Area Code] [varchar](20) NOT NULL,
   [Tax Liable] [tinyint] NOT NULL,
   [VAT Bus_ Posting Group] [varchar](10) NOT NULL,
   [Reserve] [int] NOT NULL,
   [Applies-to ID] [varchar](20) NOT NULL,
   [VAT Base Discount %] [decimal](38,20) NOT NULL,
   [Order Type] [int] NOT NULL,
   [Customer Confirmation Date] [datetime] NOT NULL,
   [Price Freeze Until] [datetime] NOT NULL,
   [Service Order No_ 2] [varchar](20) NOT NULL,
   [Item Sales Price Group] [varchar](10) NOT NULL,
   [Show Discount] [tinyint] NOT NULL,
   [Purch_ Order Type] [varchar](10) NOT NULL,
   [Inv_ Discount %] [decimal](38,20) NOT NULL,
   [Sell-to Salutation Code] [varchar](10) NOT NULL,
   [Bill-to Salutation Code] [varchar](10) NOT NULL,
   [Ship-to Addr_ Salutation Code] [varchar](10) NOT NULL,
   [Vehicle Sales Price Group] [varchar](10) NOT NULL,
   [Option Sales Price Group] [varchar](10) NOT NULL,
   [Copy Header Text to Next Doc_] [tinyint] NOT NULL,
   [Copy Footer Text to Next Doc_] [tinyint] NOT NULL,
   [Customer Group Code] [varchar](10) NOT NULL,
   [Cockpit Entry No_] [int] NOT NULL,
   [Transfer Method] [int] NOT NULL,
   [Cockpit Cr_ Memo Version No_] [varchar](20) NOT NULL,
   [Status Code] [varchar](20) NOT NULL,
   [First Shipment Date] [datetime] NOT NULL,
   [Last Shipment Date] [datetime] NOT NULL,
   [Main Shipment Date] [datetime] NOT NULL,
   [Print] [tinyint] NOT NULL,
   [Branch Code] [varchar](10) NOT NULL,
   [Use Inventory Buffer Quantity] [tinyint] NOT NULL,
   [Vehicle Unit Price Date] [datetime] NOT NULL,
   [Cash Payment] [tinyint] NOT NULL,
   [Cash Payment Document Type] [int] NOT NULL,
   [Disable for Requisition] [tinyint] NOT NULL,
   [Req_ Wksh_ Template Name] [varchar](20) NOT NULL,
   [Requisition Wksh_ Name] [varchar](20) NOT NULL,
   [Customer Contact Program] [tinyint] NOT NULL,
   [Mobile Service] [tinyint] NOT NULL,
   [Bulkcust_ Business] [tinyint] NOT NULL,
   [Bulk Customer No_] [varchar](30) NOT NULL,
   [Bulkcust_ Gen_ Bus_ Post_ Grp] [varchar](10) NOT NULL,
   [Bulkcust_ VAT Bus_ Post_ Group] [varchar](10) NOT NULL,
   [No_ of Bulk Customer] [varchar](10) NOT NULL,
   [Bulkcust_Veh_ Sales Price Grp] [varchar](10) NOT NULL,
   [Bulkcust_ Opt_ Sales Price Grp] [varchar](10) NOT NULL,
   [Bulkcust_ Item Sales Price Grp] [varchar](10) NOT NULL,
   [SA3 Quotation ID] [int] NOT NULL,
   [SA3 Contract No_] [int] NOT NULL,
   [SA3 Order No_] [int] NOT NULL,
   [VIN] [varchar](20) NOT NULL,
   [License No_] [varchar](11) NOT NULL,
   [Mileage] [decimal](38,20) NOT NULL,
   [Model Code] [varchar](20) NOT NULL,
   [Model No_] [varchar](20) NOT NULL,
   [Prod_ Year] [datetime] NOT NULL,
   [Model] [varchar](50) NOT NULL,
   [Type] [varchar](50) NOT NULL,
   [Initial Registration] [datetime] NOT NULL,
   [Engine Code] [varchar](10) NOT NULL,
   [Engine No_] [varchar](20) NOT NULL,
   [Customer Registration Date] [datetime] NOT NULL,
   [Labor Type] [varchar](30) NOT NULL,
   [Labor Charging Code] [varchar](10) NOT NULL,
   [Fabrication Code] [varchar](20) NOT NULL,
   [PaSS Deliver All Positions] [tinyint] NOT NULL,
   [Combine Shipment] [tinyint] NOT NULL,
   [Premium Selection] [int] NOT NULL,
   [Bulkcust_ Labor Price Group] [varchar](10) NOT NULL,
   [Bulkcust_ Ser_ Sales Price Grp] [varchar](10) NOT NULL,
   [Bulkcust_ Contact1] [varchar](20) NOT NULL,
   [Bulkcust_ Contact2] [varchar](20) NOT NULL,
   [Bulkcust_ Contact3] [varchar](20) NOT NULL,
   [Bulk_ Cont_ fleet veh_ leader] [varchar](20) NOT NULL,
   [Discount Memo] [tinyint] NOT NULL,
   [User ID] [varchar](20) NOT NULL,
   [User ID Order] [varchar](20) NOT NULL,
   [Reference-to Doc_ Type] [int] NOT NULL,
   [Reference-to Doc_ No_] [varchar](20) NOT NULL,
   [ZFSupplierNo] [varchar](10) NOT NULL,
   [ZFBMWCompCode] [varchar](10) NOT NULL,
   [ZFBMWOrderNo] [varchar](10) NOT NULL,
   [ZFBMWBusinessUnit] [varchar](10) NOT NULL,
   [ZFBMWBusinessArea] [varchar](10) NOT NULL,
   [ZFBuyerTradeParty] [varchar](10) NOT NULL,
   [WebShopRGNr] [varchar](20) NOT NULL,
   [Client_DB] [varchar](20) NOT NULL

   ,CONSTRAINT [Sales_Header$0] PRIMARY KEY CLUSTERED ([Document Type], [No_], [Client_DB])
)


GO
