Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SELECT news.*
- FROM (
- SELECT id
- FROM news
- WHERE cat_id= x
- ORDER BY
- id DESC
- LIMIT m, n
- ) o
- JOIN news
- ON news.id = o.id
- from u in news
- join n in
- (
- from x in news
- where x.cat_id = 10
- orderby x.Id descending
- select x
- ).Skip(10).Take(20) on u.Id equals n.Id
- select u
Add Comment
Please, Sign In to add comment