dbGetHostName#
Purpose#
Returns the database connection’s host name
Format#
- host_name = dbGetHostName(db_id)#
- Parameters:
db_id (scalar) – database connection index number.
- Returns:
host_name (string) – name of database connection.
Examples#
// Add MySQL to the list of database connections
db_id = dbAddDatabase("MYSQL");
// Set the host name
dbSetHostName(db_id, "db.example.com");
// Retrieve and print the host name
host_name = dbGetHostName(db_id);
print host_name;