Xojo Conferences
XDCMay2019MiamiUSA

Platforms to show: All Mac Windows Linux Cross-Platform

/SQL/SQLDatabaseMBS CubeSQL select version
Function:
You find this example project in your Plugins Download as a Xojo project file within the examples folder: /SQL/SQLDatabaseMBS CubeSQL select version
This example is the version from Tue, 28th May 2018.
Project "SQLDatabaseMBS CubeSQL select version.rbp"
Class App Inherits Application
Const kEditClear = "&Löschen"
Const kFileQuit = "Beenden"
Const kFileQuitShortcut = ""
EventHandler Sub Open() // use internal CubeSQL library call InternalCubeSQLLibraryMBS.Use dim db as new SQLDatabaseMBS db.Option("APPNAME") = "Xojo Test" db.Option("ConnectionTimeout") = "5" // 5 seconds timeout? 'db.Option("ConnectionEncryption") = "AES128" // or "AES192" or "AES256" // connect to database // in this example it is CubeSQL, // but can also be Sybase, Oracle, Informix, DB2, SQLServer, InterBase, MySQL, SQLBase and ODBC db.DatabaseName = "cubesql:localhost@mydatabase.sqlite" db.UserName = "admin" db.Password = "admin" if db.Connect then dim r as RecordSet = db.SQLSelect("select sqlite_version()") if r = nil or r.eof then MsgBox "Failed to query version." else MsgBox "Version: "+r.IdxField(1).StringValue end if end if End EventHandler
End Class
Class Window1 Inherits Window
End Class
MenuBar MenuBar1
MenuItem FileMenu = "&Ablage"
MenuItem FileQuit = "#App.kFileQuit"
MenuItem EditMenu = "&Bearbeiten"
MenuItem EditUndo = "&Rückgängig"
MenuItem UntitledMenu1 = "-"
MenuItem EditCut = "&Ausschneiden"
MenuItem EditCopy = "&Kopieren"
MenuItem EditPaste = "&Einfügen"
MenuItem EditClear = "#App.kEditClear"
MenuItem UntitledMenu0 = "-"
MenuItem EditSelectAll = "&Alles auswählen"
End MenuBar
End Project

See also:

Feedback, Comments & Corrections

The items on this page are in the following plugins: MBS SQL Plugin.




Links
MBS Xojo Plugins