Recent

Author Topic: Anyone worked throug IBdemo-20050328?  (Read 3507 times)

HowardH

  • New Member
  • *
  • Posts: 16
    • http://www.celtic-fiddler.com
Anyone worked throug IBdemo-20050328?
« on: October 20, 2007, 11:57:59 pm »
I managed to get the IBdemo-20050328 project to compile and run, and it displays the customer table in the grid, but update and delete do not work in the demo. Apparently, I need to add something to the deletesql, insertsql, and updatesql properties of the SQLQuery1 component -- which is the sort of thing I was hoping to see illustrated in the example. Looks like whoever wrote up the example was following the bad example of Borland (the documentation for Delphi 1.0 was the worst I have ever seen in a commercial product) by not bothering to complete it, or even hint at what might be needed to complete it.

BTW, for anybody who hasn't gotten even that far, here is what I had to do to get it to run:

Quote
1) In IBConnection1, the database name is the complete pathname of the database file, and the hostname is 127.0.0.1
2) The UserName is SYSDBA, and the password is whatever you assigned (the default out of the box is "masterkey", and should be changed first thing after you install Firebird)
3) In SQLTransaction1, make sure the Database property is set to IBConnection1.
4) In SQLQuery1, make sure the Database property is set to IBConnection1.
5) In Datasource1, make sure the Dataset property is set to SQLQuery1
6) In Edit1, use the same string you used for the database name in the IBConnection1.

At that point, you can set everything to Connected or Active, and see the table in the grid at design time. You probably want to set Active to false in SQLQuery1 before you run the demo.


Is there anybody here who has successfully added insert, delete, and update functionality to the IBdemo-20050328? If so, would you mind showing me how it was done?

Specifically, is there some format for the sql that will allow me to use data-aware components with minimal coding, or do I have to dynamically update an sql statement and put it into the deletesql, insertsql, or updatesql property of the SQLQuery1 component (if the latter, I'm kinda wondering what advantage there is to using a data-aware component)?
Howard Lee Harkness
The Celtic Fiddler http://www.celtic-fiddler.com
Violins and Accessories

 

TinyPortal © 2005-2018