Advertisement
Guest User

Untitled

a guest
Jul 11th, 2022
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MySQL 13.88 KB | None | 0 0
  1. CREATE TABLE `sales_flat_order` (
  2.  `entity_id` int unsigned NOT NULL AUTO_INCREMENT COMMENT 'Entity Id',
  3.  `psl_wawi_order_export` int DEFAULT '0',
  4.  `state` varchar(32) DEFAULT NULL COMMENT 'State',
  5.  `status` varchar(32) DEFAULT NULL COMMENT 'Status',
  6.  `coupon_code` varchar(255) DEFAULT NULL COMMENT 'Coupon Code',
  7.  `protect_code` varchar(255) DEFAULT NULL COMMENT 'Protect Code',
  8.  `shipping_description` varchar(255) DEFAULT NULL COMMENT 'Shipping Description',
  9.  `is_virtual` smallint unsigned DEFAULT NULL COMMENT 'Is Virtual',
  10.  `store_id` smallint unsigned DEFAULT NULL COMMENT 'Store Id',
  11.  `customer_id` int unsigned DEFAULT NULL COMMENT 'Customer Id',
  12.  `base_discount_amount` decimal(12,4) DEFAULT NULL COMMENT 'Base Discount Amount',
  13.  `base_discount_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Base Discount Canceled',
  14.  `base_discount_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Discount Invoiced',
  15.  `base_discount_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Discount Refunded',
  16.  `base_grand_total` decimal(12,4) DEFAULT NULL COMMENT 'Base Grand Total',
  17.  `base_shipping_amount` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Amount',
  18.  `base_shipping_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Canceled',
  19.  `base_shipping_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Invoiced',
  20.  `base_shipping_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Refunded',
  21.  `base_shipping_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Tax Amount',
  22.  `base_shipping_tax_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Tax Refunded',
  23.  `base_subtotal` decimal(12,4) DEFAULT NULL COMMENT 'Base Subtotal',
  24.  `base_subtotal_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Base Subtotal Canceled',
  25.  `base_subtotal_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Subtotal Invoiced',
  26.  `base_subtotal_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Subtotal Refunded',
  27.  `base_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Base Tax Amount',
  28.  `base_tax_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Base Tax Canceled',
  29.  `base_tax_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Tax Invoiced',
  30.  `base_tax_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Tax Refunded',
  31.  `base_to_global_rate` decimal(12,4) DEFAULT NULL COMMENT 'Base To Global Rate',
  32.  `base_to_order_rate` decimal(12,4) DEFAULT NULL COMMENT 'Base To Order Rate',
  33.  `base_total_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Canceled',
  34.  `base_total_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Invoiced',
  35.  `base_total_invoiced_cost` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Invoiced Cost',
  36.  `base_total_offline_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Offline Refunded',
  37.  `base_total_online_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Online Refunded',
  38.  `base_total_paid` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Paid',
  39.  `base_total_qty_ordered` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Qty Ordered',
  40.  `base_total_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Refunded',
  41.  `discount_amount` decimal(12,4) DEFAULT NULL COMMENT 'Discount Amount',
  42.  `discount_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Discount Canceled',
  43.  `discount_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Discount Invoiced',
  44.  `discount_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Discount Refunded',
  45.  `grand_total` decimal(12,4) DEFAULT NULL COMMENT 'Grand Total',
  46.  `shipping_amount` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Amount',
  47.  `shipping_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Canceled',
  48.  `shipping_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Invoiced',
  49.  `shipping_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Refunded',
  50.  `shipping_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Tax Amount',
  51.  `shipping_tax_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Tax Refunded',
  52.  `store_to_base_rate` decimal(12,4) DEFAULT NULL COMMENT 'Store To Base Rate',
  53.  `store_to_order_rate` decimal(12,4) DEFAULT NULL COMMENT 'Store To Order Rate',
  54.  `subtotal` decimal(12,4) DEFAULT NULL COMMENT 'Subtotal',
  55.  `subtotal_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Subtotal Canceled',
  56.  `subtotal_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Subtotal Invoiced',
  57.  `subtotal_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Subtotal Refunded',
  58.  `tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Tax Amount',
  59.  `tax_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Tax Canceled',
  60.  `tax_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Tax Invoiced',
  61.  `tax_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Tax Refunded',
  62.  `total_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Total Canceled',
  63.  `total_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Total Invoiced',
  64.  `total_offline_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Total Offline Refunded',
  65.  `total_online_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Total Online Refunded',
  66.  `total_paid` decimal(12,4) DEFAULT NULL COMMENT 'Total Paid',
  67.  `total_qty_ordered` decimal(12,4) DEFAULT NULL COMMENT 'Total Qty Ordered',
  68.  `total_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Total Refunded',
  69.  `can_ship_partially` smallint unsigned DEFAULT NULL COMMENT 'Can Ship Partially',
  70.  `can_ship_partially_item` smallint unsigned DEFAULT NULL COMMENT 'Can Ship Partially Item',
  71.  `customer_is_guest` smallint unsigned DEFAULT NULL COMMENT 'Customer Is Guest',
  72.  `customer_note_notify` smallint unsigned DEFAULT NULL COMMENT 'Customer Note Notify',
  73.  `billing_address_id` int DEFAULT NULL COMMENT 'Billing Address Id',
  74.  `customer_group_id` smallint DEFAULT NULL COMMENT 'Customer Group Id',
  75.  `edit_increment` int DEFAULT NULL COMMENT 'Edit Increment',
  76.  `email_sent` smallint unsigned DEFAULT NULL COMMENT 'Email Sent',
  77.  `forced_shipment_with_invoice` smallint unsigned DEFAULT NULL COMMENT 'Forced Do Shipment With Invoice',
  78.  `payment_auth_expiration` int DEFAULT NULL COMMENT 'Payment Authorization Expiration',
  79.  `quote_address_id` int DEFAULT NULL COMMENT 'Quote Address Id',
  80.  `quote_id` int DEFAULT NULL COMMENT 'Quote Id',
  81.  `shipping_address_id` int DEFAULT NULL COMMENT 'Shipping Address Id',
  82.  `adjustment_negative` decimal(12,4) DEFAULT NULL COMMENT 'Adjustment Negative',
  83.  `adjustment_positive` decimal(12,4) DEFAULT NULL COMMENT 'Adjustment Positive',
  84.  `base_adjustment_negative` decimal(12,4) DEFAULT NULL COMMENT 'Base Adjustment Negative',
  85.  `base_adjustment_positive` decimal(12,4) DEFAULT NULL COMMENT 'Base Adjustment Positive',
  86.  `base_shipping_discount_amount` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Discount Amount',
  87.  `base_subtotal_incl_tax` decimal(12,4) DEFAULT NULL COMMENT 'Base Subtotal Incl Tax',
  88.  `base_total_due` decimal(12,4) DEFAULT NULL COMMENT 'Base Total Due',
  89.  `payment_authorization_amount` decimal(12,4) DEFAULT NULL COMMENT 'Payment Authorization Amount',
  90.  `shipping_discount_amount` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Discount Amount',
  91.  `subtotal_incl_tax` decimal(12,4) DEFAULT NULL COMMENT 'Subtotal Incl Tax',
  92.  `total_due` decimal(12,4) DEFAULT NULL COMMENT 'Total Due',
  93.  `weight` decimal(12,4) DEFAULT NULL COMMENT 'Weight',
  94.  `customer_dob` datetime DEFAULT NULL COMMENT 'Customer Dob',
  95.  `increment_id` varchar(50) DEFAULT NULL COMMENT 'Increment Id',
  96.  `applied_rule_ids` varchar(255) DEFAULT NULL COMMENT 'Applied Rule Ids',
  97.  `base_currency_code` varchar(3) DEFAULT NULL COMMENT 'Base Currency Code',
  98.  `customer_email` varchar(255) DEFAULT NULL COMMENT 'Customer Email',
  99.  `customer_firstname` varchar(255) DEFAULT NULL COMMENT 'Customer Firstname',
  100.  `customer_lastname` varchar(255) DEFAULT NULL COMMENT 'Customer Lastname',
  101.  `customer_middlename` varchar(255) DEFAULT NULL COMMENT 'Customer Middlename',
  102.  `customer_prefix` varchar(255) DEFAULT NULL COMMENT 'Customer Prefix',
  103.  `customer_suffix` varchar(255) DEFAULT NULL COMMENT 'Customer Suffix',
  104.  `customer_taxvat` varchar(255) DEFAULT NULL COMMENT 'Customer Taxvat',
  105.  `discount_description` varchar(255) DEFAULT NULL COMMENT 'Discount Description',
  106.  `ext_customer_id` varchar(255) DEFAULT NULL COMMENT 'Ext Customer Id',
  107.  `ext_order_id` varchar(255) DEFAULT NULL COMMENT 'Ext Order Id',
  108.  `global_currency_code` varchar(3) DEFAULT NULL COMMENT 'Global Currency Code',
  109.  `hold_before_state` varchar(255) DEFAULT NULL COMMENT 'Hold Before State',
  110.  `hold_before_status` varchar(255) DEFAULT NULL COMMENT 'Hold Before Status',
  111.  `order_currency_code` varchar(255) DEFAULT NULL COMMENT 'Order Currency Code',
  112.  `original_increment_id` varchar(50) DEFAULT NULL COMMENT 'Original Increment Id',
  113.  `relation_child_id` varchar(32) DEFAULT NULL COMMENT 'Relation Child Id',
  114.  `relation_child_real_id` varchar(32) DEFAULT NULL COMMENT 'Relation Child Real Id',
  115.  `relation_parent_id` varchar(32) DEFAULT NULL COMMENT 'Relation Parent Id',
  116.  `relation_parent_real_id` varchar(32) DEFAULT NULL COMMENT 'Relation Parent Real Id',
  117.  `remote_ip` varchar(255) DEFAULT NULL COMMENT 'Remote Ip',
  118.  `shipping_method` varchar(255) DEFAULT NULL COMMENT 'Shipping Method',
  119.  `store_currency_code` varchar(3) DEFAULT NULL COMMENT 'Store Currency Code',
  120.  `store_name` varchar(255) DEFAULT NULL COMMENT 'Store Name',
  121.  `x_forwarded_for` varchar(255) DEFAULT NULL COMMENT 'X Forwarded For',
  122.  `customer_note` text COMMENT 'Customer Note',
  123.  `created_at` timestamp NULL DEFAULT NULL COMMENT 'Created At',
  124.  `updated_at` timestamp NULL DEFAULT NULL COMMENT 'Updated At',
  125.  `total_item_count` smallint unsigned NOT NULL DEFAULT '0' COMMENT 'Total Item Count',
  126.  `customer_gender` int DEFAULT NULL COMMENT 'Customer Gender',
  127.  `hidden_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Hidden Tax Amount',
  128.  `base_hidden_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Base Hidden Tax Amount',
  129.  `shipping_hidden_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Hidden Tax Amount',
  130.  `base_shipping_hidden_tax_amnt` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Hidden Tax Amount',
  131.  `hidden_tax_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Hidden Tax Invoiced',
  132.  `base_hidden_tax_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Hidden Tax Invoiced',
  133.  `hidden_tax_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Hidden Tax Refunded',
  134.  `base_hidden_tax_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Hidden Tax Refunded',
  135.  `shipping_incl_tax` decimal(12,4) DEFAULT NULL COMMENT 'Shipping Incl Tax',
  136.  `base_shipping_incl_tax` decimal(12,4) DEFAULT NULL COMMENT 'Base Shipping Incl Tax',
  137.  `coupon_rule_name` varchar(255) DEFAULT NULL COMMENT 'Coupon Sales Rule Name',
  138.  `paypal_ipn_customer_notified` int DEFAULT '0' COMMENT 'Paypal Ipn Customer Notified',
  139.  `gift_message_id` int DEFAULT NULL COMMENT 'Gift Message Id',
  140.  `cod_fee` decimal(12,4) DEFAULT NULL COMMENT 'Cod Fee',
  141.  `base_cod_fee` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Fee',
  142.  `cod_fee_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Cod Fee Invoiced',
  143.  `base_cod_fee_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Fee Invoiced',
  144.  `cod_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Cod Tax Amount',
  145.  `base_cod_tax_amount` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Tax Amount',
  146.  `cod_tax_amount_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Cod Tax Amount Invoiced',
  147.  `base_cod_tax_amount_invoiced` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Tax Amount Invoiced',
  148.  `cod_fee_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Cod Fee Refunded',
  149.  `base_cod_fee_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Fee Refunded',
  150.  `cod_tax_amount_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Cod Tax Amount Refunded',
  151.  `base_cod_tax_amount_refunded` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Tax Amount Refunded',
  152.  `cod_fee_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Cod Fee Canceled',
  153.  `base_cod_fee_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Fee Canceled',
  154.  `cod_tax_amount_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Cod Tax Amount Canceled',
  155.  `base_cod_tax_amount_canceled` decimal(12,4) DEFAULT NULL COMMENT 'Base Cod Tax Amount Canceled',
  156.  `payone_transaction_status` varchar(16) NOT NULL COMMENT 'payone_transaction_status',
  157.  `payone_dunning_status` varchar(16) NOT NULL COMMENT 'payone_dunning_status',
  158.  `payone_payment_method_type` varchar(50) NOT NULL COMMENT 'Method Type that was used. Only filled for CreditCard and OnlineBankTransfer',
  159.  `payone_payment_fee` float DEFAULT NULL COMMENT 'payone_payment_fee',
  160.  `payone_prevent_confirmation` int DEFAULT NULL COMMENT 'Flag to prevent confirmation mail',
  161.  `payone_cancel_substitute_increment_id` varchar(50) DEFAULT NULL COMMENT 'Increment ID of the cancled order which this is the substitute for',
  162.  `mollie_transaction_id` varchar(255) DEFAULT NULL COMMENT 'Mollie Transaction Id',
  163.  `mollie_mpm_payment_fee` decimal(12,4) DEFAULT NULL,
  164.  `base_mollie_mpm_payment_fee` decimal(12,4) DEFAULT NULL,
  165.  `mollie_mpm_payment_fee_tax` decimal(12,4) DEFAULT NULL,
  166.  `base_mollie_mpm_payment_fee_tax` decimal(12,4) DEFAULT NULL,
  167.  PRIMARY KEY (`entity_id`),
  168.  UNIQUE KEY `UNQ_SALES_FLAT_ORDER_INCREMENT_ID` (`increment_id`),
  169.  KEY `IDX_SALES_FLAT_ORDER_STATUS` (`status`),
  170.  KEY `IDX_SALES_FLAT_ORDER_STATE` (`state`),
  171.  KEY `IDX_SALES_FLAT_ORDER_STORE_ID` (`store_id`),
  172.  KEY `IDX_SALES_FLAT_ORDER_CREATED_AT` (`created_at`),
  173.  KEY `IDX_SALES_FLAT_ORDER_CUSTOMER_ID` (`customer_id`),
  174.  KEY `IDX_SALES_FLAT_ORDER_EXT_ORDER_ID` (`ext_order_id`),
  175.  KEY `IDX_SALES_FLAT_ORDER_QUOTE_ID` (`quote_id`),
  176.  KEY `IDX_SALES_FLAT_ORDER_UPDATED_AT` (`updated_at`),
  177.  KEY `IDX_SALES_FLAT_ORDER_PO_CANCEL_SUBSTITUTE_INCREMENT_ID` (`payone_cancel_substitute_increment_id`),
  178.  KEY `IDX_SALES_FLAT_ORDER_MOLLIE_TRANSACTION_ID` (`mollie_transaction_id`),
  179.  CONSTRAINT `FK_SALES_FLAT_ORDER_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE SET NULL ON UPDATE CASCADE,
  180.  CONSTRAINT `FK_SALES_FLAT_ORDER_STORE_ID_CORE_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `core_store` (`store_id`) ON DELETE SET NULL ON UPDATE CASCADE
  181. ) ENGINE=InnoDB AUTO_INCREMENT=129047 DEFAULT CHARSET=utf8mb3 COMMENT='Sales Flat Order'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement