Subject | Re: Problem with records disappear in dbgrid(detail db). |
---|---|
Author | speedyc65 |
Post date | 2003-11-10T22:04:57Z |
--- In IBObjects@yahoogroups.com, Helen Borrie <helebor@t...> wrote:
same dataset and pressing Insert(+) and then Post(v) after putting
some info on the row. When either pressing TDBNavigator Post button
or leaving the row in the TDBGrid makes the row disappears. When I
do a Next and Previous on the master table the grid then shows all
rows including the newly posted one.
BESKRIVNING.NR=BESKRIVNING_NR_GEN
KOMPETENS.NR=KOMPETENS_NR_GEN
LONEART.NR=LONEART_NR_GEN
MTRL.NR=MTRL_NR_GEN
RISKER.NR=RISKER_NR_GEN
They all work the same way and get the same behaviour in a Grid.
still be the current. Why are the key values not available ?
if the UPDATE command to the server didnt report an error why are
the buffer emptied ?
> At 01:18 PM 6/11/2003 +0000, you wrote:wrote:
> >--- In IBObjects@yahoogroups.com, Helen Borrie <helebor@t...>
> > > At 09:56 PM 5/11/2003 +0000, you wrote:lines
> > >
> > > >Sorry I wrote KeyFields but I meant KeyLinks. So what you are
> >saying
> > > >that I have done it right in KeyLinks then, but why does the
> > > >disappears after Post and then reappears when you do a Next /to give
> > > >Previous ?
> > >
> > > Some more questions --
> > > Are you calling Insert or Append?
> >I'm using a DBGrid so I don't know what it uses.
>
> I'll put the question another way. How are you causing the grid
> you an empty row so that you can insert a new row?I used the Insert key but I also tried to add a DBNavigator to the
>
same dataset and pressing Insert(+) and then Post(v) after putting
some info on the row. When either pressing TDBNavigator Post button
or leaving the row in the TDBGrid makes the row disappears. When I
do a Next and Previous on the master table the grid then shows all
rows including the newly posted one.
>user
> > > Where do the PK values for your new rows come from? Does the
> >enterGenatorLinks
> > > them, or are they generated/calculated on the server?
> > >
> >Two values come from OnNewRecord on the detail(TIBOTable) and the
> >last one is a generator. The generator is listed in the
> >in the TIBODatabase.AVVIKELSE.NR=AVVIKELSE_NR_GEN
>
> 1. What does the GeneratorLinks entry look like?
BESKRIVNING.NR=BESKRIVNING_NR_GEN
KOMPETENS.NR=KOMPETENS_NR_GEN
LONEART.NR=LONEART_NR_GEN
MTRL.NR=MTRL_NR_GEN
RISKER.NR=RISKER_NR_GEN
They all work the same way and get the same behaviour in a Grid.
> 2. Do you see the generator value in the grid when thenew "empty" row
> appears?Yes.
> 3. Do you see the other key values?Yes.
> Your new rows are going to get "lost" (from the point of view ofthe
> dataset) if those key values are not available to put into the Keybuffer.
>If followed you all the way to here. The row is posted and should
still be the current. Why are the key values not available ?
if the UPDATE command to the server didnt report an error why are
the buffer emptied ?
> Helen