摘要: 表 stu (学生表) CREATE TABLE stu ( id INT (10) NOT NULL UNIQUE auto_increment PRIMARY KEY, NAME VARCHAR (255) NOT NULL UNIQUE ) ENGINE = INNODB charset = 阅读全文
posted @ 2021-06-17 15:45 Bonnie_ξ 阅读(551) 评论(0) 推荐(0)
摘要: SELECT NOW(),CURDATE(),CURTIME() 阅读全文
posted @ 2021-06-17 15:21 Bonnie_ξ 阅读(52) 评论(0) 推荐(0)
摘要: 定义和用法 CONCAT_WS - 用分隔符连接字符串。 语法 CONCAT_WS(separator,str1,str2,...) 用分隔符连接字符串,是CONCAT()的一种特殊形式。 第一个参数是其余参数的分隔符。 分隔符被添加到要连接的字符串之间。 分隔符可以是字符串,其余参数也可以。 如果 阅读全文
posted @ 2021-06-17 15:19 Bonnie_ξ 阅读(320) 评论(0) 推荐(0)
摘要: 0、创建一张数据表 表名为 test_when_case CREATE TABLE `test_when_case` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `type` tinyint(1) NOT NULL DEFAULT '0' COM 阅读全文
posted @ 2021-06-17 15:13 Bonnie_ξ 阅读(262) 评论(0) 推荐(0)
摘要: 当MyBatis 判断条件为等于的时候,常量需要加 .toString() 来转换,这种方法是稳定的,推荐使用,比如: <!-- 正确的,稳定,推荐使用 --> <if test="newsImage != null and newsImage == '0'.toString()"> <![CDAT 阅读全文
posted @ 2021-06-17 13:55 Bonnie_ξ 阅读(529) 评论(0) 推荐(0)
摘要: package com.zxwa.ntmss.process.common.util.date; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Calendar; import 阅读全文
posted @ 2021-06-17 11:46 Bonnie_ξ 阅读(56) 评论(0) 推荐(0)
摘要: 函数:FROM_UNIXTIME作用:将MYSQL中以INT(11)存储的时间以"YYYY-MM-DD"格式来显示。语法:FROM_UNIXTIME(unix_timestamp,format) 返回表示 Unix 时间标记的一个字符串,根据format字符串格式化。format可以包含与DATE_ 阅读全文
posted @ 2021-06-17 11:25 Bonnie_ξ 阅读(1196) 评论(0) 推荐(0)