sqlx:fixed get follow index tweets incorrect problem

r/paopao-ce-plus paopao-ce-plus/v0.5.0-rc.2
Michael Li 2 years ago
parent 4a49693493
commit 96f124423e
No known key found for this signature in database

@ -110,7 +110,7 @@ const (
_Tweet_GetAnyPostCount = `SELECT count(*) FROM @post WHERE visibility IN (?)`
_Tweet_GetAnyPosts = `SELECT * FROM @post WHERE visibility IN (?) AND is_del=0 LIMIT ? OFFSET ?`
_Tweet_GetBeFollowIds = `SELECT follow_id FROM @following WHERE user_id=? AND is_del=0`
_Tweet_GetBeFriendIds = `SELECT user_id FROM @contact WHERE friend_id=? AND is_del=0`
_Tweet_GetBeFriendIds = `SELECT user_id FROM @contact WHERE friend_id=? AND status=2 AND is_del=0`
_Tweet_GetPostAttachmentBill = `SELECT * FROM @post_attachment_bill WHERE post_id=? AND user_id=? AND is_del=0`
_Tweet_GetPostById = `SELECT * FROM @post WHERE id=? AND is_del=0`
_Tweet_GetPostContentById = `SELECT * FROM @post_content WHERE id=? AND is_del=0`

@ -1198,7 +1198,7 @@ WHERE user_id=? AND is_del=0;
-- name: get_be_friend_ids@tweet
-- prepare: stmt
SELECT user_id FROM @contact WHERE friend_id=? AND is_del=0;
SELECT user_id FROM @contact WHERE friend_id=? AND status=2 AND is_del=0;
-- name: get_be_follow_ids@tweet
-- prepare: stmt

Loading…
Cancel
Save