테이블필드확인.sql 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571
  1. SELECT * FROM `dbr_company` WHERE email = 'opticlibre@naver.com';
  2. SELECT * FROM `pro_member` WHERE email = 'opticlibre@naver.com';
  3. SELECT * FROM `pro_member_ext` WHERE id = 168;
  4. delete FROM `pro_member` WHERE email = 'dev1.dabory@gmail.com';
  5. delete FROM `pro_member` WHERE email = 'dev1.dabory@gmail.com';
  6. delete FROM `pro_member_ext` WHERE id = 149;
  7. SELECT * FROM `dbr_company` WHERE email = 'dev1.dabory@gmail.com';
  8. SELECT * FROM `pro_member` WHERE email = 'dev1.dabory@gmail.com';
  9. SELECT * FROM `pro_member_ext` WHERE id = 149;
  10. ALTER TABLE `dbr_user_menu` ADD `guest_app_id` INT(11) NOT NULL DEFAULT '0' AFTER `is_skipped`;
  11. ALTER TABLE `bcs_circulatiing`
  12. CHANGE `circulatiing_supply` `circulating_supply` DECIMAL (34, 0) DEFAULT 0 NOT NULL;
  13. RENAME TABLE `bcs_circulatiing` TO `bcs_circulating`;
  14. ALTER TABLE `dbr_porder_bd`
  15. ADD `memo` TEXT NULL DEFAULT NULL AFTER `confirm_date`,
  16. ADD `column2` varchar(69) DEFAULT NULL AFTER `confirm_date`,
  17. ADD `column1` varchar(69) DEFAULT NULL AFTER `confirm_date`;
  18. delete FROM `dbr_setup` WHERE setup_code = 'office-info';
  19. INSERT INTO dbr_setup (branch_id, setup_code, brand_code, setup_name, component, parameter, is_on_use, is_brand_select, setup_json )
  20. VALUES (0, 'office-info', '', '사무실정보', 'popup-setup.form-a.office-info-form', '/popup-setup/form-a/office-info', '1', '0', '{\"OfcCode\":\"baeksan-optical\",\"OfcPlace\":\"2\",\"OfcName\":\"3\",\"OfcTaxNo\":\"4\",\"OfcEmail\":\"5\",\"OfcTelNo\":\"6\",\"OfcFaxNo\":\"7\",\"OfcMobile\":\"8\",\"OfcZipCode\":\"9\",\"OfcPresident\":\"10\",\"OfcAddress\":\"11\",\"OfcBizType\":\"12\",\"OfcDealItem\":\"13\"}');
  21. update dbr_setup set component = 'popup-setup.form-a.media-library-form' where setup_code='media-body'
  22. drop table if exists dbt_list_type1;
  23. CREATE TABLE `dbt_list_type1` (
  24. `t_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  25. `id` int(10) unsigned DEFAULT NULL,
  26. `created_on` int(11) NOT NULL DEFAULT unix_timestamp(),
  27. `list_token` varchar(21) NOT NULL,
  28. `order_by` varchar(32) DEFAULT NULL,
  29. `c1` varchar(64) DEFAULT NULL,
  30. `c2` varchar(64) DEFAULT NULL,
  31. `c3` varchar(64) DEFAULT NULL,
  32. `c4` varchar(64) DEFAULT NULL,
  33. `c5` varchar(64) DEFAULT NULL,
  34. `c6` varchar(64) DEFAULT NULL,
  35. `c7` varchar(64) DEFAULT NULL,
  36. `c8` varchar(64) DEFAULT NULL,
  37. `c9` varchar(64) DEFAULT NULL,
  38. `c10` varchar(64) DEFAULT NULL,
  39. `c11` varchar(64) DEFAULT NULL,
  40. `c12` varchar(64) DEFAULT NULL,
  41. `c13` varchar(64) DEFAULT NULL,
  42. `c14` varchar(64) DEFAULT NULL,
  43. `c15` varchar(64) DEFAULT NULL,
  44. `c16` varchar(64) DEFAULT NULL,
  45. `c17` varchar(64) DEFAULT NULL,
  46. `c18` varchar(64) DEFAULT NULL,
  47. `c19` varchar(64) DEFAULT NULL,
  48. `c20` varchar(64) DEFAULT NULL,
  49. `d1` decimal(20,4) DEFAULT '0.0000',
  50. `d2` decimal(20,4) DEFAULT '0.0000',
  51. `d3` decimal(20,4) DEFAULT '0.0000',
  52. `d4` decimal(20,4) DEFAULT '0.0000',
  53. `d5` decimal(20,4) DEFAULT '0.0000',
  54. `d6` decimal(20,4) DEFAULT '0.0000',
  55. `d7` decimal(20,4) DEFAULT '0.0000',
  56. `d8` decimal(20,4) DEFAULT '0.0000',
  57. `d9` decimal(20,4) DEFAULT '0.0000',
  58. `d10` decimal(20,4) DEFAULT '0.0000',
  59. `is_sum` char(1) NOT NULL DEFAULT '0',
  60. `t1` mediumtext DEFAULT NULL,
  61. `t2` mediumtext DEFAULT NULL,
  62. UNIQUE KEY `tid` (`t_id`)
  63. ) ENGINE=MyISAM AUTO_INCREMENT=2273 DEFAULT CHARSET=utf8mb4
  64. drop table if exists cry_list1;
  65. drop table if exists cry_list1_federated;
  66. drop table if exists fed_crystal_host;
  67. CREATE TABLE `fed_crystal_host` (
  68. `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  69. `created_on` int(11) NOT NULL DEFAULT unix_timestamp(),
  70. `list_token` varchar(21) NOT NULL,
  71. `position` varchar(10) NOT NULL,
  72. `order_by` varchar(32) DEFAULT NULL,
  73. `c1` varchar(64) DEFAULT NULL,
  74. `c2` varchar(64) DEFAULT NULL,
  75. `c3` varchar(64) DEFAULT NULL,
  76. `c4` varchar(64) DEFAULT NULL,
  77. `c5` varchar(64) DEFAULT NULL,
  78. `c6` varchar(64) DEFAULT NULL,
  79. `c7` varchar(64) DEFAULT NULL,
  80. `c8` varchar(64) DEFAULT NULL,
  81. `c9` varchar(64) DEFAULT NULL,
  82. `c10` varchar(64) DEFAULT NULL,
  83. `c11` varchar(64) DEFAULT NULL,
  84. `c12` varchar(64) DEFAULT NULL,
  85. `c13` varchar(64) DEFAULT NULL,
  86. `c14` varchar(64) DEFAULT NULL,
  87. `c15` varchar(64) DEFAULT NULL,
  88. `c16` varchar(64) DEFAULT NULL,
  89. `c17` varchar(64) DEFAULT NULL,
  90. `c18` varchar(64) DEFAULT NULL,
  91. `c19` varchar(64) DEFAULT NULL,
  92. `c20` varchar(64) DEFAULT NULL,
  93. `d1` decimal(20,4) DEFAULT '0.0000',
  94. `d2` decimal(20,4) DEFAULT '0.0000',
  95. `d3` decimal(20,4) DEFAULT '0.0000',
  96. `d4` decimal(20,4) DEFAULT '0.0000',
  97. `d5` decimal(20,4) DEFAULT '0.0000',
  98. `d6` decimal(20,4) DEFAULT '0.0000',
  99. `d7` decimal(20,4) DEFAULT '0.0000',
  100. `d8` decimal(20,4) DEFAULT '0.0000',
  101. `d9` decimal(20,4) DEFAULT '0.0000',
  102. `d10` decimal(20,4) DEFAULT '0.0000',
  103. `is_sum` char(1) NOT NULL DEFAULT '0',
  104. `t1` mediumtext DEFAULT NULL,
  105. `t2` mediumtext DEFAULT NULL,
  106. UNIQUE KEY `id` (`id`)
  107. ) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4;
  108. drop table if exists fed_office_host;
  109. CREATE TABLE `fed_office_host` (
  110. `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  111. `created_on` int(11) NOT NULL DEFAULT 123,
  112. `updated_on` int(11) NOT NULL DEFAULT 123,
  113. `ofc_code` varchar(21) NOT NULL,
  114. `ofc_place` varchar(128) DEFAULT NULL,
  115. `ofc_name` varchar(128) DEFAULT NULL,
  116. `fed_office_host` varchar(128) DEFAULT NULL,
  117. `ofc_tax_no` varchar(32) DEFAULT NULL,
  118. `ofc_email` varchar(128) DEFAULT NULL,
  119. `ofc_tel_no` varchar(16) DEFAULT NULL,
  120. `ofc_fax_no` varchar(16) DEFAULT NULL,
  121. `ofc_mobile` varchar(16) DEFAULT NULL,
  122. `ofc_zip_code` varchar(16) DEFAULT NULL,
  123. `ofc_president` varchar(64) DEFAULT NULL,
  124. `ofc_address` varchar(256) DEFAULT NULL,
  125. `ofc_biz_type` varchar(64) DEFAULT NULL,
  126. `ofc_deal_type` varchar(64) DEFAULT NULL,
  127. `sales_qty_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  128. `sales_prc_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  129. `sales_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  130. `purch_qty_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  131. `purch_prc_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  132. `purch_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  133. `stock_qty_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  134. `stock_prc_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  135. `stock_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  136. `acc_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  137. UNIQUE KEY `id` (`id`)
  138. ) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  139. drop table if exists fed_office_guest;
  140. CREATE TABLE `fed_office_guest` (
  141. `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  142. `created_on` int(11) NOT NULL DEFAULT 123,
  143. `updated_on` int(11) NOT NULL DEFAULT 123,
  144. `ofc_code` varchar(21) NOT NULL,
  145. `ofc_place` varchar(128) DEFAULT NULL,
  146. `ofc_name` varchar(128) DEFAULT NULL,
  147. `fed_office_host` varchar(128) DEFAULT NULL,
  148. `ofc_tax_no` varchar(32) DEFAULT NULL,
  149. `ofc_email` varchar(128) DEFAULT NULL,
  150. `ofc_tel_no` varchar(16) DEFAULT NULL,
  151. `ofc_fax_no` varchar(16) DEFAULT NULL,
  152. `ofc_mobile` varchar(16) DEFAULT NULL,
  153. `ofc_zip_code` varchar(16) DEFAULT NULL,
  154. `ofc_president` varchar(64) DEFAULT NULL,
  155. `ofc_address` varchar(256) DEFAULT NULL,
  156. `ofc_biz_type` varchar(64) DEFAULT NULL,
  157. `ofc_deal_type` varchar(64) DEFAULT NULL,
  158. `sales_qty_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  159. `sales_prc_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  160. `sales_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  161. `purch_qty_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  162. `purch_prc_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  163. `purch_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  164. `stock_qty_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  165. `stock_prc_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  166. `stock_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  167. `acc_amt_point` tinyint(4) unsigned NOT NULL DEFAULT 0,
  168. UNIQUE KEY `id` (`id`)
  169. ) ENGINE = FEDERATED CONNECTION='mysql://symerp_db:8xFrHRymYxU@175.126.146.153:3306/crystalfed_db/fed_office_host';
  170. ) ENGINE = FEDERATED CONNECTION='mysql://weberp_db:nb7X94raSds@175.126.146.153:3306/crystalfed_db/fed_office_host';
  171. drop table if exists fed_crystal_guest;
  172. drop table if exists fed_office_guest;
  173. drop table if exists zdb_optpos_contact_lens;
  174. ALTER TABLE `dbr_sorder` ADD INDEX `sorder_date` (`sorder_date`);
  175. ALTER TABLE `dbr_sgroup` ADD `Sort` CHAR(1) NOT NULL DEFAULT '0' AFTER `agroup_id`;
  176. ALTER TABLE `dbr_sgroup` ADD `branch_id` INT(11) NOT NULL DEFAULT '0' AFTER `agroup_id`;
  177. show create table bcs_circulating
  178. ALTER TABLE
  179. CHANGE `` * COMMENT '',
  180. CHANGE `` * COMMENT '';
  181. drop table if exists dbr_acc_title;
  182. CREATE TABLE `dbr_acc_title` (
  183. `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  184. `created_on` bigint(20) DEFAULT 0,
  185. `updated_on` bigint(20) DEFAULT 0,
  186. `title_code` varchar(6) NOT NULL DEFAULT '' COMMENT '계정과목코드',
  187. `acc_dr_cr` tinyint(4) NOT NULL DEFAULT 3 COMMENT '차대변',
  188. `title_name` varchar(64) NOT NULL DEFAULT '' COMMENT '계정과목명',
  189. `atgroup_code` varchar(16) NOT NULL DEFAULT '' COMMENT '집합계정코드',
  190. `plus_minus` char(1) NOT NULL DEFAULT '0' COMMENT '증가차감',
  191. `is_chung` char(1) NOT NULL DEFAULT '0' COMMENT '충당금계정',
  192. `is_total` char(1) NOT NULL DEFAULT '0' COMMENT '합계계정',
  193. `is_import_cost` char(1) NOT NULL DEFAULT '0' COMMENT '수입비용계정',
  194. `level3_atgroup_code` varchar(16) NOT NULL DEFAULT '' COMMENT '3단계집합코드',
  195. `rep_title_code` varchar(16) NOT NULL DEFAULT '' COMMENT '대표계정코드',
  196. `is_acc_company` char(1) NOT NULL DEFAULT '0' COMMENT '회계업체존재',
  197. `is_skipped` char(1) NOT NULL DEFAULT '0' COMMENT '사용않음',
  198. PRIMARY KEY (`id`)
  199. ) ENGINE=InnoDB AUTO_INCREMENT=306 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  200. update users set created_on = 0, updated_on = 0 ;
  201. drop table if exists dbr_sorder;
  202. CREATE TABLE `dbr_sorder` (
  203. `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  204. `created_on` bigint(20) DEFAULT 0,
  205. `updated_on` bigint(20) DEFAULT 0,
  206. `sorder_date` char(8) NOT NULL DEFAULT '',
  207. `sorder_no` varchar(21) DEFAULT NULL COMMENT '수주번호:자동채번',
  208. `squote_id` int(10) unsigned DEFAULT NULL,
  209. `deal_type_id` int(10) unsigned DEFAULT NULL COMMENT '거래구분:매출(00)-Default',
  210. `user_id` int(10) unsigned NOT NULL COMMENT '사용자 id:(5)Default',
  211. `sgroup_id` int(10) unsigned DEFAULT NULL COMMENT '영업구분:안경사',
  212. `sgroup2_id` int(10) unsigned DEFAULT NULL COMMENT '영업구분:판매사',
  213. `branch_id` int(10) unsigned DEFAULT NULL COMMENT '지점:본사(1)Default',
  214. `storage_id` int(10) unsigned DEFAULT NULL COMMENT '창고:본사(1)Default',
  215. `buyer_id` int(10) unsigned DEFAULT NULL COMMENT '고객id',
  216. `vat_rate_id` int(10) unsigned DEFAULT NULL COMMENT '부가세율:포함(1)Default,별도(0)',
  217. `project_id` int(10) NOT NULL DEFAULT 0,
  218. `buyer_contact` varchar(49) DEFAULT NULL COMMENT '고객담당자',
  219. `pay_terms` varchar(69) DEFAULT NULL COMMENT '지불조건',
  220. `pay_period` varchar(69) DEFAULT NULL COMMENT '지불기간',
  221. `destination` varchar(69) DEFAULT NULL COMMENT '도착지역',
  222. `delivery` varchar(69) DEFAULT NULL COMMENT '납기',
  223. `status` char(1) DEFAULT NULL COMMENT '상황:완료(3)',
  224. `situation` char(2) DEFAULT NULL COMMENT '안좋은 상황코드(claim등)',
  225. `is_closed` char(1) NOT NULL COMMENT '종결처리',
  226. `is_first_order` char(1) NOT NULL DEFAULT '0' COMMENT '고객의 첫번째 주문여부',
  227. `column1` varchar(69) DEFAULT NULL,
  228. `column2` varchar(69) DEFAULT NULL,
  229. `remarks` text DEFAULT NULL,
  230. `json1` text DEFAULT NULL COMMENT '검안내용',
  231. `json2` text DEFAULT NULL COMMENT '현재 사용하지 않음',
  232. `is_pro` char(1) NOT NULL DEFAULT '0' COMMENT '0:ERP주문, 1:온라인주문',
  233. `discount_amt` decimal(20,4) NOT NULL DEFAULT 0.0000 COMMENT '할인금액',
  234. `ccard_amt` decimal(20,4) NOT NULL DEFAULT 0.0000 COMMENT '신용카드결제액',
  235. `cash_amt` decimal(20,4) NOT NULL DEFAULT 0.0000 COMMENT '현금결제액',
  236. `coupon_amt` decimal(20,4) NOT NULL DEFAULT 0.0000 COMMENT '쿠폰결제액',
  237. `reward_amt` decimal(20,4) NOT NULL DEFAULT 0.0000 COMMENT '적립금사용액',
  238. `credit_use_amt` decimal(20,4) NOT NULL DEFAULT 0.0000 COMMENT '충전금사용액',
  239. `is_locked` char(1) NOT NULL DEFAULT '0' COMMENT '정산완료(1)-수정불가',
  240. `ship_contact` varchar(64) DEFAULT NULL COMMENT '연락처명',
  241. `ship_mobile` varchar(21) DEFAULT NULL COMMENT '배송연락처번호',
  242. `ship_method` varchar(32) DEFAULT NULL COMMENT '배송방식',
  243. `ship_fee` decimal(20,4) DEFAULT 0.0000 COMMENT '배송비',
  244. `ship_zip_code` varchar(21) DEFAULT NULL COMMENT '우편번호',
  245. `ship_addr1` varchar(64) DEFAULT NULL COMMENT '주소1',
  246. `ship_addr2` varchar(64) DEFAULT NULL COMMENT '주소2',
  247. `ship_notes` varchar(64) DEFAULT NULL COMMENT '배송메모',
  248. `paymethod` char(2) NOT NULL DEFAULT '0' COMMENT '결재방식',
  249. `remit_account` varchar(64) DEFAULT NULL COMMENT '송금받는계좌',
  250. `remit_name` varchar(32) DEFAULT NULL COMMENT '무통장입금자명',
  251. `ip` varchar(20) DEFAULT NULL,
  252. PRIMARY KEY (`id`),
  253. UNIQUE KEY `sorder_no` (`sorder_no`),
  254. KEY `sorder_date` (`sorder_date`),
  255. KEY `squote_id` (`squote_id`),
  256. KEY `deal_type_id` (`deal_type_id`),
  257. KEY `user_id` (`user_id`),
  258. KEY `sgroup_id` (`sgroup_id`),
  259. KEY `sgroup2_id` (`sgroup2_id`),
  260. KEY `branch_id` (`branch_id`),
  261. KEY `storage_id` (`storage_id`),
  262. KEY `buyer_id` (`buyer_id`),
  263. KEY `vat_rate_id` (`vat_rate_id`),
  264. KEY `project_id` (`project_id`),
  265. KEY `mdx_buyer_date` (`buyer_id`,`sorder_date`) USING BTREE
  266. ) ENGINE=InnoDB AUTO_INCREMENT=100012 DEFAULT CHARSET=utf8mb4;
  267. REPLACE INTO dbr_media
  268. (id, media_no, media_date, user_id, branch_id, media_brand, media_name)
  269. VALUES
  270. (1, '200101-0000', '20000101', 5, 1, 'image', 'blank_image');
  271. REPLACE INTO dbr_media_bd (id, media_id, seq_no, image_type) VALUES (1, 1, 1, 'big');
  272. REPLACE INTO dbr_media_bd (id, media_id, seq_no, image_type) VALUES (2, 1, 2, 'middle');
  273. REPLACE INTO dbr_media_bd (id, media_id, seq_no, image_type) VALUES (3, 1, 3, 'thumb');
  274. REPLACE INTO users
  275. (id, email, password, activate_code, reset_code, nick_name, first_name, sur_name)
  276. VALUES
  277. (1, MD5(RAND()), 'unlinked', 'unlinked', 'unlinked', 'unlinked', 'unlinked', 'unlinked');
  278. REPLACE INTO dbr_user_ext
  279. (id, mobile_no, phone_no, user_perm_id, menu_lang_sw,
  280. sgroup_id, branch_id, storage_id, agroup_id, country_code, is_expired)
  281. VALUES
  282. (1, 'unlinked', 'unlinked', 7, 0,
  283. 1, 1, 1, 1, 'ko_KR', '0');
  284. REPLACE INTO pro_member
  285. (id, email, password, activate_code, reset_code, nick_name, first_name, sur_name)
  286. VALUES
  287. (1, MD5(RAND()), 'unlinked', 'unlinked', 'unlinked', 'unlinked', 'unlinked', 'unlinked');
  288. ALTER TABLE `pro_member_ext` CHANGE `created_on` `created_on` BIGINT(11) NOT NULL DEFAULT '0';
  289. ALTER TABLE `pro_member_ext` CHANGE `updated_on` `updated_on` BIGINT(11) NOT NULL DEFAULT '0';
  290. REPLACE INTO pro_member_ext
  291. (id, mobile_no, phone_no, member_perm_id, menu_lang_sw,
  292. sgroup_id, branch_id, storage_id, agroup_id, country_code, is_expired)
  293. VALUES
  294. (1, 'unlinked', 'unlinked', 7, 0,
  295. 1, 1, 1, 1, 'ko_KR', '0');
  296. REPLACE INTO pro_seo_meta (id, join_duid) VALUES (1, '1')
  297. drop table if exists dbt_list_sum;
  298. CREATE TABLE `dbt_list_sum` (
  299. `t_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  300. `h_id` int(11) NOT NULL DEFAULT 0 COMMENT '전표 Header id',
  301. `id` int(10) unsigned DEFAULT NULL,
  302. `created_on` bigint(20) DEFAULT 0,
  303. `list_token` varchar(21) NOT NULL,
  304. `order_by` varchar(64) DEFAULT NULL,
  305. `c1` varchar(64) DEFAULT NULL,
  306. `c2` varchar(64) DEFAULT NULL,
  307. `c3` varchar(64) DEFAULT NULL,
  308. `c4` varchar(64) DEFAULT NULL,
  309. `c5` varchar(64) DEFAULT NULL,
  310. `c6` varchar(64) DEFAULT NULL,
  311. `c7` varchar(64) DEFAULT NULL,
  312. `c8` varchar(64) DEFAULT NULL,
  313. `c9` varchar(64) DEFAULT NULL,
  314. `c10` varchar(64) DEFAULT NULL,
  315. `c11` varchar(64) DEFAULT NULL,
  316. `c12` varchar(64) DEFAULT NULL,
  317. `c13` varchar(64) DEFAULT NULL,
  318. `c14` varchar(64) DEFAULT NULL,
  319. `c15` varchar(64) DEFAULT NULL,
  320. `c16` varchar(64) DEFAULT NULL,
  321. `c17` varchar(64) DEFAULT NULL,
  322. `c18` varchar(64) DEFAULT NULL,
  323. `c19` varchar(64) DEFAULT NULL,
  324. `c20` varchar(64) DEFAULT NULL,
  325. `d1` decimal(20,4) DEFAULT 0.0000,
  326. `d2` decimal(20,4) DEFAULT 0.0000,
  327. `d3` decimal(20,4) DEFAULT 0.0000,
  328. `d4` decimal(20,4) DEFAULT 0.0000,
  329. `d5` decimal(20,4) DEFAULT 0.0000,
  330. `d6` decimal(20,4) DEFAULT 0.0000,
  331. `d7` decimal(20,4) DEFAULT 0.0000,
  332. `d8` decimal(20,4) DEFAULT 0.0000,
  333. `d9` decimal(20,4) DEFAULT 0.0000,
  334. `d10` decimal(20,4) DEFAULT 0.0000,
  335. `is_sum` char(1) NOT NULL DEFAULT '0',
  336. `t1` mediumtext DEFAULT NULL,
  337. `t2` mediumtext DEFAULT NULL,
  338. UNIQUE KEY `tid` (`t_id`)
  339. ) ENGINE=MyISAM AUTO_INCREMENT=360 DEFAULT CHARSET=utf8mb4
  340. [ssohost pre-process]
  341. drop table if exists crm_account;
  342. CREATE TABLE `crm_account` (
  343. `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  344. `created_on` bigint(11) NOT NULL,
  345. `updated_on` bigint(11) NOT NULL,
  346. `buyer_id` int(10) unsigned NOT NULL,
  347. `account_name` varchar(64) NOT NULL,
  348. `str0` varchar(64) DEFAULT NULL,
  349. `str1` varchar(64) DEFAULT NULL,
  350. `str2` varchar(64) DEFAULT NULL,
  351. `str3` varchar(64) DEFAULT NULL,
  352. `str4` varchar(64) DEFAULT NULL,
  353. `str5` varchar(64) DEFAULT NULL,
  354. `str6` varchar(64) DEFAULT NULL,
  355. `str7` varchar(64) DEFAULT NULL,
  356. `str8` varchar(64) DEFAULT NULL,
  357. `str9` varchar(64) DEFAULT NULL,
  358. `rng0` varchar(64) DEFAULT NULL,
  359. `rng1` varchar(64) DEFAULT NULL,
  360. `rng2` varchar(64) DEFAULT NULL,
  361. `rng3` varchar(64) DEFAULT NULL,
  362. `rng4` varchar(64) DEFAULT NULL,
  363. `rng5` varchar(64) DEFAULT NULL,
  364. `rng6` varchar(64) DEFAULT NULL,
  365. `rng7` varchar(64) DEFAULT NULL,
  366. `rng8` varchar(64) DEFAULT NULL,
  367. `rng9` varchar(64) DEFAULT NULL,
  368. `dec0` decimal(20,4) DEFAULT 0.0000,
  369. `dec1` decimal(20,4) DEFAULT 0.0000,
  370. `dec2` decimal(20,4) DEFAULT 0.0000,
  371. `dec3` decimal(20,4) DEFAULT 0.0000,
  372. `dec4` decimal(20,4) DEFAULT 0.0000,
  373. `dec5` decimal(20,4) DEFAULT 0.0000,
  374. `dec6` decimal(20,4) DEFAULT 0.0000,
  375. `dec7` decimal(20,4) DEFAULT 0.0000,
  376. `dec8` decimal(20,4) DEFAULT 0.0000,
  377. `dec9` decimal(20,4) DEFAULT 0.0000,
  378. `chk0_opt0` char(1) DEFAULT '0',
  379. `chk0_opt1` char(1) DEFAULT '0',
  380. `chk0_opt2` char(1) DEFAULT '0',
  381. `chk0_opt3` char(1) DEFAULT '0',
  382. `chk0_opt4` char(1) DEFAULT '0',
  383. `chk1_opt0` char(1) DEFAULT '0',
  384. `chk1_opt1` char(1) DEFAULT '0',
  385. `chk1_opt2` char(1) DEFAULT '0',
  386. `chk1_opt3` char(1) DEFAULT '0',
  387. `chk1_opt4` char(1) DEFAULT '0',
  388. `chk2_opt0` char(1) DEFAULT '0',
  389. `chk2_opt1` char(1) DEFAULT '0',
  390. `chk2_opt2` char(1) DEFAULT '0',
  391. `chk2_opt3` char(1) DEFAULT '0',
  392. `chk2_opt4` char(1) DEFAULT '0',
  393. `chk3_opt0` char(1) DEFAULT '0',
  394. `chk3_opt1` char(1) DEFAULT '0',
  395. `chk3_opt2` char(1) DEFAULT '0',
  396. `chk3_opt3` char(1) DEFAULT '0',
  397. `chk3_opt4` char(1) DEFAULT '0',
  398. `chk4_opt0` char(1) DEFAULT '0',
  399. `chk4_opt1` char(1) DEFAULT '0',
  400. `chk4_opt2` char(1) DEFAULT '0',
  401. `chk4_opt3` char(1) DEFAULT '0',
  402. `chk4_opt4` char(1) DEFAULT '0',
  403. `chk5_opt0` char(1) DEFAULT '0',
  404. `chk5_opt1` char(1) DEFAULT '0',
  405. `chk5_opt2` char(1) DEFAULT '0',
  406. `chk5_opt3` char(1) DEFAULT '0',
  407. `chk5_opt4` char(1) DEFAULT '0',
  408. `chk6_opt0` char(1) DEFAULT '0',
  409. `chk6_opt1` char(1) DEFAULT '0',
  410. `chk6_opt2` char(1) DEFAULT '0',
  411. `chk6_opt3` char(1) DEFAULT '0',
  412. `chk6_opt4` char(1) DEFAULT '0',
  413. `chk7_opt0` char(1) DEFAULT '0',
  414. `chk7_opt1` char(1) DEFAULT '0',
  415. `chk7_opt2` char(1) DEFAULT '0',
  416. `chk7_opt3` char(1) DEFAULT '0',
  417. `chk7_opt4` char(1) DEFAULT '0',
  418. `chk8_opt0` char(1) DEFAULT '0',
  419. `chk8_opt1` char(1) DEFAULT '0',
  420. `chk8_opt2` char(1) DEFAULT '0',
  421. `chk8_opt3` char(1) DEFAULT '0',
  422. `chk8_opt4` char(1) DEFAULT '0',
  423. `chk9_opt0` char(1) DEFAULT '0',
  424. `chk9_opt1` char(1) DEFAULT '0',
  425. `chk9_opt2` char(1) DEFAULT '0',
  426. `chk9_opt3` char(1) DEFAULT '0',
  427. `chk9_opt4` char(1) DEFAULT '0',
  428. PRIMARY KEY (`id`)
  429. ) ENGINE=InnoDB AUTO_INCREMENT=104 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  430. drop table if exists crm_account_item;
  431. CREATE TABLE `crm_account_item` (
  432. `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  433. `created_on` bigint(11) NOT NULL,
  434. `updated_on` bigint(11) NOT NULL,
  435. `account_id` int(10) unsigned NOT NULL,
  436. `item_name` varchar(64) DEFAULT NULL,
  437. `str0` varchar(64) DEFAULT NULL,
  438. `str1` varchar(64) DEFAULT NULL,
  439. `str2` varchar(64) DEFAULT NULL,
  440. `str3` varchar(64) DEFAULT NULL,
  441. `str4` varchar(64) DEFAULT NULL,
  442. `str5` varchar(64) DEFAULT NULL,
  443. `str6` varchar(64) DEFAULT NULL,
  444. `str7` varchar(64) DEFAULT NULL,
  445. `str8` varchar(64) DEFAULT NULL,
  446. `str9` varchar(64) DEFAULT NULL,
  447. `rng0` varchar(64) DEFAULT NULL,
  448. `rng1` varchar(64) DEFAULT NULL,
  449. `rng2` varchar(64) DEFAULT NULL,
  450. `rng3` varchar(64) DEFAULT NULL,
  451. `rng4` varchar(64) DEFAULT NULL,
  452. `rng5` varchar(64) DEFAULT NULL,
  453. `rng6` varchar(64) DEFAULT NULL,
  454. `rng7` varchar(64) DEFAULT NULL,
  455. `rng8` varchar(64) DEFAULT NULL,
  456. `rng9` varchar(64) DEFAULT NULL,
  457. `dec0` decimal(20,4) DEFAULT 0.0000,
  458. `dec1` decimal(20,4) DEFAULT 0.0000,
  459. `dec2` decimal(20,4) DEFAULT 0.0000,
  460. `dec3` decimal(20,4) DEFAULT 0.0000,
  461. `dec4` decimal(20,4) DEFAULT 0.0000,
  462. `dec5` decimal(20,4) DEFAULT 0.0000,
  463. `dec6` decimal(20,4) DEFAULT 0.0000,
  464. `dec7` decimal(20,4) DEFAULT 0.0000,
  465. `dec8` decimal(20,4) DEFAULT 0.0000,
  466. `dec9` decimal(20,4) DEFAULT 0.0000,
  467. `chk0_opt0` char(1) DEFAULT '0',
  468. `chk0_opt1` char(1) DEFAULT '0',
  469. `chk0_opt2` char(1) DEFAULT '0',
  470. `chk0_opt3` char(1) DEFAULT '0',
  471. `chk0_opt4` char(1) DEFAULT '0',
  472. `chk1_opt0` char(1) DEFAULT '0',
  473. `chk1_opt1` char(1) DEFAULT '0',
  474. `chk1_opt2` char(1) DEFAULT '0',
  475. `chk1_opt3` char(1) DEFAULT '0',
  476. `chk1_opt4` char(1) DEFAULT '0',
  477. `chk2_opt0` char(1) DEFAULT '0',
  478. `chk2_opt1` char(1) DEFAULT '0',
  479. `chk2_opt2` char(1) DEFAULT '0',
  480. `chk2_opt3` char(1) DEFAULT '0',
  481. `chk2_opt4` char(1) DEFAULT '0',
  482. `chk3_opt0` char(1) DEFAULT '0',
  483. `chk3_opt1` char(1) DEFAULT '0',
  484. `chk3_opt2` char(1) DEFAULT '0',
  485. `chk3_opt3` char(1) DEFAULT '0',
  486. `chk3_opt4` char(1) DEFAULT '0',
  487. `chk4_opt0` char(1) DEFAULT '0',
  488. `chk4_opt1` char(1) DEFAULT '0',
  489. `chk4_opt2` char(1) DEFAULT '0',
  490. `chk4_opt3` char(1) DEFAULT '0',
  491. `chk4_opt4` char(1) DEFAULT '0',
  492. `chk5_opt0` char(1) DEFAULT '0',
  493. `chk5_opt1` char(1) DEFAULT '0',
  494. `chk5_opt2` char(1) DEFAULT '0',
  495. `chk5_opt3` char(1) DEFAULT '0',
  496. `chk5_opt4` char(1) DEFAULT '0',
  497. `chk6_opt0` char(1) DEFAULT '0',
  498. `chk6_opt1` char(1) DEFAULT '0',
  499. `chk6_opt2` char(1) DEFAULT '0',
  500. `chk6_opt3` char(1) DEFAULT '0',
  501. `chk6_opt4` char(1) DEFAULT '0',
  502. `chk7_opt0` char(1) DEFAULT '0',
  503. `chk7_opt1` char(1) DEFAULT '0',
  504. `chk7_opt2` char(1) DEFAULT '0',
  505. `chk7_opt3` char(1) DEFAULT '0',
  506. `chk7_opt4` char(1) DEFAULT '0',
  507. `chk8_opt0` char(1) DEFAULT '0',
  508. `chk8_opt1` char(1) DEFAULT '0',
  509. `chk8_opt2` char(1) DEFAULT '0',
  510. `chk8_opt3` char(1) DEFAULT '0',
  511. `chk8_opt4` char(1) DEFAULT '0',
  512. `chk9_opt0` char(1) DEFAULT '0',
  513. `chk9_opt1` char(1) DEFAULT '0',
  514. `chk9_opt2` char(1) DEFAULT '0',
  515. `chk9_opt3` char(1) DEFAULT '0',
  516. `chk9_opt4` char(1) DEFAULT '0',
  517. PRIMARY KEY (`id`)
  518. ) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  519. INSERT INTO pro_item_revsum ( id, created_on, updated_on)
  520. SELECT id, UNIX_TIMESTAMP(), UNIX_TIMESTAMP()
  521. FROM dbr_item
  522. where 1;