Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Remote Server Problem

11 posts in General Discussion Last posting was on 2003-10-27 09:57:44.0Z
MickeyBob Posted on 2003-10-26 01:43:05.0Z
Sender: 2054.3f9acf66.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Remote Server Problem
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <3f9b26a9.2129.846930886@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 25 Oct 2003 18:43:05 -0700
X-Trace: forums-1-dub 1067132585 10.22.241.41 (25 Oct 2003 18:43:05 -0700)
X-Original-Trace: 25 Oct 2003 18:43:05 -0700, 10.22.241.41
Lines: 42
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1908
Article PK: 4154

I'm experiencing a problem setting up a remote server to
text files.

My ultimate goal is to import and export data from text
files which are downloaded and uploaded on a daily basis
to/from a PC running Windows XP Embedded OS and ASA 9.0. One
approach I'm trying is to set up a remote server that uses
Microsoft's ODBC text driver, then setup a stored procedure
that purges a native table and then populates it with the
data from the remote server and vice-versa.

I can add the remote server specifying the DSN I've set up
(i.e., 'OnDisk') with the ODBC administrator utility. I can
also add a proxy table specifying the name of my text file
(i.e., 'Table1.txt'). While creating the new proxy table,
the wizard recognizes the column names successfully and the
proxy table seems to be created without a problem. (I have
tried this with and without an explicit table schema but
with identical results.) However, when I try to view the
data from Sybase Central, nothing shows up. I try to view
the proxy table in Interactive SQL but get the following
error:

[Sybase][ODBC Driver][Adaptive Server Anywhere]General
error: Server 'OnDisk': [Microsoft][ODBC Text Driver] The
Microsoft Jet database engine could not find the object
'C:\DATA\Table1.csv'. Make sure the object exists and that
you spell its name and the path name correctly.

