VSqliteDatabase Class: Construction Methods
The VSqliteDatabase class constructor has two forms. The first one is for a LOCAL database and the second one is for a CLIENT database.
VSqliteDatabase( inLocation as String )
- inLocation - fully qualified name (path + name) for this database
You should use this form of VSqliteDatabase constructor, if you create a database object that will work with a local database.
db = new VSqliteDatabase( 'db1' ) db = new VSqliteDatabase( 'c:\db1' )
VSqliteDatabase( inConnection as VConnection, inLocation as String )
- inConnection - VConnection object
- inLocation - name for this database (the path will be ignored since db is under vServer and vServer knows path to its sqlite-database folder)
You should use this form of VSqliteDatabase constructor to create a VSqliteDatabase object to access a remote database. The connection should be opened before.
connection = new VConnection( "somecompany.com", "sa", "sa" ) connection.Open() remote_db = new VSqliteDatabase( connection, 'db1' ) remote_db.Open() .................. remote_db.Close() connection.Close()