仅当上个月有一条记录时才检索去年的数据
我有两个表
USER
和 TRANSACTION
我想从 TRANSACTION
表中选择过去一年的数据,如果 USER
> 上个月进行的任何交易
USER
和 TRANSACTION
表都使用 USER_ID
连接,
这将如何实现?
I have two tables
USER
and TRANSACTION
i want to choose the data from TRANSACTION
table for last one year if the USER
has made any transaction in the last month
USER
and TRANSACTION
table are connected using USER_ID
how can it will be achieved?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
列出上个月活跃用户去年的交易:(
您不需要
USERS
表)list last year of transactions for users active in the last month:
(you don't need
USERS
table)