Home > Archive > SQL Anywhere for Linux > April 2005 > Remote server on linux









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Remote server on linux
José Henrique

2005-04-07, 8:02 pm

Hi,

I have 2 ASA databases running on linux.
Database1 need access tables at database2, i'm trying to create remote
server (database2) in database1.

The only existing way is via odbc, and a have executed the folling
command to create a odbc

dbdsn -w database2 -c " uid=sql;pwd=sql;eng=
database2" -x
tcpip{host=127.0.0.1;serverport=5592}

And executed this sql command in isql to create a remote server

CREATE SERVER "database2" CLASS 'ASAODBC' USING 'database2';

and this to create a proxy table

CREATE EXISTING TABLE ptbCustomer
at 'adotesc2;;tbCustome
r';

But on second sql command i recive this error

Remote server '' could not be found; Add the server using CREATE SERVER
SQLCODE=-659, ODBC 3 State="HY000"
Line 1, column 1

What i'm doing wrong?

My ASA version is 9.0.2 (2452)

Sorry my BAD BAD BAD BAD english

José Henrique
Mark Culp

2005-04-07, 8:02 pm

First, make sure that your DSN is correct by using dbping
i.e.:
dbping -c "DSN=database2" -d

Then use

CREATE SERVER "database2" CLASS 'asaodbc'
USING 'DRIVER=< path_to_libdbodbc9_r
.so>;DSN=database2';

The check that the first server can find/connect to the second server
using
sp_remote_tables database2

Then create your proxy table
CREATE EXISTING TABLE ptbCustomer
AT 'database2;;tbCustom
er';
--
Mark Culp
SQLAnywhere Research and Development
-------------------------------------------------------------------------
** Whitepapers, TechDocs, bug fixes are all available through the **
** iAnywhere Developer Community at http://www.ianywhere.com/developer **
-------------------------------------------------------------------------

José Henrique wrote:
>
> Hi,
>
> I have 2 ASA databases running on linux.
> Database1 need access tables at database2, i'm trying to create remote
> server (database2) in database1.
>
> The only existing way is via odbc, and a have executed the folling
> command to create a odbc
>
> dbdsn -w database2 -c " uid=sql;pwd=sql;eng=
database2" -x
> tcpip{host=127.0.0.1;serverport=5592}
>
> And executed this sql command in isql to create a remote server
>
> CREATE SERVER "database2" CLASS 'ASAODBC' USING 'database2';
>
> and this to create a proxy table
>
> CREATE EXISTING TABLE ptbCustomer
> at 'adotesc2;;tbCustome
r';
>
> But on second sql command i recive this error
>
> Remote server '' could not be found; Add the server using CREATE SERVER
> SQLCODE=-659, ODBC 3 State="HY000"
> Line 1, column 1
>
> What i'm doing wrong?
>
> My ASA version is 9.0.2 (2452)
>
> Sorry my BAD BAD BAD BAD english
>
> José Henrique

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com