Commit 56b3294d authored by 赵建伟's avatar 赵建伟

add sql format codes

parent 2caf2fc6
package com.gmei.data.dqmp.domain;
public class TblIndicatorOperatorInfo {
private Integer id;
private String indicatorName;
private String operatorExpr;
private String comment;
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getIndicatorName() {
return indicatorName;
}
public void setIndicatorName(String indicatorName) {
this.indicatorName = indicatorName == null ? null : indicatorName.trim();
}
public String getOperatorExpr() {
return operatorExpr;
}
public void setOperatorExpr(String operatorExpr) {
this.operatorExpr = operatorExpr == null ? null : operatorExpr.trim();
}
public String getComment() {
return comment;
}
public void setComment(String comment) {
this.comment = comment == null ? null : comment.trim();
}
}
\ No newline at end of file
package com.gmei.data.dqmp.domain;
public class TblRuleDuplexInfo {
private Integer id;
private String checkType;
private String checkDbName;
private String checkTbName;
private String checkColName;
private String referDbName;
private String referTbName;
private String referColName;
private Integer isPartitioned;
private Integer isValid;
private String checkTime;
private String createTime;
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getCheckType() {
return checkType;
}
public void setCheckType(String checkType) {
this.checkType = checkType == null ? null : checkType.trim();
}
public String getCheckDbName() {
return checkDbName;
}
public void setCheckDbName(String checkDbName) {
this.checkDbName = checkDbName == null ? null : checkDbName.trim();
}
public String getCheckTbName() {
return checkTbName;
}
public void setCheckTbName(String checkTbName) {
this.checkTbName = checkTbName == null ? null : checkTbName.trim();
}
public String getCheckColName() {
return checkColName;
}
public void setCheckColName(String checkColName) {
this.checkColName = checkColName == null ? null : checkColName.trim();
}
public String getReferDbName() {
return referDbName;
}
public void setReferDbName(String referDbName) {
this.referDbName = referDbName == null ? null : referDbName.trim();
}
public String getReferTbName() {
return referTbName;
}
public void setReferTbName(String referTbName) {
this.referTbName = referTbName == null ? null : referTbName.trim();
}
public String getReferColName() {
return referColName;
}
public void setReferColName(String referColName) {
this.referColName = referColName == null ? null : referColName.trim();
}
public Integer getIsPartitioned() {
return isPartitioned;
}
public void setIsPartitioned(Integer isPartitioned) {
this.isPartitioned = isPartitioned;
}
public Integer getIsValid() {
return isValid;
}
public void setIsValid(Integer isValid) {
this.isValid = isValid;
}
public String getCheckTime() {
return checkTime;
}
public void setCheckTime(String checkTime) {
this.checkTime = checkTime == null ? null : checkTime.trim();
}
public String getCreateTime() {
return createTime;
}
public void setCreateTime(String createTime) {
this.createTime = createTime == null ? null : createTime.trim();
}
}
\ No newline at end of file
package com.gmei.data.dqmp.domain;
public class TblRuleDuplexInfoWithBLOBs extends TblRuleDuplexInfo {
private String checkFilters;
private String referFilters;
public String getCheckFilters() {
return checkFilters;
}
public void setCheckFilters(String checkFilters) {
this.checkFilters = checkFilters == null ? null : checkFilters.trim();
}
public String getReferFilters() {
return referFilters;
}
public void setReferFilters(String referFilters) {
this.referFilters = referFilters == null ? null : referFilters.trim();
}
}
\ No newline at end of file
package com.gmei.data.dqmp.domain;
public class TblRuleSimpleInfo {
private Integer id;
private String checkType;
private String dbName;
private String tbName;
private String colName;
private String indicatorType;
private String startTime;
private String endTime;
private Integer isPartitioned;
private Integer isValid;
private String checkTime;
private String createTime;
private String filters;
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getCheckType() {
return checkType;
}
public void setCheckType(String checkType) {
this.checkType = checkType == null ? null : checkType.trim();
}
public String getDbName() {
return dbName;
}
public void setDbName(String dbName) {
this.dbName = dbName == null ? null : dbName.trim();
}
public String getTbName() {
return tbName;
}
public void setTbName(String tbName) {
this.tbName = tbName == null ? null : tbName.trim();
}
public String getColName() {
return colName;
}
public void setColName(String colName) {
this.colName = colName == null ? null : colName.trim();
}
public String getIndicatorType() {
return indicatorType;
}
public void setIndicatorType(String indicatorType) {
this.indicatorType = indicatorType == null ? null : indicatorType.trim();
}
public String getStartTime() {
return startTime;
}
public void setStartTime(String startTime) {
this.startTime = startTime == null ? null : startTime.trim();
}
public String getEndTime() {
return endTime;
}
public void setEndTime(String endTime) {
this.endTime = endTime == null ? null : endTime.trim();
}
public Integer getIsPartitioned() {
return isPartitioned;
}
public void setIsPartitioned(Integer isPartitioned) {
this.isPartitioned = isPartitioned;
}
public Integer getIsValid() {
return isValid;
}
public void setIsValid(Integer isValid) {
this.isValid = isValid;
}
public String getCheckTime() {
return checkTime;
}
public void setCheckTime(String checkTime) {
this.checkTime = checkTime == null ? null : checkTime.trim();
}
public String getCreateTime() {
return createTime;
}
public void setCreateTime(String createTime) {
this.createTime = createTime == null ? null : createTime.trim();
}
public String getFilters() {
return filters;
}
public void setFilters(String filters) {
this.filters = filters == null ? null : filters.trim();
}
}
\ No newline at end of file
package com.gmei.data.dqmp.mapper;
import com.gmei.data.dqmp.domain.TblIndicatorOperatorInfo;
import com.gmei.data.dqmp.domain.TblIndicatorOperatorInfoCriteria;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface TblIndicatorOperatorInfoMapper {
int countByExample(TblIndicatorOperatorInfoCriteria example);
int deleteByExample(TblIndicatorOperatorInfoCriteria example);
int deleteByPrimaryKey(Integer id);
int insert(TblIndicatorOperatorInfo record);
int insertSelective(TblIndicatorOperatorInfo record);
List<TblIndicatorOperatorInfo> selectByExample(TblIndicatorOperatorInfoCriteria example);
TblIndicatorOperatorInfo selectByPrimaryKey(Integer id);
int updateByExampleSelective(@Param("record") TblIndicatorOperatorInfo record, @Param("example") TblIndicatorOperatorInfoCriteria example);
int updateByExample(@Param("record") TblIndicatorOperatorInfo record, @Param("example") TblIndicatorOperatorInfoCriteria example);
int updateByPrimaryKeySelective(TblIndicatorOperatorInfo record);
int updateByPrimaryKey(TblIndicatorOperatorInfo record);
}
\ No newline at end of file
package com.gmei.data.dqmp.mapper;
import com.gmei.data.dqmp.domain.TblRuleDuplexInfo;
import com.gmei.data.dqmp.domain.TblRuleDuplexInfoCriteria;
import com.gmei.data.dqmp.domain.TblRuleDuplexInfoWithBLOBs;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface TblRuleDuplexInfoMapper {
int countByExample(TblRuleDuplexInfoCriteria example);
int deleteByExample(TblRuleDuplexInfoCriteria example);
int deleteByPrimaryKey(Integer id);
int insert(TblRuleDuplexInfoWithBLOBs record);
int insertSelective(TblRuleDuplexInfoWithBLOBs record);
List<TblRuleDuplexInfoWithBLOBs> selectByExampleWithBLOBs(TblRuleDuplexInfoCriteria example);
List<TblRuleDuplexInfo> selectByExample(TblRuleDuplexInfoCriteria example);
TblRuleDuplexInfoWithBLOBs selectByPrimaryKey(Integer id);
int updateByExampleSelective(@Param("record") TblRuleDuplexInfoWithBLOBs record, @Param("example") TblRuleDuplexInfoCriteria example);
int updateByExampleWithBLOBs(@Param("record") TblRuleDuplexInfoWithBLOBs record, @Param("example") TblRuleDuplexInfoCriteria example);
int updateByExample(@Param("record") TblRuleDuplexInfo record, @Param("example") TblRuleDuplexInfoCriteria example);
int updateByPrimaryKeySelective(TblRuleDuplexInfoWithBLOBs record);
int updateByPrimaryKeyWithBLOBs(TblRuleDuplexInfoWithBLOBs record);
int updateByPrimaryKey(TblRuleDuplexInfo record);
}
\ No newline at end of file
package com.gmei.data.dqmp.mapper;
import com.gmei.data.dqmp.domain.TblRuleSimpleInfo;
import com.gmei.data.dqmp.domain.TblRuleSimpleInfoCriteria;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface TblRuleSimpleInfoMapper {
int countByExample(TblRuleSimpleInfoCriteria example);
int deleteByExample(TblRuleSimpleInfoCriteria example);
int deleteByPrimaryKey(Integer id);
int insert(TblRuleSimpleInfo record);
int insertSelective(TblRuleSimpleInfo record);
List<TblRuleSimpleInfo> selectByExampleWithBLOBs(TblRuleSimpleInfoCriteria example);
List<TblRuleSimpleInfo> selectByExample(TblRuleSimpleInfoCriteria example);
TblRuleSimpleInfo selectByPrimaryKey(Integer id);
int updateByExampleSelective(@Param("record") TblRuleSimpleInfo record, @Param("example") TblRuleSimpleInfoCriteria example);
int updateByExampleWithBLOBs(@Param("record") TblRuleSimpleInfo record, @Param("example") TblRuleSimpleInfoCriteria example);
int updateByExample(@Param("record") TblRuleSimpleInfo record, @Param("example") TblRuleSimpleInfoCriteria example);
int updateByPrimaryKeySelective(TblRuleSimpleInfo record);
int updateByPrimaryKeyWithBLOBs(TblRuleSimpleInfo record);
int updateByPrimaryKey(TblRuleSimpleInfo record);
}
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="com.gmei.data.dqmp.mapper.TblIndicatorOperatorInfoMapper" >
<resultMap id="BaseResultMap" type="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfo" >
<id column="id" property="id" jdbcType="INTEGER" />
<result column="indicator_name" property="indicatorName" jdbcType="VARCHAR" />
<result column="operator_expr" property="operatorExpr" jdbcType="VARCHAR" />
<result column="comment" property="comment" jdbcType="VARCHAR" />
</resultMap>
<sql id="Example_Where_Clause" >
<where >
<foreach collection="oredCriteria" item="criteria" separator="or" >
<if test="criteria.valid" >
<trim prefix="(" suffix=")" prefixOverrides="and" >
<foreach collection="criteria.criteria" item="criterion" >
<choose >
<when test="criterion.noValue" >
and ${criterion.condition}
</when>
<when test="criterion.singleValue" >
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue" >
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue" >
and ${criterion.condition}
<foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause" >
<where >
<foreach collection="example.oredCriteria" item="criteria" separator="or" >
<if test="criteria.valid" >
<trim prefix="(" suffix=")" prefixOverrides="and" >
<foreach collection="criteria.criteria" item="criterion" >
<choose >
<when test="criterion.noValue" >
and ${criterion.condition}
</when>
<when test="criterion.singleValue" >
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue" >
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue" >
and ${criterion.condition}
<foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List" >
id, indicator_name, operator_expr, comment
</sql>
<select id="selectByExample" resultMap="BaseResultMap" parameterType="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfoCriteria" >
select
<if test="distinct" >
distinct
</if>
<include refid="Base_Column_List" />
from tbl_indicator_operator_info
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null" >
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
select
<include refid="Base_Column_List" />
from tbl_indicator_operator_info
where id = #{id,jdbcType=INTEGER}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
delete from tbl_indicator_operator_info
where id = #{id,jdbcType=INTEGER}
</delete>
<delete id="deleteByExample" parameterType="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfoCriteria" >
delete from tbl_indicator_operator_info
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfo" >
insert into tbl_indicator_operator_info (id, indicator_name, operator_expr,
comment)
values (#{id,jdbcType=INTEGER}, #{indicatorName,jdbcType=VARCHAR}, #{operatorExpr,jdbcType=VARCHAR},
#{comment,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfo" >
insert into tbl_indicator_operator_info
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="indicatorName != null" >
indicator_name,
</if>
<if test="operatorExpr != null" >
operator_expr,
</if>
<if test="comment != null" >
comment,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=INTEGER},
</if>
<if test="indicatorName != null" >
#{indicatorName,jdbcType=VARCHAR},
</if>
<if test="operatorExpr != null" >
#{operatorExpr,jdbcType=VARCHAR},
</if>
<if test="comment != null" >
#{comment,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfoCriteria" resultType="java.lang.Integer" >
select count(*) from tbl_indicator_operator_info
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map" >
update tbl_indicator_operator_info
<set >
<if test="record.id != null" >
id = #{record.id,jdbcType=INTEGER},
</if>
<if test="record.indicatorName != null" >
indicator_name = #{record.indicatorName,jdbcType=VARCHAR},
</if>
<if test="record.operatorExpr != null" >
operator_expr = #{record.operatorExpr,jdbcType=VARCHAR},
</if>
<if test="record.comment != null" >
comment = #{record.comment,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null" >
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map" >
update tbl_indicator_operator_info
set id = #{record.id,jdbcType=INTEGER},
indicator_name = #{record.indicatorName,jdbcType=VARCHAR},
operator_expr = #{record.operatorExpr,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR}
<if test="_parameter != null" >
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfo" >
update tbl_indicator_operator_info
<set >
<if test="indicatorName != null" >
indicator_name = #{indicatorName,jdbcType=VARCHAR},
</if>
<if test="operatorExpr != null" >
operator_expr = #{operatorExpr,jdbcType=VARCHAR},
</if>
<if test="comment != null" >
comment = #{comment,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="updateByPrimaryKey" parameterType="com.gmei.data.dqmp.domain.TblIndicatorOperatorInfo" >
update tbl_indicator_operator_info
set indicator_name = #{indicatorName,jdbcType=VARCHAR},
operator_expr = #{operatorExpr,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR}
where id = #{id,jdbcType=INTEGER}
</update>
</mapper>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment