Lasso Soft Inc. > Home

[Database_RealName]

[Database_RealName] returns the real name of the database passed as a parameter. If the parameter names a Lasso database alias then the original name of the database on the database server will be returned.

This tag can be used so the true name of a database can be used in SQL statements.

If the database name is not found then the specified name will be returned unchanged.

  • Syntax
  • Parameters
[Database_RealName: 'Database Name']

[Database_RealName: 'Alias Name']
Required Parameters
Database Name The database name or alias for which the real name should be returned.
Examples

To return the real name of a database alias:

Use the [Database_RealName] tag. In the following example a database 'Contacts' has been set up in Lasso Administration with an alias 'MyContacts'. The alias name is used in the -Database tag, but the real database name must be used in the -SQL statement.

[Inline: -Database='MyContacts', -SQL='SELECT * FROM `' + (Database_RealName: 'MyContacts') + '`.`' + (Table_RealName: 'MyPeople') + '`;']
  [Found_Count]
[/Inline]
Result:
8
Tag Link [Database_RealName] Category Database
Type Substitution Data Source Any
Support Preferred Version 6.0
Output Type String Security Tag
Implementation LCAPI Sets Lasso 8.5, Lasso 8.0, Lasso 7.0, Lasso 6.0

Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.

LassoSoft Inc. > Home

 

 

©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft