### Get List of Tables

An example of a Sub to get the list of database tables.
'Get the list of tables for a database
`Public Sub DBGetTables As List
Log("DBGetTables :: Start")
Dim Result As List
Result.Initialize
Dim cursor As ResultSet
Dim cmd As String = "SELECT * FROM sqlite_master WHERE TYPE=""table"" ORDER BY name;"
Try
cursor = gSQL.ExecQuery (cmd)
Do While cursor.NextRow
Result.Add(cursor.GetString("name"))
Loop
Catch
Log("Error", "Get list of tables " & DBFile & " = " & LastException)
End Try
Log("DBGetTables :: End = Tables:" & Result.size)
Return Result
End Sub`

Changed: , Category: SQLite, File: T6C254M1825.htm, ID: 1825