The "path" property is an optional string that identifies the path of the database folder. It defaults to "".
- Do not include the name of the database file in the path because the database filename and the extension
.dbsare automatically added to the path, see Create thetest_db_max.dbsdatabase in thec:\temp\folder. - Must be between 0 and 2,048 bytes.
- When
"path"is omitted or set tonull, the FairCom server creates the database in the<faircom>/datafolder. - When you include the
\character in the"path"property, you must include two backslashes in a row because in JSON the single backslash character is an escape character— for example,"c:\\temp"designates thec:\temppath. - You can use forward slashes in the path property (even on Microsoft Windows) because the FairCom server correctly interprets them as backslashes on Windows and as forward slashes on Linux, MacOS, and Unix.
Create the test_db_max.dbs database in the c:\temp\ folder
{
"action": "createDatabase",
"params": {
"databaseName": "test_db_max",
"path": "c:\\temp"
},
"authToken": "replaceWithAuthTokenFromCreateSession"
}
"path" omitted or set to null
If the FairCom server is installed in the C:\FairCom\FairCom-Edge.windows.64bit.v4.5.1.170\ folder, this code example creates the test3.dbs database in C:\FairCom\FairCom-Edge.windows.64bit.v4.5.1.170\data\.
{
"action": "createDatabase",
"params": {
"databaseName": "test3"
},
"authToken": "replaceWithAuthTokenFromCreateSession"
}
Forward slash
{
"action": "createDatabase",
"params": {
"databaseName": "test4",
"path": "c:/temp"
},
"authToken": "replaceWithAuthTokenFromCreateSession"
}