ctakes-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seanfi...@apache.org
Subject svn commit: r1851404 - /ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/cr/JdbcCollectionReader.java
Date Tue, 15 Jan 2019 18:47:52 GMT
Author: seanfinan
Date: Tue Jan 15 18:47:52 2019
New Revision: 1851404

URL: http://svn.apache.org/viewvc?rev=1851404&view=rev
Log:
Fix oversight assuming that the sql statement is all uppercase.

Modified:
    ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/cr/JdbcCollectionReader.java

Modified: ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/cr/JdbcCollectionReader.java
URL: http://svn.apache.org/viewvc/ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/cr/JdbcCollectionReader.java?rev=1851404&r1=1851403&r2=1851404&view=diff
==============================================================================
--- ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/cr/JdbcCollectionReader.java
(original)
+++ ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/cr/JdbcCollectionReader.java
Tue Jan 15 18:47:52 2019
@@ -1,4 +1,4 @@
-/**
+/*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
  * distributed with this work for additional information
@@ -217,7 +217,7 @@ public class JdbcCollectionReader extend
          throws SQLException {
       StringBuffer sb = new StringBuffer();
       sb.append( "SELECT COUNT(*) " );
-      int idx = querySql.indexOf( "FROM" );
+      int idx = querySql.toUpperCase().indexOf( "FROM" );
       sb.append( querySql.subSequence( idx, querySql.length() ) );
       PreparedStatement cntStmt = conn.prepareStatement( sb.toString() );
 



Mime
View raw message