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

Files.Stat

Queries file status.

Component Version macOS Windows Linux Server iOS SDK
Files 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "Files.Stat"; Path { ; DontResolveSymlink } )   More

Parameters

Parameter Description Example Flags
Path The native file path to the file to be checked. "/Users/John/Desktop/test.txt"
DontResolveSymlink Pass 1 if you like to get information on a symlink file or pass 0 to follow the symbolic link.
Default is 0.

Ignored on Windows.
0 Optional

Result

Returns JSON or error.

Description

Queries file status.
This is a low level function to query file status as JSON.

FieldDescription
devID of device containing file
inoinode number
modeValueNumeric value for mode.
modeMode formatted as text.
typeThe type of this item. One of block device, character device, directory, pipe, symlink, file or socket.
nlinknumber of hard links to the file
uiduser ID of owner
gidgroup ID of owner
rdevdevice ID (if special file)
sizetotal size, in bytes
blocksnumber of 512B blocks allocated
blksizeblocksize for file system I/O
flagsuser defined flags for file
genfile generation number
atimeValuetime of last access
atimeThe time stamp as text.
mtimeValuetime of last modification
mtimeThe time stamp as text.
ctimeValuetime of last status change
ctimeThe time stamp as text.

blocks and blksize are not available on Windows.
flags and gen are only for iOS and macOS.

This function requires a native path. Use Path.FileMakerPathToNativePath to convert a FileMaker path to a native path if required. If you like to have the user choose the path, you can use FileDialog functions.
For Server be aware that server has limited permissions and may not be able to access all files on a computer.

Examples

Check folder on macOS:

MBS( "Files.Stat"; "/Users/cs/Documents" )

Example result:
{ "dev": 16777232, "ino": 231396683, "modeValue": 16832, "mode": "40700", "type": "directory", "nlink": 16, "uid": 501, "gid": 20, "rdev": 0, "size": 512, "blocks": 0, "blksize": 4096, "atimeValue": 1.774379e+09, "mtimeValue": 1774378980, "ctimeValue": 1.774379e+09, "flags": 0, "gen": 0, "atime": "24.03.2026 20:03:04", "ctime": "24.03.2026 20:03:01", "mtime": "24.03.2026 20:03" }

Read information on a symbolic link:

MBS( "Files.Stat"; "/Users/cs/testing"; 1 )

Example result:
{ "dev": 16777232, "ino": 261365169, "modeValue": 41453, "mode": "120755", "type": "symlink", "nlink": 1, "uid": 501, "gid": 20, "rdev": 0, "size": 4, "blocks": 0, "blksize": 4096, "atimeValue": 1.774383e+09, "mtimeValue": 1.774383e+09, "ctimeValue": 1.774383e+09, "flags": 0, "gen": 0, "atime": "24.03.2026 21:03:15", "ctime": "24.03.2026 21:03:15", "mtime": "24.03.2026 21:03:15" }

Check a regular file on macOS:

MBS( "Files.Stat"; "/Users/cs/test.mov" )

Example result:
{ "dev": 16777232, "ino": 261395714, "modeValue": 33188, "mode": "100644", "type": "file", "nlink": 1, "uid": 501, "gid": 20, "rdev": 0, "size": 11515035, "blocks": 22496, "blksize": 4096, "atimeValue": 1.705653e+09, "mtimeValue": 1.547127e+09, "ctimeValue": 1.774386e+09, "flags": 0, "gen": 0, "atime": "19.01.2024 09:35:48", "ctime": "24.03.2026 22:06:38", "mtime": "10.01.2019 14:35:52" }

Check a file on Windows:

MBS( "Files.Stat"; "C:\Users\cs\Desktop\Dialog.fmp12" )

Example result:
{ "dev": 2, "ino": 0, "modeValue": 33206, "mode": "100666", "type": "file", "nlink": 1, "uid": 0, "gid": 0, "rdev": 2, "size": 425984, "atimeValue": 1774386862, "mtimeValue": 1773253839, "ctimeValue": 1771420055, "atime": "24.03.2026 22:14:22", "ctime": "18.02.2026 14:07:35", "mtime": "11.03.2026 19:30:39" }

Check a folder on Linux:

MBS( "Files.Stat"; "/opt/FileMaker/FileMaker Server/Data" )

Example result:
{ "dev": 2050, "ino": 524321, "modeValue": 16877, "mode": "40755", "type": "directory", "nlink": 13, "uid": 996, "gid": 1001, "rdev": 0, "size": 4096, "blocks": 8, "blksize": 4096, "atimeValue": 1773768063, "mtimeValue": 1773767964, "ctimeValue": 1773767964, "atime": "03/17/2026 06:21:03 PM", "ctime": "03/17/2026 06:19:24 PM", "mtime": "03/17/2026 06:19:24 PM" }

See also

Blog Entries

Created 24th March 2026, last changed 25th March 2026


Files.StartDownloadingUbiquitousItem - Files.USBSerialNumber