Name: revDatabaseConnectResult

Synonyms: revdb_connectionerr

Type: function

Syntax: revDatabaseConnectResult(<databaseID>)

Summary:
<return|Returns> the most recent error message for a <database>.

Associations: database library

Introduced: 1.1

OS: mac, windows, linux, ios, android

Platforms: desktop, server, mobile

Security: disk, network

Example:
revDatabaseConnectResult(line x of revOpenDatabases())

Example:
if revDatabaseConnectResult(myReservations) is empty then exit repeat

Parameters:
databaseID:
The number returned by the revOpenDatabase function when the database
was opened.

Returns:
The <revDatabaseConnectResult> <function> <return|returns> a <string>.

Description:
Use the <revDatabaseConnectResult> <function> to check for successful
completion of commands.

If there were no errors on the specified database connection, the
<revDatabaseConnectResult> <function> <return|returns> empty. Otherwise
the <revDatabaseConnectResult> function returns the database specific
error message for the most recent database operation that failed.

>*Important:*  The <revDatabaseConnectResult> <function> is part of the 
> <Database library>. To ensure that the <function> works in a 
> <standalone application>, you must include this 
> <LiveCode custom library|custom library> when you create your 
> <standalone application|standalone>. In the Inclusions pane of the 
> <Standalone Application Settings> window, make sure both the 
> "Database" library checkbox and those of the database drivers you are 
> using are checked.

Changes:
The revDatabaseConnectResult synonym was added in version 2.0.

References: revCloseDatabase (command), function (control structure),
revQueryResult (function), revOpenDatabase (function),
revOpenDatabases (function), Standalone Application Settings (glossary),
database (glossary), standalone application (glossary), return (glossary),
LiveCode custom library (glossary), string (keyword),
Database library (library)

Tags: database

