Database Query Builder
janschenkel at yahoo.com
Fri Dec 5 09:03:52 CST 2003
--- "tkuypers at pandora.be" <tkuypers at pandora.be> wrote:
> When using the Database Query Builder, you have to
> enter the address of the
> database. But is there a way to create a
> preference-file which is loaded
> during startup, because I¹m creating a
> mySQL-front-end which uses different
> databases (development db on server 1 and live db on
> server 2).
> Now I created my SQL-statements myself, so I check a
> preference-file at
> startup, which I manually can edit, or edit in my
> preference-tab in the
> program, but I would like to use the Database Query
> Builder and still be
> able to change and save these settings.
> Anyone any advice, because I can¹t seem to find
> where the Database Query
> Builder gets and stores its data.
> Thanks in advance,
> Ton Kuypers
The revDatabase implementation is an interesting one,
in that each and every query is actually an unplaced,
The connection information for the query is stored in
its custom property set named "cREVDatabaseQuery" :
In order to get the actual group, you have to use the
undocumented function 'revQueryLongName' ; hand it a
query name and it gives you the long name of the
group, after which you can play around with its custom
properties from a script :
put revQueryLongName(tQueryName) into tQueryObject
set the cREVDatabaseQuery["dbhost"] of \
tQueryObject to "the.other.host"
Oh, a little note of warning : do not try to place the
database query groups onto a card, or the query will
stop working alltogether. Took me a while to figure
that one out...
Hope this helped,
"As we grow older, we grow both wiser and more foolish at the same time." (La Rochefoucauld)
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
More information about the use-livecode