Exist any Way to Determine the Version of Firebird SQL is running? using SQL or code (delphi, C++).
Bye
You can find your Firebird Server version by clicking the Check Firebird Version button in the Database Connection window using the menu option Tools --> Database Connection.
To check that the Firebird Server is running in Windows just go to Services applet and check for Firebird Server and Firebird Guardian services. Alternatively, if you used the installer Firebird will have installed a Server Control Applet in the Control Panel.
Firebird is an open-source SQL relational database management system that support Linux, Microsoft Windows, macOS and other Unix platforms. The database forked from Borland's open source edition of InterBase in 2000 but the code has been largely rewritten since Firebird 1.5.
SQL> SHOW DB; The show database (or show db) command displays details about the current database.
If you want to find it via SQL you can use get_context to find the engine version it with the following:
SELECT rdb$get_context('SYSTEM', 'ENGINE_VERSION')
as version from rdb$database;
you can read more about it here firebird faq, but it requires Firebird 2.1 I believe.
Two things you can do:
Use the Services API to query the server version, the call is isc_service_query()
with the isc_info_svc_server_version
parameter. Your preferred Delphi component set should surface a method to wrap this API.
For C++ there is for example IBPP which has IBPP::Service::GetVersion()
to return the version string.
What you get back with these is the same string that is shown in the control panel applet.
If you need to check whether certain features are available it may be enough (or even better) to execute statements against the system tables to check whether a given system relation or some field in that relation is available. If the ODS of the database is from an older version some features may not be supported, even though the server version is recent enough.
The ODS version can also be queried via the API, use the isc_database_info()
call.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With