On Thursday 16 March 2006 15:30, Joost van der Sluis wrote:
> > So to recap
> >  datasource1.dataset.UpdateRecord;
> >   datasource1.dataset.Post;
> >   datasource1.DataSet.close;
> >   sqlquery1.sql.Clear;
> >   sqlquery1.SQL.Text:='commit';
> >   sqlquery1.ExecSQL
> >
> >  sqlquery1.Close;
> >
> > does not work.
> >
> > BTW have no experience using any recent Delphi.  All that I'm learning is
> > through the school of hard knocks (reading articles from google).  But
> > when I get this working I will post to the wiki.
>
> The transaction is committed by the command transaction.commit
>
> For an example, see the fpc-code: fcl/db/sqldb/examples/fedittable.pp

Now I'm getting somewhere.  I getting an error about 'FWR' is not a column. 
The string is the primary key data (pkid = custno data in custno = 'FWR').  
So how do I set the primary key. Or rather where do I set it.  I think I read 
somewhere that I need to set a primary key. 

BTW the file was very helpful. 
to recap (for other newbie's):
use sqlquery to retreive the data
use dataset to post
use sqlquery to applyupdates
use SQLTranaction to commit the data.
 
John 

_________________________________________________________________
     To unsubscribe: mail [EMAIL PROTECTED] with
                "unsubscribe" as the Subject
   archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to