Subject | Re: [firebird-support] Getting database creation date programatically |
---|---|
Author | Josef Kokeš |
Post date | 2012-06-15T07:48:41Z |
>>>> I need to find the date of last database restore. GSTAT -h can printI am working in a very heterogenous environment. The worst components
>>>> this information as "Creation date". Does anyone know how can I get this
>>>> information programatically?
>>>
>>> If monitoring tables are available, it might be easier to query
>>> MON$DATABASE with e.g.:
>>>
>>> select mon$creation_date from mon$database
>>
>> Unfortunately, I need this information for Firebird 1.0, too :-(
>
> In general, you can use the Services API to fetch the header page and
> then parse the content to get the creation date.
>
> Depending on your used database access layer product/components,
> especially in the Delphi world, they usually offer components which wrap
> the Services API calls/layer into an ease to use object model.
>
> So, what database access layer do you use?
>
which I still need to support are a heavily modified ancient version of
ZeosLib for Delphi 5, and some unnamed C library used by a Linux
version. So I think using the API directly and not depending on
components is my best option.
Pepak