www.Inmagic.com    Inmagic Forums    Inmagic Forums  Hop To Forum Categories  ODBC    How to limit the number of results returned by a query?
Go
New
Find
Notify
Tools
Reply
  
-star Rating Rate It!  Login/Join 
MF
Posted
Is there a way to limit the number of results returned by a query?

In SQL you could do this "SELECT TOP 100 Record_Number FROM Records" and it would return 100 results.

Is there an equivalent syntax to use with ODBC driver?
 
Posts: 5 | Registered: Tue August 21 2007Reply With QuoteEdit or Delete MessageReport This Post
Posted Hide Post
Does anyone have a solution/work around for this? I've discovered that the ODBC driver does not recognize the 'LIMIT' command either.

The only workaround I have is to import the entire contents of the database via the query and then limit the results in the coding itself. It would be a lot faster if I could just limit the number of results in the SQL query.
 
Posts: 25 | Location: Brampton, Ontario, Canada | Registered: Wed November 01 2000Reply With QuoteEdit or Delete MessageReport This Post
Posted Hide Post
The Inmagic ODBC command subset is very limited. I wonder if it would EXEC a stored procedure?


Peter Tyrrell, MLIS
Senior Consultant
Andornot Consulting Inc.
http://www.andornot.com/about/developerblog
 
Posts: 179 | Location: Vancouver, BC, Canada | Registered: Thu September 20 2001Reply With QuoteEdit or Delete MessageReport This Post
Posted Hide Post
quote:
Originally posted by Peter Tyrrell:
The Inmagic ODBC command subset is very limited. I wonder if it would EXEC a stored procedure?


On that note, I need to pass a huge SQL statement to DB/Textworks. If I try to pass the whole thing at once, the ODBC driver will clip it. I can break it down into several smaller SQL statements but then passing a number of SQL statements through ODBC really slows the page down.

Is there a way to create stored procedures with Inmagic? Can anyone recommend a better method for passing large SQL statements through ODBC?
 
Posts: 25 | Location: Brampton, Ontario, Canada | Registered: Wed November 01 2000Reply With QuoteEdit or Delete MessageReport This Post
 Previous Topic | Next Topic powered by eve community  
 

www.Inmagic.com    Inmagic Forums    Inmagic Forums  Hop To Forum Categories  ODBC    How to limit the number of results returned by a query?