Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
bigdatainterservice
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
曹鹏
bigdatainterservice
Commits
b986771a
Commit
b986771a
authored
Jun 21, 2019
by
wangling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改sql,只取最新的网吧旅店信息
parent
c130caf8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
13 deletions
+18
-13
src/main/resources/mybatis/mapper/gxzxt/AjbkMapper.xml
+18
-13
No files found.
src/main/resources/mybatis/mapper/gxzxt/AjbkMapper.xml
View file @
b986771a
...
...
@@ -209,18 +209,22 @@
<include
refid =
"bkbzxx_where_sql"
/>
</select>
<select
id=
"selectBkrwbzxx"
parameterType=
"com.founder.interservice.bkxx.model.Bkbzxx"
resultType=
"com.founder.interservice.bkxx.model.Bkbzxx"
>
SELECT
t2.pk_value as pkValue,
t2.bzid as bzid,
t2.bkfknr as bkfknr,
t2.bkzyid as bkzyid,
t2.bkzy as bkzy,
t2.sffs as sffs,
t2.sfsc as sfsc,
t2.type as type,
t2.createdtime as createdtime
from Z_AJBK_BZXX t2
WHERE 1=1
<include
refid =
"bkbzxx_where_sql"
/>
SELECT *
FROM (SELECT ROW_NUMBER ()
OVER (PARTITION BY t2.bkzy ORDER BY t2.createdtime DESC)
rn,
t2.pk_value as pkValue,
t2.bzid as bzid,
t2.bkfknr as bkfknr,
t2.bkzyid as bkzyid,
t2.bkzy as bkzy,
t2.sffs as sffs,
t2.sfsc as sfsc,
t2.type as type,
t2.createdtime as createdtime
FROM Z_AJBK_BZXX t2
WHERE 1=1
<include
refid =
"bkbzxx_where_sql"
/>
)
WHERE rn = 1
</select>
</mapper>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment