LassoScript Utility
Basics Browse Detail

-MaxRows

Tag Link -MaxRows Category Database
Type Command Source Available No
Support Synonym Version 3.0
Change Unchanged Data Source Any
Output Type None Security None
Implementation LCAPI Sets Lasso 8.5, Lasso 8.0, Lasso 7.0, Lasso 6.0, Lasso 5.0, Lasso 3.x

Description

-MaxRows specifies the maximum number of records which should be displayed on each page from a -Search or -FindAll action. The default is 50 if no -MaxRows tag is specified. Synonym is -MaxRecords.

This tag can be used in concert with the -SkipRows tag to page through a found set.

The value specified for this command tag can be retrieved using the [MaxRows_Value] tag.

Syntax

[Inline: -MaxRows=MaxRows_Value, ...]

<a href="default.lasso?-MaxRows=MaxRows_Value&...">Link</a>

<form action="default.lasso" method="POST">
  <input type="hidden" name="-MaxRows" value="MaxRows_Value">
  ...
</form>

Parameters

Required Parameters
MaxRows_Value Specifies the number of records which should be returned.

Examples

To specify how many records to return from a database action:

Use the -MaxRows command tag. The following example specifies a -Search action in [Inline] ... [/Inline] tags. Only one record is returned since -MaxRows=1 is specified.

[Inline: -Search,
    -Database='Contacts',
    -Table='People',
    -MaxRows=1,
    'First_Name'='John']
  [Records]
    <br>[Field: 'First_Name'] [Field: 'Last_Name']
  [/Records]
[/Inline]

<br>John Doe