Subject RE: [ib-support] Database Backup
Author Nigel Weeks
What tool did you use for the backup? It's missing table declaration
meta-data...not good.

-----Original Message-----
From: John Bennett [mailto:JBennett@...]
Sent: Tuesday, 10 June 2003 14:28
To: 'ib-support@yahoogroups.com'
Subject: RE: [ib-support] Database Backup


I agree, doesn't sound possible. On further investigations, the stored procs
didn't come over either even though the output we took from the
backup/restore suggest that they were written.
I will look at doing a metadata only backup.
Johnb

-----Original Message-----
From: Alan McDonald [mailto:alan@...]
Sent: Tuesday, 10 June 2003 2:26 PM
To: ib-support@yahoogroups.com
Subject: RE: [ib-support] Database Backup


bizarre - doesn't sound possible...
can you do a metadata only backup of your old database and see default
values?
Alan

> -----Original Message-----
> From: John Bennett [mailto:JBennett@...]
> Sent: Tuesday, 10 June 2003 2:23 PM
> To: 'ib-support@yahoogroups.com'
> Subject: RE: [ib-support] Database Backup
>
>
> This is exactly what I am saying.
>
> -----Original Message-----
> From: Alan McDonald [mailto:alan@...]
> Sent: Tuesday, 10 June 2003 1:20 PM
> To: ib-support@yahoogroups.com
> Subject: RE: [ib-support] Database Backup
>
>
> OTOH John, you suerly do not mean that the previous database had table
> metadata containg default values, and the restore now has created
> the tables
> but columns are now defined without their default value metadata??
> Alan
>
> > -----Original Message-----
> > From: Helen Borrie [mailto:helebor@...]
> > Sent: Tuesday, 10 June 2003 1:07 PM
> > To: ib-support@yahoogroups.com
> > Subject: Re: [ib-support] Database Backup
> >
> >
> > John,
> >
> > At 12:33 PM 10/06/2003 +1000, you wrote:
> >
> > >Hi all,
> > >
> > >I have what is (hopefully) a simple question.
> > >
> > >We have an Interbase 5.6 database that we recently backed up
> using gbak.
> > >We then moved the database to another production machine and
> restored it.
> > >Upon further investigation we have noticed that tables with fields that
> > >contain default values have not been recreated with the default values.
> > >Is there any way to add the default value to the field without
> losing the
> > >data that is already in the table (500,000 records)?
> >
> > Sorry, but you are going to have to look for a more plausible reason why
> > your "default values are missing". If default values were
> written at the
> > time the rows were created, then they became physical data,
> just like any
> > value that was written there by any other means. Gbak has no way of
> > knowing that a particular value in a particular column in a
> > particular row
> > was put there by a default constraint.
> >
> > A more likely reason is that you *thought* default values should
> > have been
> > written, when in reality they were not. Defaults work only in a very
> > restricted set of circumstances, viz.
> > 1. on an insert. (They don't apply to updates at all.)
> > 2. only where the INSERT statement does not include the
> defaulted column
> > in its field list.
> >
> > If you want a default value to be written wherever the column would
> > otherwise receive NULL, then you have to write Before Insert and Before
> > Update triggers to make it happen.
> >
> > As to how to fix the situation one-off, for existing data:
> >
> > UPDATE atable
> > set defaulted_col = TheDefault
> > where defaulted_col is null ;
> >
> > heLen
> >
> >
> >
> >
> > >Thanks in advance
> > >Johnb
> > >
> > >
> > >To unsubscribe from this group, send an email to:
> > >ib-support-unsubscribe@egroups.com
> > >
> > >
> > >
> > >Your use of Yahoo! Groups is subject to
http://docs.yahoo.com/info/terms/
>
>
>
>
> To unsubscribe from this group, send an email to:
> ib-support-unsubscribe@egroups.com
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>




To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com



Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/



To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com



Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/





To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com



Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/



To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com



Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/