Re[4]: [firebird-support] GBak Backup Restore Problem

2013-06-25 Thread Dmitry Kuzmenko
Hello, Tupy...!

Wednesday, June 26, 2013, 12:35:34 AM, you wrote:

Tn I will not repeat (ooops, I am already in the way !) that the
Tn source DB (for the backup) is ok.

currently no evidence that it is ok :-)

Tn GBak ! This mean = or the problem happens at the backup process, or during 
the restore
Tn process.

usually process is
- backup see data, store it
- restore creates metadata, restores data, data does not fit to
constraints - error.

Tn But as we have no tool to see the backup content, it´s
Tn not possible to know where

It's possible. Tool name is IBBackupSurgeon.
You can dig in that direction, too.

Tn We experimented to restore first only the DB structure and then
Tn restore the data, and then we got no error. Using the same backup file.

You can't do that. You can restore metadata+data or only metadata.
Gbak is unable to restore data into existing database.
So, please explain what you are doing.

Tn We have FB 2.1.

this is misty. I know 5 versions of 2.1. 2.1.0, 2.1.1, 2.1.2...
and all of them up to 2.1.4 have bugfixes.

-- 
Dmitry Kuzmenko, www.ib-aid.com



Re[4]: [firebird-support] GBak Backup Restore Problem

2013-06-25 Thread Helen Borrie
At 08:56 a.m. 26/06/2013, Dmitry Kuzmenko wrote:

Tn I will not repeat (ooops, I am already in the way !) that the
Tn source DB (for the backup) is ok.

currently no evidence that it is ok :-)

The gbak restore problem IS evidence that the source DB is not OK. This problem 
could have been lying unnoticed in that database for a long time, if you have 
never done a backup-and-restore on it until now.  

Applying a NOT NULL constraint with a DEFAULT to a  column does  not magically 
update nulls that already exist in that column.  A DEFAULT applies **only** 
to inserts and then **only** if the insert statement excludes that column from 
the input set.

Tn We have FB 2.1.

this is misty. I know 5 versions of 2.1. 2.1.0, 2.1.1, 2.1.2...
and all of them up to 2.1.4 have bugfixes.

Actually, 2.1.5 and 2.1.5 Update 1 after that. ;-) 

Firebird 3 will disallow changing a column from nullable to NOT NULL if you do 
not fix the data manually beforehand.


Helen Borrie, Support Consultant, IBPhoenix (Pacific)
Author of The Firebird Book and The Firebird Book Second Edition
http://www.firebird-books.net
__