Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 4 of 4 total
Thread Same SQL for remote and local?
Fri, Feb 10 2006 4:34 AMPermanent Link

Paul Harrison
Hi

I have an app that is used by many clients with and without the server dependant on the clients preference.

The application has multiple databases and I currently have to alter the syntax of the sql to accomodate the differences of the remote
and local restrictions.

Locally
select * from "c:\dbdir1\mytable1"
select * from "c:\dbdir2\mytable2"

Remote - obviously where DB1 and DB2 are TDBISAMDatabases
select * from "\DB1\mytable1"
select * from "\DB2\mytable2"


Am I missing a trick or am I stuck with two versions of the SQL

Thanks in advance

Paul

D7 & v4.21
Fri, Feb 10 2006 1:22 PMPermanent Link

"Donat Hebert \(WSI\)"
Hi Paul.  We manage our environments though a Function that dynamically
calculates the path based
on customers configuration and where they are.  You'll find that even
temporary workspace can be tricky especially
with citrix.  Our process uses an alias for databases and diskspace.  So
when the code fires, it will dynamically adjust
based on their own configuration.

ie CAlias('DB1','MyTable1',G_UserID) will return ansiquoted Path and
tablename glued together ...

More complex ones are a users own workspace which can resolve unique space
by person to ensure no file collisions. ie
G_UserID is current userid for example.  You can customize to your needs.
There are so many possible variations.

Donat.

"Paul Harrison" <paul.harrison@ba.com> wrote in message
news:216307D7-72CF-4058-B043-E81216BD3FE2@news.elevatesoft.com...
> Hi
>
> I have an app that is used by many clients with and without the server
> dependant on the clients preference.
>
> The application has multiple databases and I currently have to alter the
> syntax of the sql to accomodate the differences of the remote
> and local restrictions.
>
> Locally
> select * from "c:\dbdir1\mytable1"
> select * from "c:\dbdir2\mytable2"
>
> Remote - obviously where DB1 and DB2 are TDBISAMDatabases
> select * from "\DB1\mytable1"
> select * from "\DB2\mytable2"
>
>
> Am I missing a trick or am I stuck with two versions of the SQL
>
> Thanks in advance
>
> Paul
>
> D7 & v4.21
>

Fri, Feb 10 2006 2:42 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Paul,

<< Am I missing a trick or am I stuck with two versions of the SQL >>

For now, unfortunately yes.  However, the next version (ElevateDB) removes
this issue and local and C/S databases are referenced in an identical
fashion.

--
Tim Young
Elevate Software
www.elevatesoft.com

Tue, Feb 14 2006 5:35 AMPermanent Link

Paul Harrison
Thanks for the info.

Just as I suspected

Paul
Image