Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old

FM.SQL.FieldCount

Queries number of fields.

Component Version macOS Windows Linux Server iOS SDK
FM FMSQL 5.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "FM.SQL.FieldCount"; SQLref )   More

Parameters

Parameter Description Example
SQLref The reference number returned by FM.SQL.Execute function. $SQLRef

Result

Returns number or error.

Description

Queries number of fields.

Examples

Query some values:

Set Variable [$sql; Value:MBS( "FM.SQL.Execute"; ""; "select * from Clients")]
If [MBS("IsError")]
    Show Custom Dialog ["SQL error"; $sql]
Else
    Show Custom Dialog ["SQL result"; "got " & MBS( "FM.SQL.RowCount"; $sql ) &" rows with each " & MBS( "FM.SQL.FieldCount"; $sql ) & " …"]
    Set Variable [$r; Value:MBS( "FM.SQL.Release"; $sql )]
End If

See also

Example Databases

Blog Entries

This function is free to use.

Created 18th April 2015, last changed 8th January 2017


FM.SQL.Field - FM.SQL.FieldType