<![CDATA[select t1.* from (SELECT t1.ACTIVE, t1.CODE, t1.COMPANY_ID, t1.CREATE_DATE, t1.CREATE_UID, t21.NAME AS CREATE_UNAME, t1.ID, t1.IMPLEMENTATION, t1.NAME, t1.NUMBER_INCREMENT, t1.NUMBER_NEXT, t1.PADDING, t1.PREFIX, t1.SUFFIX, t1.USE_DATE_RANGE, t1.WRITE_DATE, t1.WRITE_UID, t41.NAME AS WRITE_UNAME FROM IR_SEQUENCE t1 LEFT JOIN RES_USERS t11 ON t1.CREATE_UID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN RES_USERS t31 ON t1.WRITE_UID = t31.ID LEFT JOIN RES_PARTNER t41 ON t31.PARTNER_ID = t41.ID ) t1 where id=#{id}]]>
<![CDATA[select t1.* from (SELECT t1.CREATE_DATE, t1.CREATE_UID, t21.NAME AS CREATE_UNAME, t1.DATE_FROM, t1.DATE_TO, t1.ID, t1.NUMBER_NEXT, t1.SEQUENCE_ID, t1.WRITE_DATE, t1.WRITE_UID, t41.NAME AS WRITE_UNAME FROM IR_SEQUENCE_DATE_RANGE t1 LEFT JOIN RES_USERS t11 ON t1.CREATE_UID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN RES_USERS t31 ON t1.WRITE_UID = t31.ID LEFT JOIN RES_PARTNER t41 ON t31.PARTNER_ID = t41.ID ) t1 where id=#{id}]]>
<where><iftest="ew!=null and ew.sqlSegment!=null and !ew.emptyOfWhere">${ew.sqlSegment}</if></where>
<iftest="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">${ew.sqlSegment}</if>
</select>
<!--数据查询[Default]-->
<sqlid="Default"databaseId="postgresql">
<![CDATA[ SELECT t1.CREATE_DATE, t1.CREATE_UID, t21.NAME AS CREATE_UNAME, t1.DATE_FROM, t1.DATE_TO, t1.ID, t1.NUMBER_NEXT, t1.SEQUENCE_ID, t1.WRITE_DATE, t1.WRITE_UID, t41.NAME AS WRITE_UNAME FROM IR_SEQUENCE_DATE_RANGE t1 LEFT JOIN RES_USERS t11 ON t1.CREATE_UID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN RES_USERS t31 ON t1.WRITE_UID = t31.ID LEFT JOIN RES_PARTNER t41 ON t31.PARTNER_ID = t41.ID
]]>
</sql>
<!--数据查询[View]-->
<sqlid="View"databaseId="postgresql">
<![CDATA[ SELECT t1.CREATE_DATE, t1.CREATE_UID, t21.NAME AS CREATE_UNAME, t1.DATE_FROM, t1.DATE_TO, t1.ID, t1.NUMBER_NEXT, t1.SEQUENCE_ID, t1.WRITE_DATE, t1.WRITE_UID, t41.NAME AS WRITE_UNAME FROM IR_SEQUENCE_DATE_RANGE t1 LEFT JOIN RES_USERS t11 ON t1.CREATE_UID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN RES_USERS t31 ON t1.WRITE_UID = t31.ID LEFT JOIN RES_PARTNER t41 ON t31.PARTNER_ID = t41.ID