(FYI, I think I'm using version 2.7 of the MDAC.)

I've searched on the web for anything related to this error
and can't seem to find anything relevent and helpful. I've
seen some forum posts regarding 8.3 naming schemes but my
names all jive with that. I've also tried doing something
similar with Excel files and everything works fine.

Any help in resolving this problem will be greatly
appreciated. Secondly, any alternatives you could propose
are of interest.

Thanks


Breck Carter [TeamSybase] Posted on 2003-10-26 12:01:15.0Z
From: "Breck Carter [TeamSybase]" <NOSPAM__bcarter@risingroad.com>
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
Organization: RisingRoad Professional Services
Reply-To: NOSPAM__bcarter@risingroad.com
Message-ID: <3ugnpv8mdrr1pstulep0k5n9vo2rsmh7i1@4ax.com>
References: <3f9b26a9.2129.846930886@sybase.com>
X-Newsreader: Forte Agent 1.8/32.548
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: bcarter.sentex.ca
X-Original-NNTP-Posting-Host: bcarter.sentex.ca
Date: 26 Oct 2003 05:01:15 -0700
X-Trace: forums-1-dub 1067173275 64.7.134.118 (26 Oct 2003 05:01:15 -0700)
X-Original-Trace: 26 Oct 2003 05:01:15 -0700, bcarter.sentex.ca
Lines: 53
X-Authenticated-User: TeamPS
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1912
Article PK: 4155

Another alternative: LOAD TABLE.

Breck

On 25 Oct 2003 18:43:05 -0700, MickeyBob wrote:

>I'm experiencing a problem setting up a remote server to
>text files.
>
>My ultimate goal is to import and export data from text
>files which are downloaded and uploaded on a daily basis
>to/from a PC running Windows XP Embedded OS and ASA 9.0. One
>approach I'm trying is to set up a remote server that uses
>Microsoft's ODBC text driver, then setup a stored procedure
>that purges a native table and then populates it with the
>data from the remote server and vice-versa.
>
>I can add the remote server specifying the DSN I've set up
>(i.e., 'OnDisk') with the ODBC administrator utility. I can
>also add a proxy table specifying the name of my text file
>(i.e., 'Table1.txt'). While creating the new proxy table,
>the wizard recognizes the column names successfully and the
>proxy table seems to be created without a problem. (I have
>tried this with and without an explicit table schema but
>with identical results.) However, when I try to view the
>data from Sybase Central, nothing shows up. I try to view
>the proxy table in Interactive SQL but get the following
>error:
>
>[Sybase][ODBC Driver][Adaptive Server Anywhere]General
>error: Server 'OnDisk': [Microsoft][ODBC Text Driver] The
>Microsoft Jet database engine could not find the object
>'C:\DATA\Table1.csv'. Make sure the object exists and that
>you spell its name and the path name correctly.
>
>(FYI, I think I'm using version 2.7 of the MDAC.)
>
>I've searched on the web for anything related to this error
>and can't seem to find anything relevent and helpful. I've
>seen some forum posts regarding 8.3 naming schemes but my
>names all jive with that. I've also tried doing something
>similar with Excel files and everything works fine.
>
>Any help in resolving this problem will be greatly
>appreciated. Secondly, any alternatives you could propose
>are of interest.
>
>Thanks

--
bcarter@risingroad.com
Mobile and Distributed Enterprise Database Applications
www.risingroad.com


MickeyBob Posted on 2003-10-26 12:27:11.0Z
Sender: 48e9.3f9bc90f.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <3f9bcbaf.48f1.846930886@sybase.com>
References: <3f9b26a9.2129.846930886@sybase.com><3ugnpv8mdrr1pstulep0k5n9vo2rsmh7i1@4ax.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 26 Oct 2003 05:27:11 -0700
X-Trace: forums-1-dub 1067174831 10.22.241.41 (26 Oct 2003 05:27:11 -0700)
X-Original-Trace: 26 Oct 2003 05:27:11 -0700, 10.22.241.41
Lines: 25
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1915
Article PK: 4156

I've thought about using LOAD TABLE or some other sequence
of SQL commands and executing them from Interactive SQL.
I've shied away from that approach because of memory
considerations. The PC this is running on only has 128Mb
total, 112Mb available, and with the DB engine and my
application I'm approaching that limit. Therefore I don't
won't to run and load another application. In fact, to get
my application to run at this point, I have to manually kill
the dbisql.exe process from the task manager - which brings
up other questions: Why is this service/application running
automatically? If this is the same executable for
Interactive SQL, where is the user interface? etc.

The big advantages I see in using the remote server approach
is no additional applications have to be loaded and run and
I can execute the stored procedure to import and export the
data from within my application with little and no custom
programming which saves me time and minimizes my application
size.

Any thoughts?

> Another alternative: LOAD TABLE.
>
> Breck


Breck Carter [TeamSybase] Posted on 2003-10-26 13:55:59.0Z
From: "Breck Carter [TeamSybase]" <NOSPAM__bcarter@risingroad.com>
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
Organization: RisingRoad Professional Services
Reply-To: NOSPAM__bcarter@risingroad.com
Message-ID: <scmnpv48qdm1j6704jf700e8kj9v7j68cm@4ax.com>
References: <3f9b26a9.2129.846930886@sybase.com><3ugnpv8mdrr1pstulep0k5n9vo2rsmh7i1@4ax.com> <3f9bcbaf.48f1.846930886@sybase.com>
X-Newsreader: Forte Agent 1.8/32.548
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: bcarter.sentex.ca
X-Original-NNTP-Posting-Host: bcarter.sentex.ca
Date: 26 Oct 2003 06:55:59 -0700
X-Trace: forums-1-dub 1067180159 64.7.134.118 (26 Oct 2003 06:55:59 -0700)
X-Original-Trace: 26 Oct 2003 06:55:59 -0700, bcarter.sentex.ca
Lines: 66
X-Authenticated-User: TeamPS
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1916
Article PK: 4159

LOAD TABLE can be run from a stored procedure. It is a real SQL
command, not a ISQL command like INPUT. LOAD TABLE also has the
advantage of being about a zillion times faster than INPUT, since
INPUT does transactional INSERT statements (and, FWIW, so does INSERT
SELECT from proxy table) whereas LOAD TABLE is effectively
non-transactional... no steenking .LOG file I/O. LOAD TABLE also works
with local temporary tables (new in V9). Because it is a SQL command
you can also run LOAD TABLE via EXECUTE IMMEDIATE... although that may
introduce you to a whole world of \\escape character pain, it does let
you specify file and table names dynamically.

One potential drawback is that the file specifications in LOAD TABLE
are relative to the server whereas with INPUT they are relative to the
client. That makes no difference to you if the database engine is
running on the client machine. If the file is on a different box from
the engine then that may introduce you to Universal Naming Convention
(UNC) pain, combined with \\\\ or \\\\\\\\escape character pain (I'm
not kidding, 8 backslashes is not unheard of if you use a string
literal separately from EXECUTE IMMEDIATE :)

Another potential drawback (let me say it before someone else does) is
the non-transactional nature... the .LOG file doesn't have a record of
individual rows, just the LOAD TABLE and file spec, so govern yourself
accordingly when it comes to recovery... if the file ain't there
anymore log-based roll forward ain't gonna re-LOAD (yawn... Winston
Cup cars don't have anti-lock brakes, they go for the *speed* :)

IMO proxy tables are wonderful things but they are overkill for
reading text files... plus all that schema.ini and ODBC.INI stuff.

LOAD TABLE rocks!

Breck The Ken Schrader Of SQL

On 26 Oct 2003 05:27:11 -0700, MickeyBob wrote:

>I've thought about using LOAD TABLE or some other sequence
>of SQL commands and executing them from Interactive SQL.
>I've shied away from that approach because of memory
>considerations. The PC this is running on only has 128Mb
>total, 112Mb available, and with the DB engine and my
>application I'm approaching that limit. Therefore I don't
>won't to run and load another application. In fact, to get
>my application to run at this point, I have to manually kill
>the dbisql.exe process from the task manager - which brings
>up other questions: Why is this service/application running
>automatically? If this is the same executable for
>Interactive SQL, where is the user interface? etc.
>
>The big advantages I see in using the remote server approach
>is no additional applications have to be loaded and run and
>I can execute the stored procedure to import and export the
>data from within my application with little and no custom
>programming which saves me time and minimizes my application
>size.
>
>Any thoughts?
>
>> Another alternative: LOAD TABLE.
>>
>> Breck

--
bcarter@risingroad.com
Mobile and Distributed Enterprise Database Applications
www.risingroad.com


MickeyBob Posted on 2003-10-26 22:43:42.0Z
Sender: 4a41.3f9c5c1a.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <3f9c5c2e.4a43.846930886@sybase.com>
References: <3f9b26a9.2129.846930886@sybase.com><3ugnpv8mdrr1pstulep0k5n9vo2rsmh7i1@4ax.com> <3f9bcbaf.48f1.846930886@sybase.com><scmnpv48qdm1j6704jf700e8kj9v7j68cm@4ax.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 26 Oct 2003 15:43:42 -0700
X-Trace: forums-1-dub 1067211822 10.22.241.41 (26 Oct 2003 15:43:42 -0700)
X-Original-Trace: 26 Oct 2003 15:43:42 -0700, 10.22.241.41
Lines: 12
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1917
Article PK: 17388

That sounds like a good option, I'll give it a try. But how
about "exporting" data. Is there an "UNLOAD TABLE"? (I'll be
investigating this on my own too.)

I don't think the lack of a transaction log is a big deal in
my situation because the imported text files essentially
contain all the data anyway. However, the same can't be said
for the export files. There I need to be assured that all
rows are written out to the text files before I purge the
table.

Thanks for the insights!


MickeyBob Posted on 2003-10-27 00:39:31.0Z
Sender: 4a99.3f9c76fd.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <3f9c7753.4a9b.846930886@sybase.com>
References: <3f9b26a9.2129.846930886@sybase.com><3ugnpv8mdrr1pstulep0k5n9vo2rsmh7i1@4ax.com> <3f9bcbaf.48f1.846930886@sybase.com><scmnpv48qdm1j6704jf700e8kj9v7j68cm@4ax.com><3f9c5c2e.4a43.846930886@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 26 Oct 2003 17:39:31 -0700
X-Trace: forums-1-dub 1067218771 10.22.241.41 (26 Oct 2003 17:39:31 -0700)
X-Original-Trace: 26 Oct 2003 17:39:31 -0700, 10.22.241.41
Lines: 5
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1918
Article PK: 4158

The LOAD TABLE and UNLOAD TABLE commands work great. I've
implemented several stored procedures using these commands
and they seem to fit the bill perfectly.

Thanks for the tremendous help!


Breck Carter [TeamSybase] Posted on 2003-10-27 09:57:44.0Z
From: "Breck Carter [TeamSybase]" <NOSPAM__bcarter@risingroad.com>
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
Organization: RisingRoad Professional Services
Reply-To: NOSPAM__bcarter@risingroad.com
Message-ID: <iutppv4smjs098bq5khrnm0lv4nqcvqp91@4ax.com>
References: <3f9b26a9.2129.846930886@sybase.com><3ugnpv8mdrr1pstulep0k5n9vo2rsmh7i1@4ax.com> <3f9bcbaf.48f1.846930886@sybase.com><scmnpv48qdm1j6704jf700e8kj9v7j68cm@4ax.com><3f9c5c2e.4a43.846930886@sybase.com> <3f9c7753.4a9b.846930886@sybase.com>
X-Newsreader: Forte Agent 1.8/32.548
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: bcarter.sentex.ca
X-Original-NNTP-Posting-Host: bcarter.sentex.ca
Date: 27 Oct 2003 02:57:44 -0700
X-Trace: forums-1-dub 1067252264 64.7.134.118 (27 Oct 2003 02:57:44 -0700)
X-Original-Trace: 27 Oct 2003 02:57:44 -0700, bcarter.sentex.ca
Lines: 20
X-Authenticated-User: TeamPS
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1919
Article PK: 17366

That's great!

FWIW there is also an UNLOAD SELECT that lets you create a file from
an arbitrary query, which gives you more freedom. "UNLOAD TABLE t" can
then be thought of as "UNLOAD SELECT * FROM t".

Breck

On 26 Oct 2003 17:39:31 -0700, MickeyBob wrote:

>The LOAD TABLE and UNLOAD TABLE commands work great. I've
>implemented several stored procedures using these commands
>and they seem to fit the bill perfectly.
>
>Thanks for the tremendous help!

--
bcarter@risingroad.com
Mobile and Distributed Enterprise Database Applications
www.risingroad.com


Greg Fenton Posted on 2003-10-26 06:25:41.0Z
From: Greg Fenton <greg.fenton_NOSPAM_@ianywhere.com>
Organization: iAnywhere Solutions Inc.
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4) Gecko/20030624
X-Accept-Language: en-us, en
MIME-Version: 1.0
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
References: <3f9b26a9.2129.846930886@sybase.com>
In-Reply-To: <3f9b26a9.2129.846930886@sybase.com>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
X-Original-NNTP-Posting-Host: cpe000625d8278c-cm.cpe.net.cable.rogers.com
Message-ID: <3f9b69ee@forums-2-dub>
X-Original-Trace: 25 Oct 2003 23:30:06 -0700, cpe000625d8278c-cm.cpe.net.cable.rogers.com
Lines: 50
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 25 Oct 2003 23:18:23 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 25 Oct 2003 23:25:41 -0700
X-Trace: forums-1-dub 1067149541 10.22.108.75 (25 Oct 2003 23:25:41 -0700)
X-Original-Trace: 25 Oct 2003 23:25:41 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1909
Article PK: 17357


MickeyBob wrote:

> specifying the name of my text file
> (i.e., 'Table1.txt').

[...]

> [Sybase][ODBC Driver][Adaptive Server Anywhere]General
> error: Server 'OnDisk': [Microsoft][ODBC Text Driver] The
> Microsoft Jet database engine could not find the object
> 'C:\DATA\Table1.csv'. Make sure the object exists and that
> you spell its name and the path name correctly.
>

I'm very unfamiliar with the ODBC Text Driver, so I cannot offer much
insight, but I see from your post that you have ".txt" in your
configuration, but ".csv" in the error message.

Is this simply a typo, or might it another symptom of the problem?

If the files are CSV, have you considered importing the data directly?
The INPUT statement is ISQL only, but you could call dbisql from a .BAT
file or similar and set up a batch job in the scheduler.

For more info, see the ASA 9.0 online docs:

ASA SQL Reference
SQL Statements
- INPUT statement [Interactive SQL]

Other alternatives:

- use xp_read_file in a stored procedure to load the file and then
process it using SQL statements
- have the uploaded file converted into another format (XML?) which
can be loaded by a stored procedure
- create a DLL to parse the file and call it as an external stored
procedure


Hope this helps,
greg.fenton
--
Greg Fenton
Consultant, Solution Services, iAnywhere Solutions
--------
Visit the iAnywhere Solutions Developer Community
Whitepapers, TechDocs, Downloads
http://www.ianywhere.com/developer/


MickeyBob Posted on 2003-10-26 12:13:36.0Z
Sender: 48e3.3f9bc7bc.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <3f9bc87f.48e6.846930886@sybase.com>
References: <3f9b26a9.2129.846930886@sybase.com><3f9b69ee@forums-2-dub>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 26 Oct 2003 05:13:36 -0700
X-Trace: forums-1-dub 1067174016 10.22.241.41 (26 Oct 2003 05:13:36 -0700)
X-Original-Trace: 26 Oct 2003 05:13:36 -0700, 10.22.241.41
Lines: 10
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1913
Article PK: 4161

Yes, it's a typo of sorts. I tried using a file with the
'.txt' and '.csv' extensions and with no extension. I
experienced the same symptom with both extensions. When I
used no extension, the wizard didn't recognize the column
names and I couldn't add the proxy table.

You have some good suggestions that I'm going to pursue a
little further.

Thanks,


Breck Carter [TeamSybase] Posted on 2003-10-26 12:00:44.0Z
From: "Breck Carter [TeamSybase]" <NOSPAM__bcarter@risingroad.com>
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
Organization: RisingRoad Professional Services
Reply-To: NOSPAM__bcarter@risingroad.com
Message-ID: <p5enpvs65dmjl7e4b32mlm5ardn0o9c2q1@4ax.com>
References: <3f9b26a9.2129.846930886@sybase.com>
X-Newsreader: Forte Agent 1.8/32.548
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: bcarter.sentex.ca
X-Original-NNTP-Posting-Host: bcarter.sentex.ca
Date: 26 Oct 2003 05:00:44 -0700
X-Trace: forums-1-dub 1067173244 64.7.134.118 (26 Oct 2003 05:00:44 -0700)
X-Original-Trace: 26 Oct 2003 05:00:44 -0700, bcarter.sentex.ca
Lines: 132
X-Authenticated-User: TeamPS
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1911
Article PK: 17362

It is very difficult to remotely debug (pun intended :) problems that
arise with Sybase Central wizards, simply because it's difficult for
*you* to tell *us* exactly what operations you performed without
posting 10M worth of screen shots (and please don't do that :)

I've managed to repeat your symptom with ISQL commands using
9.0.0.1216, and I have not been able to discover a workaround...
perhaps someone else can see the flaw...

-- Input file c:\temp\textfile.txt

/*
1,'123, Lombard Street'
2,'123, Lombards Street'
4,'Test One'
*/

-- Schema file c:\temp\schema.ini

/*
[textfile.txt]
ColNameHeader=True
Format=CSVDelimited
MaxScanRows=0
CharacterSet=OEM
Col1=KEY_1 Char Width 255
Col2=NON_KEY_1 Char Width 255
*/

-- "ODBC.INI" registry entry for DSN textfile

/*
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\textfile]
"Driver"="C:\\WINNT\\System32\\odbcjt32.dll"
"DefaultDir"="C:\\TEMP"
"DriverId"=dword:0000001b
"FIL"="text;"
"SafeTransactions"=dword:00000000
"UID"=""

[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\textfile\Engines]

[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\textfile\Engines\Text]
"ImplicitCommitSync"=""
"Threads"=dword:00000003
"UserCommitSync"="Yes"
*/

-- "ODBC Data Sources" list entry for DSN textfile

/*
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\ODBC Data Sources]
"textfile"="Microsoft Text Driver (*.txt; *.csv)"
*/

CREATE SERVER textfile_server CLASS 'ODBC' USING 'textfile';
CREATE EXISTING TABLE textfile_table
AT 'textfile_server;c:\\temp;;textfile.txt';
SELECT * FROM textfile_table;

-- Resulting error:

[Sybase][ODBC Driver][Adaptive Server Anywhere]Server
'textfile_server': [Microsoft][ODBC Text Driver] The Microsoft Jet
database engine could not find the object 'c:\temp\textfile.txt'.
Make sure the object exists and that you spell its name and the path
name correctly.

-- Tried again with AT 'textfile_server;c:\temp;;textfile.txt' and get
*exactly* the same error message.

-- Tried again with AT 'textfile_server;c:\\\\temp;;textfile.txt' and
get *exactly* the same error message (only one \ survives).

-- Tried again with c:\atemp and afile.txt as the folder and file
names, same result.

Breck Failed

On 25 Oct 2003 18:43:05 -0700, MickeyBob wrote:

>I'm experiencing a problem setting up a remote server to
>text files.
>
>My ultimate goal is to import and export data from text
>files which are downloaded and uploaded on a daily basis
>to/from a PC running Windows XP Embedded OS and ASA 9.0. One
>approach I'm trying is to set up a remote server that uses
>Microsoft's ODBC text driver, then setup a stored procedure
>that purges a native table and then populates it with the
>data from the remote server and vice-versa.
>
>I can add the remote server specifying the DSN I've set up
>(i.e., 'OnDisk') with the ODBC administrator utility. I can
>also add a proxy table specifying the name of my text file
>(i.e., 'Table1.txt'). While creating the new proxy table,
>the wizard recognizes the column names successfully and the
>proxy table seems to be created without a problem. (I have
>tried this with and without an explicit table schema but
>with identical results.) However, when I try to view the
>data from Sybase Central, nothing shows up. I try to view
>the proxy table in Interactive SQL but get the following
>error:
>
>[Sybase][ODBC Driver][Adaptive Server Anywhere]General
>error: Server 'OnDisk': [Microsoft][ODBC Text Driver] The
>Microsoft Jet database engine could not find the object
>'C:\DATA\Table1.csv'. Make sure the object exists and that
>you spell its name and the path name correctly.
>
>(FYI, I think I'm using version 2.7 of the MDAC.)
>
>I've searched on the web for anything related to this error
>and can't seem to find anything relevent and helpful. I've
>seen some forum posts regarding 8.3 naming schemes but my
>names all jive with that. I've also tried doing something
>similar with Excel files and everything works fine.
>
>Any help in resolving this problem will be greatly
>appreciated. Secondly, any alternatives you could propose
>are of interest.
>
>Thanks

--
bcarter@risingroad.com
Mobile and Distributed Enterprise Database Applications
www.risingroad.com


Breck Carter [TeamSybase] Posted on 2003-10-26 12:22:34.0Z
From: "Breck Carter [TeamSybase]" <NOSPAM__bcarter@risingroad.com>
Newsgroups: ianywhere.public.general
Subject: Re: Remote Server Problem
Organization: RisingRoad Professional Services
Reply-To: NOSPAM__bcarter@risingroad.com
Message-ID: <03inpvonpmtah2uuocqpnl3plvsnkm24rc@4ax.com>
References: <3f9b26a9.2129.846930886@sybase.com> <p5enpvs65dmjl7e4b32mlm5ardn0o9c2q1@4ax.com>
X-Newsreader: Forte Agent 1.8/32.548
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: bcarter.sentex.ca
X-Original-NNTP-Posting-Host: bcarter.sentex.ca
Date: 26 Oct 2003 05:22:34 -0700
X-Trace: forums-1-dub 1067174554 64.7.134.118 (26 Oct 2003 05:22:34 -0700)
X-Original-Trace: 26 Oct 2003 05:22:34 -0700, bcarter.sentex.ca
Lines: 141
X-Authenticated-User: TeamPS
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:1914
Article PK: 4160

I tried it with ASA 8 and got the same thing (albeit with a
less-informative error message). I am suspecting the MS text driver
but I don't have a licensed Merant driver handy to test the theory.

Breck

On 26 Oct 2003 05:00:44 -0700, "Breck Carter [TeamSybase]"

<NOSPAM__bcarter@risingroad.com> wrote:

>It is very difficult to remotely debug (pun intended :) problems that
>arise with Sybase Central wizards, simply because it's difficult for
>*you* to tell *us* exactly what operations you performed without
>posting 10M worth of screen shots (and please don't do that :)
>
>I've managed to repeat your symptom with ISQL commands using
>9.0.0.1216, and I have not been able to discover a workaround...
>perhaps someone else can see the flaw...
>
>-- Input file c:\temp\textfile.txt
>
>/*
>1,'123, Lombard Street'
>2,'123, Lombards Street'
>4,'Test One'
>*/
>
>-- Schema file c:\temp\schema.ini
>
>/*
>[textfile.txt]
>ColNameHeader=True
>Format=CSVDelimited
>MaxScanRows=0
>CharacterSet=OEM
>Col1=KEY_1 Char Width 255
>Col2=NON_KEY_1 Char Width 255
>*/
>
>-- "ODBC.INI" registry entry for DSN textfile
>
>/*
>Windows Registry Editor Version 5.00
>
>[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\textfile]
>"Driver"="C:\\WINNT\\System32\\odbcjt32.dll"
>"DefaultDir"="C:\\TEMP"
>"DriverId"=dword:0000001b
>"FIL"="text;"
>"SafeTransactions"=dword:00000000
>"UID"=""
>
>[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\textfile\Engines]
>
>[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\textfile\Engines\Text]
>"ImplicitCommitSync"=""
>"Threads"=dword:00000003
>"UserCommitSync"="Yes"
>*/
>
>-- "ODBC Data Sources" list entry for DSN textfile
>
>/*
>Windows Registry Editor Version 5.00
>
>[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\ODBC Data Sources]
>"textfile"="Microsoft Text Driver (*.txt; *.csv)"
>*/
>
>CREATE SERVER textfile_server CLASS 'ODBC' USING 'textfile';
>CREATE EXISTING TABLE textfile_table
> AT 'textfile_server;c:\\temp;;textfile.txt';
>SELECT * FROM textfile_table;
>
>-- Resulting error:
>
>[Sybase][ODBC Driver][Adaptive Server Anywhere]Server
>'textfile_server': [Microsoft][ODBC Text Driver] The Microsoft Jet
>database engine could not find the object 'c:\temp\textfile.txt'.
>Make sure the object exists and that you spell its name and the path
>name correctly.
>
>-- Tried again with AT 'textfile_server;c:\temp;;textfile.txt' and get
>*exactly* the same error message.
>
>-- Tried again with AT 'textfile_server;c:\\\\temp;;textfile.txt' and
>get *exactly* the same error message (only one \ survives).
>
>-- Tried again with c:\atemp and afile.txt as the folder and file
>names, same result.
>
>Breck Failed
>
>On 25 Oct 2003 18:43:05 -0700, MickeyBob wrote:
>
>>I'm experiencing a problem setting up a remote server to
>>text files.
>>
>>My ultimate goal is to import and export data from text
>>files which are downloaded and uploaded on a daily basis
>>to/from a PC running Windows XP Embedded OS and ASA 9.0. One
>>approach I'm trying is to set up a remote server that uses
>>Microsoft's ODBC text driver, then setup a stored procedure
>>that purges a native table and then populates it with the
>>data from the remote server and vice-versa.
>>
>>I can add the remote server specifying the DSN I've set up
>>(i.e., 'OnDisk') with the ODBC administrator utility. I can
>>also add a proxy table specifying the name of my text file
>>(i.e., 'Table1.txt'). While creating the new proxy table,
>>the wizard recognizes the column names successfully and the
>>proxy table seems to be created without a problem. (I have
>>tried this with and without an explicit table schema but
>>with identical results.) However, when I try to view the
>>data from Sybase Central, nothing shows up. I try to view
>>the proxy table in Interactive SQL but get the following
>>error:
>>
>>[Sybase][ODBC Driver][Adaptive Server Anywhere]General
>>error: Server 'OnDisk': [Microsoft][ODBC Text Driver] The
>>Microsoft Jet database engine could not find the object
>>'C:\DATA\Table1.csv'. Make sure the object exists and that
>>you spell its name and the path name correctly.
>>
>>(FYI, I think I'm using version 2.7 of the MDAC.)
>>
>>I've searched on the web for anything related to this error
>>and can't seem to find anything relevent and helpful. I've
>>seen some forum posts regarding 8.3 naming schemes but my
>>names all jive with that. I've also tried doing something
>>similar with Excel files and everything works fine.
>>
>>Any help in resolving this problem will be greatly
>>appreciated. Secondly, any alternatives you could propose
>>are of interest.
>>
>>Thanks

--
bcarter@risingroad.com
Mobile and Distributed Enterprise Database Applications
www.risingroad.com