on 2011 Oct 07 2:12 PM
I am writing a java app that is connecting to a Sybase IQ instance. I am using the iAnywhere JDBC driver that came with SQL Anywhere 11 (jodbc.jar). In my java project I am using jodbc.jar from SQL Anywhere 11. My connection string is pretty simple. "jdbc:ianywhere:DSN=dw". I want to be able to 'export' a table. Both unload and output redirection result in errors.
unload table #test to '\\servertest_bcp.out';
results in the following error: [Sybase][ODBC Driver][Sybase IQ]Feature 'unload from non-SQL Anywhere tables' not implemented
select * from #test >#U:test_bcp.out; [Sybase][ODBC Driver][Sybase IQ]Syntax error near '>'
Request clarification before answering.
I think the UNLOAD error message is pretty clear - when you are connected to an IQ server you cannot use the UNLOAD statement to unload any table except tables stored in SYSTEM (i.e. tables that reside in the SQL Anywhere store). The reason is because the IQ piece of the server (where your table is stored) does not support the UNLOAD statement.
Regarding your error using '>' redirection - The issue is that '>' is not understood by the server - it is the shell that handles output redirection of stdout from an application. Note also that older versions of dbisql also handled a form of '>' redirection - see the tip mentioned on this page about exporting data.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
50 | |
9 | |
8 | |
6 | |
5 | |
5 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.