<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../../../../style.css">
<title>
Gambas Documentation - DB.Limit
 (gb.db)</title>
</head>
<table class="none" width="100%" cellpadding="0" cellspacing="0" border="0">
<tr><td align="left">
<font size="-1">
<a href="../../../../help+en"><img class="flag" alt="Home" border="0" src="../../../../img/lang/en.png" align="center"></a>&nbsp;
<a href="../db+en">Up</a>&nbsp;
<a href="integer+en">Previous</a>&nbsp;
<a href="long+en">Next</a>&nbsp;
</td></tr></table>
<div class="notab">
<h1>
DB.Limit
 (gb.db)</h1>
<div class="black"><font size="-2"><b>Syntax</b></font></div>
<pre class="syntax"><font color="blue">STATIC</font> <font color="blue">FUNCTION</font> <b>Limit</b> <font color="blue">(</font> <u>Limit</u> <font color="blue">AS</font> <font color="#0080FF">Integer</font> <font color="blue">)</font> <font color="blue">AS</font> <font color="#0080FF"><a href="../connection+en">Connection</a></font></pre>
Limits the number of records returned by the next query.
<p>
After the query is executed, the number of returned records is reset to unlimited.
<p>
<div class="warning"><table class="none" border="0"><tr><td width="40" valign="top"><img border="0" src="../../../../img/tip.png" align="center"></td><td valign="top">
This method returns the connection it applies to, so that you can write something like that:
<tt>DB.Limit(X).Exec(...)</tt>
</td></tr></table></div>

</div>
</body>
</html>

