Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 6 of 6 total
Thread Remote and Local Data Mix
Mon, Nov 26 2012 4:16 AMPermanent Link

Christian Ahlgrimm

For a evaluationlist in a multi-user environment I have to link local and remote data via sql.
I know, that I can't mix local and remote databases in one sql.

This problem comes up, because I had to store some data in user-dependent tables and these tables are physically on NAS-drives with logical-Drivenames mapped wih the the variable %username% in it.
(e.g. Drivename H: for the user1 is another directory as for user2 and so on)

Is there a possibility to link the tables in these user-dependent-directorys with those in the remote-databases  ?

sorry for my bad english..

christian.
Mon, Nov 26 2012 4:47 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Christian


The only way I can think of is to stream the remote data into a local table and then use that. I don't do that myself so can't help with the syntax. However, it has been answered several times so use "stream client server local" as the search terms for ElevatDBs on-line newsgroups and you should find an answer.

Roy Lambert [Team Elevate]
Mon, Nov 26 2012 5:42 AMPermanent Link

Christian Ahlgrimm

Hi
thanks for your fast response, I also thought of this variant,
my only problem is, the user-dependent datavolume is small, but the serverside-one is big.

may be, I have an error in my algorithm,

another idea: I used the username to build a new Tablename (by coding it), but I didn't find a way to use variables in pathnames in sql....
Mon, Nov 26 2012 6:31 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Christian

> thanks for your fast response, I also thought of this variant,
>my only problem is, the user-dependent datavolume is small, but the serverside-one is big.

All you need to pass back to the local machine is the result set that the SQL generates on the server, then you use that in conjunction with the local table to generate the final result set.

If the local result set from the query is small enough it could even be directly coded into the sql.

>may be, I have an error in my algorithm,
>
>another idea: I used the username to build a new Tablename (by coding it), but I didn't find a way to use variables in pathnames in sql....

It should be possible to do something along those lines possibly using a server side procedure. You are right about not being able to use parameters but there's nothing against directly altering the sql code in the program.

Roy Lambert [Team Elevate]
Tue, Nov 27 2012 9:10 AMPermanent Link

Christian Ahlgrimm

" but there's nothing against directly altering the sql code in the program."--->

thanks for showing the way to the solution..
I'm using the qrdesign report generator, which is using  a  .qr2-file with the sql in it.
This file I'm now altering by coding.  

sometimes I don't see the forest because of the many trees (german saying).

christian
Tue, Nov 27 2012 1:29 PMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Christian


>sometimes I don't see the forest because of the many trees (german saying).

The English version goes "you can't see the wood for the trees"

Roy
Image