Subject Re: [IBO] Read-Only Database with Firebird 2.1.1 and IBObjects 4.8.7
Author Thomas Steinmaurer
> --- In IBObjects@yahoogroups.com, Thomas Steinmaurer <ts@...> wrote:
>>> [snip]
>>>
>>>> SELECT RDB$RELATION_FIELDS.*
>>>> , RDB$RELATION_FIELDS.RDB$DB_KEY
>>>> from rdb$relation_fields
>>>> where rdb$default_source is not null
>>> The statement above fails and leads to the error message.
>>>
>>> I have no idea why, possibly it is related to using RDB$DB_KEY in
> the
>>> statement, although the above query works fine on the read-only
> database
>>> in isql.
>> Btw, it's the where clause. For example, changing the where clause
> to
>> WHERE RDB$DEFAULT_SOURCE IS NULL
>>
>> allows me to execute the query with IBO and FB 2.1. Both statements
> work
>> fine with Firebird 2.0 and IBO. Weird.
>>
>>
>> --
>> Best Regards,
>> Thomas Steinmaurer
>> LogManager Series - Logging/Auditing Suites supporting
>> InterBase, Firebird, Advantage Database, MS SQL Server and
>> NexusDB V2
>> Upscene Productions
>> http://www.upscene.com
>> My blog:
>> http://blog.upscene.com/thomas/
>>
>
> Yes I just tried it again: I created a complete new database file,
> just with one table
>
> create table test ( test integer default 0);
>
> after using gfix with parameter -mode read_only I can't execute the
> above statement.
>
> When I change the table and don't use the "default 0"-part in it,
> everything works fine.

Btw, do you have an database properties at connection level like
ForcedWrites, ReservePageSpace, ... set to non default values?

This will reproduce the error message, but already at connect time.



--
Best Regards,
Thomas Steinmaurer
LogManager Series - Logging/Auditing Suites supporting
InterBase, Firebird, Advantage Database, MS SQL Server and
NexusDB V2
Upscene Productions
http://www.upscene.com
My blog:
http://blog.upscene.com/thomas/