473,394 Members | 1,751 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Java / JDBC DB2 export

Hi,
how could I do an export of tables via Java / JDBC.
There are very big tables.

I thought about:
EXPORT TO c:\aa.ixf OF ixf SELECT * FROM TEST1

How could I call this from JDBC / Java?

Any other ideas?

Thanks a lot....

May 4 '06 #1
3 8421
in**@daten-host.de wrote:
Hi,
how could I do an export of tables via Java / JDBC.
There are very big tables.

I thought about:
EXPORT TO c:\aa.ixf OF ixf SELECT * FROM TEST1

How could I call this from JDBC / Java?


EXPORT is not a SQL statement so you can't invoke it through JDBC. What you
could do is to write a stored procedure that invokes the respective DB2
API. However, with a procedure you will export the data to a file on the
database server.

Could you elaborate a bit more on what you want to do with the exported
file?

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
May 4 '06 #2
First of all: Thanks!!!
I need to export some tabels from an DB2-Server (java is running on a
different server) an import it later to another DB2-Server.
I tried it with xml, but some of the tables are bigger than 3 GB :-(

Do you have an example for the stored procedure?

May 4 '06 #3
in**@daten-host.de wrote:
First of all: Thanks!!!
I need to export some tabels from an DB2-Server (java is running on a
different server) an import it later to another DB2-Server.
I tried it with xml, but some of the tables are bigger than 3 GB :-(
You should check that your file system allows files bigger than 2 GB. Maybe
this isn't DB2's fault. (I don't know the facilities of XML well enough in
this respect.)
Do you have an example for the stored procedure?


Have a look here: http://tinyurl.com/j5mxs This wraps the LOAD
functionality into a procedure. I'll have to adjust it to the EXPORT API,
which should be easy to accomplish.

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
May 4 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Melanie | last post by:
Hi For my company I work for I have to read and process files from Excel, Access or MS SQL. This way is no poblem. I use the JDBC/ODBC bridge to make a delimited file (*.csv) and work with that....
0
by: JShurmatz | last post by:
If anyone can shed some light on this problem I would greatly appreciate it. I am unsuccessfully trying to use a database connnection retrieved from a pool configured using Java System Web...
5
by: Hassan Naqvi | last post by:
Hi, Basically, I am Java developer. In past I have played with Oracle using Java (JDBC). But this is the time to play with IBM DB2 using Java (JDBC). So kindly help this DB2 newbie. I have a...
0
by: mailkhurana | last post by:
Hii , I am trying to use a type 2 driver to connect to DB2 0n AIX 5 I have a small java test to class to establish a conneciton with the db .. I am NOT using WAS or any appserver When I try to...
1
by: Markus Wollny | last post by:
Hi! I am trying to build PostgreSQL 7.4.3 with Java enabled; I've got Apache Ant version 1.5 and j2sdk1.4.1_05 installed: Verifiying ant: # which javac /usr/java/j2sdk1.4.1_05/bin/javac #...
2
by: Jobs | last post by:
Download the JAVA , .NET and SQL Server interview with answers Download the JAVA , .NET and SQL Server interview sheet and rate yourself. This will help you judge yourself are you really worth of...
2
by: astolpho | last post by:
I am using a slightly outdated reference book on J2EE programming. It gives 2 methods of creating a database used in its casestudies. The first is an ANT script that gives the following output: ...
0
oll3i
by: oll3i | last post by:
package library.common; import java.sql.ResultSet; public interface LibraryInterface { public ResultSet getBookByAuthor(String author); public ResultSet getBookByName(String name);
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.