post list
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Simple_Not 2022-10-20 11:38:52 +10:00
parent f5349db697
commit e445c2bda1

View File

@ -34,13 +34,22 @@ namespace NeDvachAPI
conn.Open(); conn.Open();
// using ( var command = new NpgsqlCommand(@"
// SELECT * FROM
// (SELECT post_id, substring(post,1,200)
// FROM dvach
// ORDER BY post_id DESC
// limit 10
// )
subquery ORDER BY post_id ASC", conn) )
using ( var command = new NpgsqlCommand(@" using ( var command = new NpgsqlCommand(@"
SELECT * FROM SELECT * FROM
(SELECT post_id, substring(post,1,200) (
FROM dvach SELECT post_id, post
ORDER BY post_id DESC FROM dvach
) ORDER BY post_id DESC
subquery ORDER BY post_id ASC", conn) ) ) subquery
ORDER BY post_id ASC", conn) )
{ {
var reader = command.ExecuteReader(); var reader = command.ExecuteReader();