Subject | RE: [IBO] Re: How do I make ClientDatasets with master/detail relationships work right? |
---|---|
Author | IBO Support List |
Post date | 2012-11-05T19:06:13Z |
Jason Wharton in Malta Idaho.
-----Original Message-----
From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] On Behalf
Of masonwheeler
Sent: 05 November 2012 12:00 PM
To: IBObjects@yahoogroups.com
Subject: [IBO] Re: How do I make ClientDatasets with master/detail
relationships work right?
Sure, what's your Skype handle?
Mason
--- In IBObjects@yahoogroups.com, "IBO Support List" <supportlist@...>
wrote:
___________________________________________________________________________
IB Objects - direct, complete, custom connectivity to Firebird or InterBase
without the need for BDE, ODBC or any other layer.
___________________________________________________________________________
http://www.ibobjects.com - your IBO community resource for Tech Info papers,
keyword-searchable FAQ, community code contributions and more !
Yahoo! Groups Links
-----Original Message-----
From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] On Behalf
Of masonwheeler
Sent: 05 November 2012 12:00 PM
To: IBObjects@yahoogroups.com
Subject: [IBO] Re: How do I make ClientDatasets with master/detail
relationships work right?
Sure, what's your Skype handle?
Mason
--- In IBObjects@yahoogroups.com, "IBO Support List" <supportlist@...>
wrote:
>Behalf
> Mason,
>
> I'm going to need some extra help with your sample app.
> There are things there that appear quite non-standard to me.
> Perhaps you can contact me on Skype or some other instant messenger?
>
> Jason
>
> -----Original Message-----
> From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] On
> Of masonwheelerI
> Sent: 01 November 2012 04:47 PM
> To: IBObjects@yahoogroups.com
> Subject: [IBO] Re: How do I make ClientDatasets with master/detail
> relationships work right?
>
> All right. I just added ibo_cds.zip to the Files section on the Yahoo
> group. It's a fairly simple project that allows you to reproduce the
> problem. The database comes pre-populated with a master row that contains
> details referencing it. Try deleting the master row and then applying
> updates back to the data module and you'll see the problem.
>
> Mason
>
> --- In IBObjects@yahoogroups.com, "IBO Support List" <supportlist@>
> wrote:
> >
> > Mason,
> >
> > I don't use them extensively, but I do have some sample applications and
> > do intend them to work 100%. Will you please make a sample app of yourcall
> > problem so that I can see what is going on?
> >
> > Jason
> >
> > -----Original Message-----
> > From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] On
> Behalf
> > Of masonwheeler
> > Sent: 01 November 2012 11:16 AM
> > To: IBObjects@yahoogroups.com
> > Subject: [IBO] Re: How do I make ClientDatasets with master/detail
> > relationships work right?
> >
> >
> >
> > --- In IBObjects@yahoogroups.com, "masonwheeler" <masonwheeler@> wrote:
> > >
> > > I just ran into a bit of a problem. I've got two TIBOTables, let's
> > them M and D. The database table for D has a foreign key that points toand
> M's
> > table.
> > >
> > > I have two TClientDataset instances, one linked to M and one linked to
> D,
> > through providers. (Let's call them cdsM and cdsD.) The providers both
> > have ResolveToDataset set to true, which means that when I call
> > ApplyUpdates, the updates should only be sent to the TIBOTable dataset
> > not to the database.were
> > >
> > > Everything works fine until I try to delete a record in cdsM that has
> > records in cdsD pointing to it. I deleted those as well, but when I run
> the
> > following code:
> > >
> > > cdsM.ApplyUpdates(0);
> > > cdsD.ApplyUpdates(0);
> > >
> > > ...which should apply the updates back to the datasets and not to the
> > database, I get a foreign key violation from the database. (And if I
> > to apply the updates in the opposite order, it would error on inserts toM
> > instead. And this is a UI-driven operation, where it's quite possibleto
> > get both inserts and deletes in the same batch of updates.)------------------------------------
> > >
> > > How do I set this up so that I can apply both inserts and deletes from
> the
> > client datasets, and the TIBOTables will delay passing the SQL on to the
> > database until it has all the necessary information it needs to handle
> > things in the proper order? (Delete from D before M, insert to M before
> D.)
> >
> > ...anyone? I can't be the only one who's ever tried to use IBO with
> client
> > datasets.
>
___________________________________________________________________________
IB Objects - direct, complete, custom connectivity to Firebird or InterBase
without the need for BDE, ODBC or any other layer.
___________________________________________________________________________
http://www.ibobjects.com - your IBO community resource for Tech Info papers,
keyword-searchable FAQ, community code contributions and more !
Yahoo! Groups Links