MySql Query, Select greater than

后端 未结 4 2307
我在风中等你
我在风中等你 2021-02-20 03:26

I\'ve got a table, called faq_questions with the following structure:

id int not_null auto_increment,
question varchar(255),
sort_order int

I\'

4条回答
  •  春和景丽
    2021-02-20 04:33

    SELECT 
        id, question, sort_order
    FROM faq_questions 
    WHERE sort_order in 
    (SELECT 
            MIN(sort_order) 
        FROM faq_questions 
        WHERE sort_order > ?);
    

    That seems to work

提交回复
热议问题