![]() |
Next Page |
| Contents > Functions reference (alphabetical list) > Logical functions > LookupNext function |
|
|
| LookupNext function |
| Format |
LookupNext(sourceField;lower/higherFlag) |
| Parameters |
| sourceField - the field from which the lookup value is taken. |
| lower/higherFlag - the keywords lower or higher denote whether the value from the next lower/higher matching record must be taken if the lookup fails. |
| Data type returned |
| text, number, date, time, timestamp, container |
| Description |
| Returns the value specified in sourceField using the relationships in the relationships graph. If the lookup fails, the value from the source field in the next lower or higher matching record will be returned, as specified by lower/higherFlag. In order for this function to access the value in sourceField, the tables containing the source field and calculation field need to be related. Calculations using the LookupNext function won't be forced to be unstored calculations. |
| Note LookupNext returns ? when the related table is an ODBC data source. |
| Example |
| There are two tables, People and Company, in a database file containing data as shown below. |
| People table |
|
|
| Company table |
|
|
| Related topics |
| Functions reference (category list) |
| Functions reference (alphabetical list) |
| About formulas |
| About functions |
| Defining calculation fields |
| Using operators in formulas |
|
|
| Contents > Functions reference (alphabetical list) > Logical functions > LookupNext function | Next Page |