db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From myrn...@apache.org
Subject svn commit: r612827 - in /db/derby/code/trunk/java: demo/toursdb/ testing/org/apache/derbyTesting/functionTests/tests/demo/
Date Thu, 17 Jan 2008 14:29:53 GMT
Author: myrnavl
Date: Thu Jan 17 06:28:57 2008
New Revision: 612827

URL: http://svn.apache.org/viewvc?rev=612827&view=rev
Log:
replacing the gif files used in the MAPS table in toursdb example database.

Added:
    db/derby/code/trunk/java/demo/toursdb/cupisle.gif   (with props)
    db/derby/code/trunk/java/demo/toursdb/smallisle.gif   (with props)
    db/derby/code/trunk/java/demo/toursdb/witchisle.gif   (with props)
Removed:
    db/derby/code/trunk/java/demo/toursdb/BART.gif
    db/derby/code/trunk/java/demo/toursdb/Caltrain.gif
    db/derby/code/trunk/java/demo/toursdb/LightRail.gif
Modified:
    db/derby/code/trunk/java/demo/toursdb/build.xml
    db/derby/code/trunk/java/demo/toursdb/insertMaps.java
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/demo/CheckToursDBTest.java

Modified: db/derby/code/trunk/java/demo/toursdb/build.xml
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/demo/toursdb/build.xml?rev=612827&r1=612826&r2=612827&view=diff
==============================================================================
--- db/derby/code/trunk/java/demo/toursdb/build.xml (original)
+++ db/derby/code/trunk/java/demo/toursdb/build.xml Thu Jan 17 06:28:57 2008
@@ -116,7 +116,7 @@
   <target name="copyfiles">
     <copy todir="${out.dir}/${derby.testing.functest.dir}/tests/demo">
       <fileset dir="${derby.demo.src.dir}/toursdb"
-               includes="*.sql,BART.gif,Caltrain.gif,LightRail.gif"/>
+               includes="*.sql,*.gif"/>
     </copy>
   </target>
 

Added: db/derby/code/trunk/java/demo/toursdb/cupisle.gif
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/demo/toursdb/cupisle.gif?rev=612827&view=auto
==============================================================================
Binary file - no diff available.

Propchange: db/derby/code/trunk/java/demo/toursdb/cupisle.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: db/derby/code/trunk/java/demo/toursdb/insertMaps.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/demo/toursdb/insertMaps.java?rev=612827&r1=612826&r2=612827&view=diff
==============================================================================
--- db/derby/code/trunk/java/demo/toursdb/insertMaps.java (original)
+++ db/derby/code/trunk/java/demo/toursdb/insertMaps.java Thu Jan 17 06:28:57 2008
@@ -72,46 +72,43 @@
 		ps = conn.prepareStatement
 		("insert into maps (map_name, region, area, photo_format, picture) values (?,?,?,?,?)");
 
-		ps.setString(1,"BART");
-		ps.setString(2,"Bay Area");
+		ps.setString(1,"North Ocean");
+		ps.setString(2,"Cup Island");
 		ps.setBigDecimal(3, new BigDecimal("1776.11"));
 		ps.setString(4,"gif");
 		String fileName;
 		if (path == null)
-			fileName="BART.gif";
+			fileName="cupisle.gif";
 		else
-			fileName=path + File.separator + "BART.gif";
+			fileName=path + File.separator + "cupisle.gif";
 		File file = new File (fileName);
 		InputStream fileIn = new FileInputStream(file);
 		ps.setBinaryStream(5, fileIn, (int)file.length());
 		int numrows = ps.executeUpdate();
 		fileIn.close();
 
-		ps.setString(1,"Caltrain");
-		ps.setString(2,"West Bay");
+		ps.setString(1,"Middle Ocean");
+		ps.setString(2,"Small Island");
 		ps.setBigDecimal(3, new BigDecimal("1166.77"));
 		ps.setString(4,"gif");
 		if (path == null)
