Re: Standard Database Interface?
- From: Sean Woods <yoda@xxxxxxxxxx>
- Date: Sat, 20 Oct 2007 14:47:07 -0700
On Oct 17, 2:34 am, tcltk...@xxxxxxx wrote:
Where can I find the examples on how to use taodbi? I need plenty of
examples because I'm not that smart. What databases are supported? Do
I need install packages for postgres, oracle and tclodbc?
Thanks.
You would need install packages for postgres, oracle, and tclodbc.
Taodbi
is a wrapper layer on top of the existing driver. Unfortunately, I
don't have
a wrapper at present for either postgres or Oracle. (Postgres is easy
enough to
come by, but a live Oracle system is a teensy bit more of a pain to
set up to
test.)
Once you have a wrapper though it would simply be
package require taodbi-connectors
tao::object_create myDbObject [list class theDriverClass ...
(connection info)...]
myDbObject query_flat "select field1,field2 from someTable where
field3='somevalue'"
(List returned)
myDbObject cmnd "update someTable set field1='newValue' where
primary_key='someKey'"
There are some more complicated examples for when you want the object
to generate
the query for you, but essentially the point of TaoDbi is to make it
damn simple
to string up a database.
.
- Follow-Ups:
- Re: Standard Database Interface?
- From: thelfter@xxxxxxxxx
- Re: Standard Database Interface?
- References:
- Standard Database Interface?
- From: tcltkdev
- Re: Standard Database Interface?
- From: Sean Woods
- Re: Standard Database Interface?
- From: tcltkdev
- Standard Database Interface?
- Prev by Date: Re: Standard Database Interface?
- Next by Date: Re: Call by Reference
- Previous by thread: Re: Standard Database Interface?
- Next by thread: Re: Standard Database Interface?
- Index(es):
Relevant Pages
|