From c007f0ca1785db093d48f4846cda82fe8e955765 Mon Sep 17 00:00:00 2001 From: kimi <kimi42345@gmail.com> Date: 星期三, 27 五月 2020 09:59:29 +0800 Subject: [PATCH] merage --- src/main/java/com/highdatas/mdm/util/Constant.java | 50 +++++++++++++++++++++++++++++++++++++++++++++----- 1 files changed, 45 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/highdatas/mdm/util/Constant.java b/src/main/java/com/highdatas/mdm/util/Constant.java index f154c21..3c2fe43 100644 --- a/src/main/java/com/highdatas/mdm/util/Constant.java +++ b/src/main/java/com/highdatas/mdm/util/Constant.java @@ -9,6 +9,7 @@ public static final String COMMA = " , "; public static final String COMMA_TRIM = ","; public static final String WHERE_DEFAULT = " 1 = 1 "; + public static final String WHERE_DEFAULTUN = " 1 <> 1 "; public static final String SEGMENT_COMMON = "value = {0}"; public static final String SEGMENT_STRING = "value = '{0}'"; public static final String EQUAL = " = "; @@ -45,16 +46,17 @@ String StructureMenu = "StructureMenu"; String tableName = "tableName"; String Alias = "{0}.{1}"; + String extent = "{0}~{1}"; String FieldAsAlias = "{0} AS {1}"; String caseWhen = " case when a2.{0} != null then a2.{0} else a1.{0} end as {0}"; String H = "h"; String A1 = "a1"; String A2 = "a2"; String All = "all"; + String All_UPCASE = "All"; String DataMenu = "DataMenu"; String AND = " and "; String MD = "md_"; - String CNT = "cnt"; String checkFieldSqlTemplate = "select count(1) as cnt from (select {0} from {1}) a1"; @@ -65,7 +67,7 @@ String STEP_READ_FROM_TABLE = "Read data from table"; String STEP_INSERT_UPDATE = "Insert or update"; String STEP_DUMMY = "Dummy"; - String MYSQL_UUID = "replace(UUID(),'-', '')"; + String MYSQL_UUID = " UUID_SHORT() "; String TYPE = "type"; String Active = "active"; String AssembleTempTable = "hj_table_"; @@ -74,9 +76,9 @@ String CreateTableMysql = "CREATE TABLE IF NOT EXISTS `{0}` ({1}) ENGINE=InnoDB DEFAULT CHARSET=utf8;"; String checkTableByNameBySchema = "select table_name from information_schema.tables where table_schema={0} and table_name = {1};"; String Temp = "temp_"; - String Temp2RecordMySQLTemplate = "INSERT INTO {0} ({1}) SELECT {2}, replace(uuid(),''-'', '''') as std_id, replace(uuid(),''-'', '''') as id, 0 as deal from {3}"; - String MYSQLJoinUpdateSql = "INSERT INTO {0} ({1}) SELECT {2} , replace(uuid(),''-'', '''') as id, s1.id as std_id, 0 as deal FROM {3} t1 inner join {4} s1 on {5};"; - String MYSQLJoinAddSql = "INSERT INTO {0} ({1}) SELECT {2} , replace(uuid(),''-'', '''') as std_id, replace(uuid(),''-'', '''') as id, 0 as deal FROM {3} t1 WHERE NOT EXISTS(SELECT * FROM {4} s1 WHERE {5});"; + String Temp2RecordMySQLTemplate = "INSERT INTO {0} ({1}) SELECT {2}, UUID_SHORT() as std_id, UUID_SHORT() as id, 0 as deal from {3}"; + String MYSQLJoinUpdateSql = "INSERT INTO {0} ({1}) SELECT {2} , UUID_SHORT() as id, s1.id as std_id, 0 as deal FROM {3} t1 inner join {4} s1 on {5};"; + String MYSQLJoinAddSql = "INSERT INTO {0} ({1}) SELECT {2} , UUID_SHORT() as std_id, UUID_SHORT() as id, 0 as deal FROM {3} t1 WHERE NOT EXISTS(SELECT * FROM {4} s1 WHERE {5});"; String Temp2RecordHbaseTemplate = "INSERT INTO {0} ({1}) SELECT ({2}, ) from {3}"; String ParamsShell = "@\\{{0}\\}"; String Cron = "cron"; @@ -100,4 +102,42 @@ String sucPercent = "sucPercent"; String varchar = "varchar"; String varcharSize = " (255) "; + String Text = " text "; + String Default = "default"; + String USERID = "user_id"; + String FIELD = "field"; + String DISTINCT = "distinct {0}"; + String InSql = "{0} in ( {1} )"; + String asTempSql = "( {0} ) {1}"; + String z_AllVal = "z_AllVal"; + + int queueSize = 20; + int cntCoefficient = 50; + String VIEW = "view_"; + String InnerJoinTemplate = " {0} {1} on {2}"; + String changedField = "change_field"; + String XLS = "xls"; + String xlsx = "xlsx"; + String LeftJoin = " left join "; + String InnerJoin = " inner join "; + String Pre = "pre"; + String PreValue = "鍘熷鍊�"; + String fix = "fix"; + String fixValue = "杞崲鍊�"; + String userDO = "userDO"; + String MasterDispense = "Master-Dispense"; + String Master = "master"; + String View = "view"; + String Token = "token"; + + int MaxDispenseSize = Double.valueOf(1024 * 1024 * 0.5).intValue(); + String RECORDS = "records"; + String SUCCESSCODE = "200"; + String Star = "*"; + String operate = "operate"; + String timeZone = "serverTimezone"; + String TM = "tm"; + String MT = "mt"; + String IDX_TEMPLATE = "IDX_{0}_{1}"; + } -- Gitblit v1.8.0