--- FM2SQL/Attic/Convert.java 2004/03/15 12:52:00 1.48 +++ FM2SQL/Attic/Convert.java 2004/03/23 11:57:06 1.51 @@ -1,3 +1,17 @@ +/* + * Convert.java -- Converter class - Filemaker to SQL Converter + * Copyright (C) 2004 Robert Gordesch (rogo@mpiwg-berlin.mpg.de) + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the Free + * Software Foundation; either version 2 of the License, or (at your option) + * any later version. Please read license.txt for the full details. A copy of + * the GPL may be found at http://www.gnu.org/copyleft/lgpl.html You should + * have received a copy of the GNU General Public License along with this + * program; if not, write to the Free Software Foundation, Inc., 59 Temple + * Place, Suite 330, Boston, MA 02111-1307 USA Created on 15.09.2003 by + * rogo + */ + import java.util.*; import java.sql.*; import java.awt.Cursor; @@ -1671,7 +1685,6 @@ class Convert Vector vecDest = null; // tempo beanDest.setConnection(destination); - int rowCount = (idField != "") ? myIds.size() : bean.getRowCount(query); String tempID = bean.getQC() + idField + bean.getQC(); String tempIDdest = beanDest.getQC() + convertText(idField) + beanDest.getQC(); @@ -1679,7 +1692,8 @@ class Convert int endIndex = -1; String tempQuery = query; String destQuery = query.replaceAll(names.get(tbIndex).toString(), destTableName); - String tempQueryDest = destQuery.substring(0,destQuery.lastIndexOf(destTableName)+destTableName.length()+1); + String tempQueryDest = destQuery; + // remove extra query parts destQuery.substring(0,destQuery.lastIndexOf(destTableName)+destTableName.length()+1); System.out.println("new Query " + tempQueryDest); if (!idField.equals("")) {