🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.database.multi-tier
2 messages
2 total messages Started by Nick Rambarransingh Wed, 27 Dec 2000 23:18
Switching SQL on the server as needed ...
#897
Author: Nick Rambarransingh
Date: Wed, 27 Dec 2000 23:18
14 lines
1387 bytes
Good Day All,

  How would I do this?  Lets say I have a MIDAS client/server app.  I
want to prewrite my sql, and and keep them in ascii files on the
server.  This way, if there are mods to be done, I modify the SQL ascii
file, and not have to recompile.

  So, I am trying to figure out, if I had many different SQL files, and
I wanted to let the client press a button that would cause the TQuery on
the server to close, load the new sql commands, and then open, how would
I go about something like this ?

Thanks, Nick
Borland Forever ....
Re: Switching SQL on the server as needed ...
#903
Author: Patrick Martin
Date: Mon, 01 Jan 2001 23:48
68 lines
3096 bytes
This is a multi-part message in MIME format.
--------------7B3E655DDE2F7FDF8757477A
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

If your SQL does not need to be dynamically generated, then just use
TStrings::LoadsFromFile to reload the SQL text.

As long as you are careful to specify the type of parameters (if used) when
setting their values, you will be able to refresh the SQL whenever you want,
and carry straight on.

If the SQL needs to be built dynamically, you could use some way of
returning a generator call, like a dll. Just unload and reload a new dll
version with the updated code.

The next step would be to have a remote SQL provider interface, and an
application that supplies SQL over remote procedure calls (or is that too
much?).

HTH

Patrick

Nick Rambarransingh wrote:

> Good Day All,
>
>   How would I do this?  Lets say I have a MIDAS client/server app.  I
> want to prewrite my sql, and and keep them in ascii files on the
> server.  This way, if there are mods to be done, I modify the SQL ascii
> file, and not have to recompile.
>
>   So, I am trying to figure out, if I had many different SQL files, and
> I wanted to let the client press a button that would cause the TQuery on
> the server to close, load the new sql commands, and then open, how would
> I go about something like this ?
>
> Thanks, Nick
> Borland Forever ....

--------------7B3E655DDE2F7FDF8757477A
Content-Type: text/x-vcard; charset=us-ascii;
 name="patrickmmartin.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Patrick Martin
Content-Disposition: attachment;
 filename="patrickmmartin.vcf"

begin:vcard 
n:Martin;Patrick
tel;pager:na
tel;cell:07773013982
tel;fax:na
tel;home:01483 303496
tel;work:na
x-mozilla-html:TRUE
url:http://www.freenetpages.co.uk/hp/patrickmmartin/
adr:;;72 Stoke Fields;Guildord;Surrey;;UK
version:2.1
email;internet:patrickmmartin@freenet.co.uk
title:Dr.
note:This is Patrick's home vcard
x-mozilla-cpt:;20176
fn:Patrick Michael Martin
end:vcard

--------------7B3E655DDE2F7FDF8757477A--
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads