Re: Where with local table
Posted in 1997
Topics: SQL Development & Query Writing
This is a multi-part message in MIME format.
--------------67715D65ED9
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Gary Bechthold wrote:
>
> Can an SQL statement be written in such a fashion that a table(.mdb)
> on a local machine can be used as one side of the conditional in a
> where statement when connected to a remote machine? If so a short
> code fragment illustrating this would be appreciated.
Is this OnLine? What Version?
Version 6.x onwards will allow this. Older versions will require IStar.
Then try something like:
SELECT *
FROM local_table a, remote_db@server:remote_table b
WHERE a.join_col = b.join_col
AND a.cond_col ..........
Or you can define a synonym in the local database which points to the
remote_table. Then your SQL will look like any local SQL.
Hope that helps,
--
--------------67715D65ED9
Content-Type: text/plain; charset=us-ascii; name="ATT_SIG.TXT"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="ATT_SIG.TXT"
Mark.
+------------------------------------------------------------------+
|Mark D. Stock - The West Solutions Group http://www.west.co.za |
| The Informix FAQ is at http://www.iiug.org |
|mailto:marks@west.co.za +-----------------------------------------+
|Tel: +27 11 803 2151 |If it doesn't work, force it! |
|Fax: +27 11 803 2189 |If it breaks, it needed replacing anyway!|
|Cell: +27 83 250 2325 |Well, that's how I code anyway! |
+------------------------+-----------------------------------------+
--------------67715D65ED9--