Re: [firebird-support] Re: 2.5.1 upgrade dilemma

2015-08-22 Thread tvd...@ymail.com [firebird-support]
Alright, so the remaining questions to someone with that knowledge are:

- Does the problem going from 2.5.1 to 2.5.4 still only concern compound 
indices containing at least one NULLable (VAR)CHAR and no other indices than 
that? 
If not, what else?

- Is the following code enough to rebuild a superset of those, i.e. at least 
all indices that would give trouble? 

 SET TERM !! ;

EXECUTE BLOCK AS
DECLARE VARIABLE stmt VARCHAR(1000);
BEGIN
for select 'ALTER INDEX '||rdb$index_name ||' ACTIVE;'
from rdb$indices
where (rdb$system_flag is null or rdb$system_flag = 0)
order by rdb$foreign_key nulls first
into :stmt
do EXECUTE STATEMENT :stmt;
END!!

SET TERM ; !!


If not, then what should it be?

Thanks a lot.

Re: [firebird-support] Re: 2.5.1 upgrade dilemma

2015-08-22 Thread 'Carlos H. Cantu' lis...@warmboot.com.br [firebird-support]













Re: [firebird-support] Re: 2.5.1 upgrade dilemma

2015-08-22 Thread tvd...@ymail.com [firebird-support]
That's very interesting! Does this behavior still exist? Is there any way to 
verify that?

So basically, if I execute the following after moving from 2.5.1 to 2.5.4 I 
should be fine?

 SET TERM !! ;

EXECUTE BLOCK AS
DECLARE VARIABLE stmt VARCHAR(1000);
BEGIN
for select 'ALTER INDEX '||rdb$index_name ||' ACTIVE;'
from rdb$indices
where (rdb$system_flag is null or rdb$system_flag = 0)
order by rdb$foreign_key nulls first
into :stmt
do EXECUTE STATEMENT :stmt;
END!!

SET TERM ; !!



Re: [firebird-support] Re: 2.5.1 upgrade dilemma

2015-08-22 Thread 'Carlos H. Cantu' lis...@warmboot.com.br [firebird-support]













Re: [firebird-support] Re: 2.5.1 upgrade dilemma

2015-08-22 Thread setysvar setys...@gmail.com [firebird-support]
Den 22.08.2015 15:26, skrev Dmitry Yemanov dim...@users.sourceforge.net 
[firebird-support]:
> 22.08.2015 16:06, tvd...@ymail.com wrote:
>
>> Rebuilding the indices is not the issue. It's just that the warning
>> implies that rebuilding the whole database is really better than just
>> rebuilding the indices. Am I still at any kind of risk if I just rebuild
>> the indices? What is the worst thing that could happen?
> Rebuilding indices is absolutely OK, no risk implied.
>
>
> Dmitry
I think what is required is to rebuild all compound indexes, that is all 
indexes (possibly including primary key, foreign key, unique key etc.) 
that consists of more than one field (hence indexes on single fields 
need not be rebuilt). I don't know whether this is related to 
http://tracker.firebirdsql.org/browse/CORE-3675 (and therefore, only 
applicable for indexes on fields having some form of text), or whether 
it is a different error (involving all compound indexes).

Set