Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Event to import a text file 1

Status
Not open for further replies.

PetersWeb

Programmer
Apr 26, 2000
29
AU
I'm attempting to import a CSV text file once a day at a specific time by using an Event.

The following works perfectly in Interactive SQL:

INPUT INTO dba.myTable
FROM C:\\myDirectory\\fred.txt
FORMAT ascii;

Works like a charm!

I've since read in the documentation that INPUT is a command that can't be used in an event. Is there some other way I can do this via an event?

[sig]<p>Peter Toby<br><a href=mailto:webmaster@petertoby.com.au>webmaster@petertoby.com.au</a><br><a href= site is under construction but getting better![/sig]
 
I believe INPUT is a command that is exclusive to ISQL.
Adaptive Server Anywhere supports INPUT in ISQL, but also has a LOAD TABLE statement that will work in SQL commands issued by a client app, stored procedure, or trigger.

If you are using Adaptive Server Enterprise, see if it supports the LOAD TABLE statement. If so, that should be what you want.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top