alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

HSQLDB example source code file (dsv-rejects.sql)

This example HSQLDB source code file (dsv-rejects.sql) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - HSQLDB tags/keywords

count, count, create, create, date, date, dsv, dsv_row_delim, int, int, real, should, table, varchar

The HSQLDB dsv-rejects.sql source code

/*
 * $Id: dsv-rejects.sql 307 2007-06-23 03:08:06Z unsaved $
 *
 * Tests proper rejection of bad DSV input records
 */

/** This is the default on UNIX.
 *  Our *.dsv test files are stored as binaries, so this is required
 *  to run tests on Windows: */
* *DSV_ROW_DELIM = \n

CREATE TABLE t (i INT, r REAL, d DATE, t TIMESTAMP, v VARCHAR, b BOOLEAN);

* *DSV_REJECT_REPORT = ${java.io.tmpdir}/sqltoolutst-${user.name}.html
\m dsv-rejects.dsv

SELECT COUNT(*) FROM t;

*if (*? != 2)
    \q Should have imported 2 good DSV records, but imported *{?}
*end if

Other HSQLDB examples (source code examples)

Here is a short list of links related to this HSQLDB dsv-rejects.sql source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.