|
Posted by Steve on 01/30/08 20:10
"Ivan Marsh" <annoyed@you.now> wrote in message
news:pan.2008.01.30.17.44.49.792094@you.now...
> On Wed, 30 Jan 2008 11:34:57 -0600, Steve wrote:
>
>
>> "NC" <nc@iname.com> wrote in message
>> news:093fa743-0beb-4582-b9e2-8baaf8531f0b@s37g2000prg.googlegroups.com...
>>> On Jan 28, 1:37 pm, Martin <martinval...@comcast.net> wrote:
>>>>
>>>> I'm trying to adapt a PHP script that was written to use MySQL, so
>>>> that it will work with an MSAccess MDB file.
>>>
>>> Good luck...
>>>
>>>> An important part of the script makes use of the SQL "LIMIT" keyword
>>>> available in MySQL. eg: "SELECT MyField FROM MyTable LIMIT 40,10" to
>>>> select 10 records beginning at the 41st record.
>>>>
>>>> Can anyone tell me how I can achieve this same functionality when
>>>> using ODBC functions to access an MDB file?
>>>
>>> You can't. Access does not support LIMIT clauses.
>>
>> BULLSHIT !!!
>>
>> *acheive ... functionality*...the two key words. i've given an
>> explanation of at least one way...which falsifies your claim, btw.
>
> No... you have not.
christ almighty!!!
<quote>
the easiest way is to select into a temp table where one of the columns is
an auto-number...the query then becomes WHERE blah BETWEEN x AND n
</quote>
do you need the message id too?
but while i'm at it:
===========
create table companies
(
company NUMBER ,
name TEXT ,
region NUMBER
)
SELECT *
FROM
(
SELECT (
SELECT COUNT(*)
FROM companies AS r
WHERE r.Company < co.Company
) AS RowNum ,
co.Company AS Company ,
co.Name AS Name ,
co.Region AS Region
FROM companies AS co
)
WHERE RowNum BETWEEN 50 AND 100
ORDER BY RowNum
===========
fuck you very much.
oh, that would be explanation #2...demonstrated specifically for ms access.
[Back to original message]
|