Java: generate CREATE TABLE code from an existing table You can try using the dblook tool to dump an Apache Derby database table into a sql file.