Professional Web Applications Themes

What kind of thing can occur after LIMIT? - MySQL

>From the manual, Select statement... SELECT [ALL | DISTINCT | DISTINCTROW ] [HIGH_PRIORITY] [STRAIGHT_JOIN] [SQL_SMALL_RESULT] [SQL_BIG_RESULT] [SQL_BUFFER_RESULT] [SQL_CACHE | SQL_NO_CACHE] [SQL_CALC_FOUND_ROWS] select_expr, ... [FROM table_references [WHERE where_condition] [GROUP BY {col_name | expr | position} [ASC | DESC], ... [WITH ROLLUP]] [HAVING where_condition] [ORDER BY {col_name | expr | position} [ASC | DESC], ...] [LIMIT {[offset,] row_count | row_count OFFSET offset}] [PROCEDURE procedure_name(argument_list)] [INTO OUTFILE 'file_name' export_options | INTO DUMPFILE 'file_name' | INTO var_name [, var_name]] [FOR UPDATE | LOCK IN SHARE MODE]] any real example when Limit is not at the end of the statetment? tanks...

  1. #1

    Default What kind of thing can occur after LIMIT?

    >From the manual,

    Select statement...

    SELECT
    [ALL | DISTINCT | DISTINCTROW ]
    [HIGH_PRIORITY]
    [STRAIGHT_JOIN]
    [SQL_SMALL_RESULT] [SQL_BIG_RESULT] [SQL_BUFFER_RESULT]
    [SQL_CACHE | SQL_NO_CACHE] [SQL_CALC_FOUND_ROWS]
    select_expr, ...
    [FROM table_references
    [WHERE where_condition]
    [GROUP BY {col_name | expr | position}
    [ASC | DESC], ... [WITH ROLLUP]]
    [HAVING where_condition]
    [ORDER BY {col_name | expr | position}
    [ASC | DESC], ...]
    [LIMIT {[offset,] row_count | row_count OFFSET offset}]
    [PROCEDURE procedure_name(argument_list)]
    [INTO OUTFILE 'file_name' export_options
    | INTO DUMPFILE 'file_name'
    | INTO var_name [, var_name]]
    [FOR UPDATE | LOCK IN SHARE MODE]]



    any real example when Limit is not at the end of the statetment?

    tanks

    howa Guest

  2. #2

    Default Re: What kind of thing can occur after LIMIT?

    howa <com> wrote:
     
    >
    > Select statement...
    >
    > SELECT
    > [ALL | DISTINCT | DISTINCTROW ]
    > [HIGH_PRIORITY]
    > [STRAIGHT_JOIN]
    > [SQL_SMALL_RESULT] [SQL_BIG_RESULT] [SQL_BUFFER_RESULT]
    > [SQL_CACHE | SQL_NO_CACHE] [SQL_CALC_FOUND_ROWS]
    > select_expr, ...
    > [FROM table_references
    > [WHERE where_condition]
    > [GROUP BY {col_name | expr | position}
    > [ASC | DESC], ... [WITH ROLLUP]]
    > [HAVING where_condition]
    > [ORDER BY {col_name | expr | position}
    > [ASC | DESC], ...]
    > [LIMIT {[offset,] row_count | row_count OFFSET offset}]
    > [PROCEDURE procedure_name(argument_list)]
    > [INTO OUTFILE 'file_name' export_options
    > | INTO DUMPFILE 'file_name'
    > | INTO var_name [, var_name]]
    > [FOR UPDATE | LOCK IN SHARE MODE]]
    >
    >
    >
    > any real example when Limit is not at the end of the statetment?[/ref]

    Take your pick, for instance:

    SELECT * FROM table LIMIT 10 INTO OUTFILE ('/path/to/file');
    --
    Rik Wasmus
    Posted on Usenet, not any forum you might see this in.
    Ask Smart Questions: http://tinyurl.com/anel
    Rik Guest

  3. #3

    Default Re: What kind of thing can occur after LIMIT?

    But seems INTO OUTFILE ('/path/to/file'); can be put before the FROM
    cause?

    so any statement must put at the end?



    On Mar 7, 4:17 am, Rik <com> wrote: [/ref]



    >
    > Take your pick, for instance:
    >
    > SELECT * FROM table LIMIT 10 INTO OUTFILE ('/path/to/file');
    > --
    > Rik Wasmus
    > Posted on Usenet, not any forum you might see this in.
    > Ask Smart Questions:http://tinyurl.com/anel[/ref]


    howa Guest

Similar Threads

  1. Where in the page lifecycle does validation occur?
    By paul.hester@gmail.com in forum ASP.NET Building Controls
    Replies: 3
    Last Post: August 26th, 07:45 AM
  2. Replies: 0
    Last Post: June 28th, 11:17 AM
  3. click event does not occur in webusercontrol
    By Simon Storr in forum ASP.NET General
    Replies: 0
    Last Post: July 14th, 09:52 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139