<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    神魂顛倒

    Memo

       :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理 ::
      0 隨筆 :: 3 文章 :: 3 評論 :: 0 Trackbacks
  • The LIMIT clause can be used to constrain the number of rows returned by the SELECT statement. LIMIT takes one or two numeric arguments, which must both be non-negative integer constants (except when using prepared statements).

    With two arguments, the first argument specifies the offset of the first row to return, and the second specifies the maximum number of rows to return. The offset of the initial row is 0 (not 1):

    SELECT * FROM tbl LIMIT 5,10;  # Retrieve rows 6-15
    

    To retrieve all rows from a certain offset up to the end of the result set, you can use some large number for the second parameter. This statement retrieves all rows from the 96th row to the last:

    SELECT * FROM tbl LIMIT 95,18446744073709551615;
    

    With one argument, the value specifies the number of rows to return from the beginning of the result set:

    SELECT * FROM tbl LIMIT 5;     # Retrieve first 5 rows
    

    In other words, LIMIT row_count is equivalent to LIMIT 0, row_count.

    For prepared statements, you can use placeholders. The following statements will return one row from the tbl table:

    SET @a=1;
    PREPARE STMT FROM 'SELECT * FROM tbl LIMIT ?';
    EXECUTE STMT USING @a;
    

    The following statements will return the second to sixth row from the tbl table:

    SET @skip=1; SET @numrows=5;
    PREPARE STMT FROM 'SELECT * FROM tbl LIMIT ?, ?';
    EXECUTE STMT USING @skip, @numrows;
    

    For compatibility with PostgreSQL, MySQL also supports the LIMIT row_count OFFSET offset syntax.

  • (select * order by id LIMIT 35,20)

    posted on 2008-04-06 23:47 star 閱讀(104) 評論(0)  編輯  收藏 所屬分類: MySQL

    只有注冊用戶登錄后才能發表評論。


    網站導航:
     
    主站蜘蛛池模板: 国产AV无码专区亚洲AV漫画| 亚洲国产一级在线观看| 日本亚洲成高清一区二区三区| 男人和女人高潮免费网站| 亚洲一区二区精品视频| 国产免费高清69式视频在线观看| 亚洲人成无码网WWW| av片在线观看永久免费| 久久亚洲综合色一区二区三区| 精品国产污污免费网站| 亚洲AV美女一区二区三区| 久久免费看黄a级毛片| 亚洲黄页网在线观看| 四虎在线播放免费永久视频| 日韩大片在线永久免费观看网站| 中文字幕在线亚洲精品| 午夜精品一区二区三区免费视频| 亚洲小说区图片区| 永久免费视频v片www| 亚欧乱色国产精品免费视频| 亚洲av网址在线观看| 国产情侣激情在线视频免费看| 亚洲第一成年免费网站| 国产午夜亚洲精品午夜鲁丝片| 99ee6热久久免费精品6| 亚洲午夜无码久久久久小说| 亚洲一级片免费看| 亚洲最大免费视频网| 看成年女人免费午夜视频| 亚洲AV无码一区二区二三区入口 | 哒哒哒免费视频观看在线www | 人人玩人人添人人澡免费| 亚洲乱人伦精品图片| 免费国产怡红院在线观看| 在线成人精品国产区免费| 亚洲已满18点击进入在线观看| 亚洲国产精品一区二区九九| 免费精品一区二区三区第35| 亚洲乱理伦片在线观看中字| 亚洲一区二区三区香蕉| 成人免费视频88|