Solved

SQL: how to limit number of records in select?

Posted on 2000-04-25
3
715 Views
Last Modified: 2010-04-04
I'm using paradox tables.  I wish to limit the number of returned records from a SQL select satement (the first 40 records) with varying ORDER BY parameters.
Can I do this?
0
Comment
Question by:rwv
3 Comments
 

Accepted Solution

by:
Shakari earned 100 total points
ID: 2747979
you can add to select a count command

select * from table1 order by field where count<41
0
 

Expert Comment

by:lgmm
ID: 2747995
the only way to do this is that you add a field in your end query  and use a statement in where

where field <= 40

im not sure if in delphi exists the recno() function , is similar the use

0
 
LVL 3

Expert Comment

by:shenqw
ID: 2750177
It's difficult to do that use only SQL in Paradox,Easy in Oracle & Ms SQL.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
how to center only a line in richedit? 4 69
Printing problem 2 110
RESTRequest Parameter 4 51
Delphi android app hide keyboard 3 36
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

680 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question