CREATE TABLE [dbo].[parts_stock] (
   [part_number] [varchar](100) NOT NULL,
   [stock_no] [int] NOT NULL,
   [storage_location_1] [varchar](50) NULL,
   [storage_location_2] [varchar](50) NULL,
   [usage_value] [numeric](11,2) NULL,
   [stock_level] [numeric](10,2) NULL,
   [stock_allocated] [numeric](10,2) NULL,
   [minimum_stock_level] [numeric](10,2) NULL,
   [has_warn_on_below_min_level] [smallint] NULL,
   [maximum_stock_level] [int] NULL,
   [stop_order_flag] [varchar](10) NULL,
   [revenue_account_group] [varchar](50) NULL,
   [average_sales_statstic] [numeric](7,2) NULL,
   [sales_current_year] [numeric](10,2) NULL,
   [sales_previous_year] [numeric](10,2) NULL,
   [total_buy_value] [numeric](11,2) NULL,
   [total_sell_value] [numeric](11,2) NULL,
   [provider_flag] [varchar](10) NULL,
   [last_outflow_date] [datetime] NULL,
   [last_inflow_date] [datetime] NULL,
   [unevaluated_inflow_positions] [int] NULL,
   [is_disabled_in_parts_platforms] [smallint] NULL,
   [lock_by_workstation] [int] NULL,
   [lock_time] [datetime] NULL,
   [lock_trace] [varchar](255) NULL,
   [lock_trigger] [varchar](255) NULL,
   [lock_by_employee] [int] NULL,
   [lock_sourcecode] [varchar](255) NULL,
   [client_db] [varchar](20) NOT NULL

   ,CONSTRAINT [parts_stock$0] PRIMARY KEY CLUSTERED ([part_number], [stock_no], [client_db])
)


GO
