Difference between revisions of "FIELDINFO()"
Yvonnemilne (Talk | contribs) |
Yvonnemilne (Talk | contribs) |
||
| Line 17: | Line 17: | ||
Otherwise, the information string is structured as follows: | Otherwise, the information string is structured as follows: | ||
| + | |||
{| class="wikitable" | {| class="wikitable" | ||
| Line 52: | Line 53: | ||
==Example== | ==Example== | ||
<code lang="recital"> | <code lang="recital"> | ||
| + | open database southwind | ||
| + | use example | ||
| + | astore(a_info,fieldinfo(1,1),",") | ||
| + | display memory | ||
</code> | </code> | ||
Latest revision as of 15:51, 25 August 2011
Purpose
Function to return a string containing comma-separated information about a specified field
Syntax
FIELDINFO(<expN1> [, <expN2>])
See Also
ADESC(), AFIELDS(), ASTORE(), ASTRING(), DBF(), FIELD(), FIELDNAME(), FILTER(), FLDCOUNT(), FLDLIST(), FMT(), INDEXKEY(), LABEL(), NDX(), RTOS()
Description
The FIELDINFO() function is used to return a string containing comma-separated information about a specified field <expN1> in the currently selected table or the workarea/cursor numbered <expN2>. Fields are numbered from 1 to FLDCOUNT() according to their position in the table structure.
If <expN1> exceeds the number of fields in the table, or there is no currently selected table or no table open in workarea <expN2>, then FIELDINFO() returns a null string.
Otherwise, the information string is structured as follows:
| # | Value |
|---|---|
| 1 | Field name |
| 2 | Field type |
| 3 | Field width |
| 4 | Field decimals |
| 5 | Field description |
| 6 | Field default value |
| 7 | Field picture value |
| 8 | Field choices value |
| 9 | Field validation expression |
| 10 | Field validation error text |
| 11 | Field help/tooltip text |
| 12 | Field mandatory ("1" if True) |
| 13 | Field autoinc ("1" if True) |
Example
open database southwind use example astore(a_info,fieldinfo(1,1),",") display memory
Products
Recital Server, Recital