-			fileName="Caltrain.gif";
+			fileName="smallisle.gif";
 		else
-			fileName=path + File.separator + "Caltrain.gif";
+			fileName=path + File.separator + "smallisle.gif";
 		file = new File (fileName);
 		fileIn = new FileInputStream(file);
 		ps.setBinaryStream(5, fileIn, (int)file.length());
 		numrows = numrows + ps.executeUpdate();
 		fileIn.close();
 
-		ps.setString(1,"Light Rail");
-		ps.setString(2,"Santa Clara Valley");
+		ps.setString(1,"South Ocean");
+		ps.setString(2,"Witch Island");
 		ps.setBigDecimal(3, new BigDecimal("9117.90"));
 		ps.setString(4,"gif");
-		// To insert LightRail.gif would give an error because that BLOB
-		// is larger than the size indicated for the column.
-		// But we don't want to make toursDB bigger in the distribution
 		if (path == null)
-			fileName="BART.gif";
+			fileName="witchisle.gif";
 		else
-			fileName=path + File.separator + "BART.gif";
+			fileName=path + File.separator + "witchisle.gif";
 		file = new File (fileName);
 		fileIn = new FileInputStream(file);
 		ps.setBinaryStream(5, fileIn, (int)file.length());

Added: db/derby/code/trunk/java/demo/toursdb/smallisle.gif
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/demo/toursdb/smallisle.gif?rev=612827&view=auto
==============================================================================
Binary file - no diff available.

Propchange: db/derby/code/trunk/java/demo/toursdb/smallisle.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: db/derby/code/trunk/java/demo/toursdb/witchisle.gif
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/demo/toursdb/witchisle.gif?rev=612827&view=auto
==============================================================================
Binary file - no diff available.

Propchange: db/derby/code/trunk/java/demo/toursdb/witchisle.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/demo/CheckToursDBTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/demo/CheckToursDBTest.java?rev=612827&r1=612826&r2=612827&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/demo/CheckToursDBTest.java
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/demo/CheckToursDBTest.java
Thu Jan 17 06:28:57 2008
@@ -52,8 +52,9 @@
    public static Test basesuite(String name) {
         TestSuite suite = new TestSuite(CheckToursDBTest.class, name);
         Test test = new SupportFilesSetup(suite, new String[] {
-                "functionTests/tests/demo/BART.gif",
-                "functionTests/tests/demo/Caltrain.gif" });
+                "functionTests/tests/demo/cupisle.gif",
+                "functionTests/tests/demo/smallisle.gif",
+                "functionTests/tests/demo/witchisle.gif" });
         return test;
     }
 
@@ -156,11 +157,11 @@
         JDBC.assertSingleValueResultSet(ps.executeQuery(), "B747");
         stmt.execute("update FLIGHTS set AIRCRAFT='B777' where FLIGHT_ID = 'AA1134'");
         JDBC.assertSingleValueResultSet(ps.executeQuery(), "B747");
-        ps = prepareStatement("select REGION from MAPS where MAP_NAME = 'BART'");
-        JDBC.assertSingleValueResultSet(ps.executeQuery(), "Bay Area");
-        stmt.execute("update MAPS set REGION='San Francisco Bay Area' where MAP_NAME = 'BART'");
+        ps = prepareStatement("select REGION from MAPS where MAP_NAME = 'North Ocean'");
+        JDBC.assertSingleValueResultSet(ps.executeQuery(), "Cup Island");
+        stmt.execute("update MAPS set REGION='Northern Ocean' where MAP_NAME = 'North Ocean'");
         JDBC.assertSingleValueResultSet(ps.executeQuery(),
-                "San Francisco Bay Area");
+                "Northern Ocean");
         // Flight_history is now has 1 row, because of TRIG1
         ps = prepareStatement("select STATUS from FLIGHTS_HISTORY where FLIGHT_ID = 'AA1134'");
         JDBC.assertSingleValueResultSet(ps.executeQuery(),



Mime
View raw message