version 1.50, 2004/03/18 09:31:01
|
version 1.54, 2004/04/06 10:34:15
|
Line 1
|
Line 1
|
|
/* |
|
* Convert.java -- Converter class - Filemaker to SQL Converter |
|
* Copyright (C) 2003 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.util.*; |
import java.sql.*; |
import java.sql.*; |
import java.awt.Cursor; |
import java.awt.Cursor; |
Line 249 class Convert
|
Line 263 class Convert
|
FM2SQL.ProgressDialog dialog = null; |
FM2SQL.ProgressDialog dialog = null; |
if (FM2SQL.fmInstance != null) |
if (FM2SQL.fmInstance != null) |
{ |
{ |
dialog = new FM2SQL.ProgressDialog(FM2SQL.fmInstance); |
dialog = new FM2SQL.ProgressDialog(FM2SQL.fmInstance,bean); |
dialog.setTitle("Conversion running ..."); |
dialog.setTitle("Conversion running ..."); |
dialog.title.setText("Getting table data ..."); |
dialog.title.setText("Getting table data ..."); |
dialog.setLocation(FM2SQL.fmInstance.getLocationOnScreen().x + (FM2SQL.fmInstance.getWidth() - 400) / 2, FM2SQL.fmInstance.getLocationOnScreen().y + (FM2SQL.fmInstance.getHeight() - 250) / 2); |
dialog.setLocation(FM2SQL.fmInstance.getLocationOnScreen().x + (FM2SQL.fmInstance.getWidth() - 400) / 2, FM2SQL.fmInstance.getLocationOnScreen().y + (FM2SQL.fmInstance.getHeight() - 250) / 2); |
Line 456 class Convert
|
Line 470 class Convert
|
|
|
if (FM2SQL.fmInstance != null) |
if (FM2SQL.fmInstance != null) |
{ |
{ |
dialog = new FM2SQL.ProgressDialog(FM2SQL.fmInstance); |
dialog = new FM2SQL.ProgressDialog(FM2SQL.fmInstance,bean); |
dialog.setTitle("Conversion running ..."); |
dialog.setTitle("Conversion running ..."); |
dialog.title.setText("Getting table data ..."); |
dialog.title.setText("Getting table data ..."); |
dialog.setLocation(FM2SQL.fmInstance.getLocationOnScreen().x + (FM2SQL.fmInstance.getWidth() - 400) / 2, FM2SQL.fmInstance.getLocationOnScreen().y + (FM2SQL.fmInstance.getHeight() - 250) / 2); |
dialog.setLocation(FM2SQL.fmInstance.getLocationOnScreen().x + (FM2SQL.fmInstance.getWidth() - 400) / 2, FM2SQL.fmInstance.getLocationOnScreen().y + (FM2SQL.fmInstance.getHeight() - 250) / 2); |
Line 810 class Convert
|
Line 824 class Convert
|
for (int k = 0; k < row.size(); ++k) |
for (int k = 0; k < row.size(); ++k) |
{ |
{ |
obj = row.get(k); |
obj = row.get(k); |
if (obj instanceof ArrayList) |
|
if (obj instanceof ArrayList) |
if (obj instanceof ArrayList) |
obj = formatFileMakerArray((List) obj,delimiter); |
obj = formatFileMakerArray((List) obj,delimiter); |
|
|
String str = (obj == null) ? "NULL" : obj.toString(); |
String str = (obj == null) ? "NULL" : obj.toString(); |
|
if(obj instanceof Double) |
|
{ |
|
pstm.setDouble(k + 1, ((Double)obj).doubleValue()); |
|
}else |
if (!str.equals("NULL")) |
if (!str.equals("NULL")) |
pstm.setString(k + 1, str); |
pstm.setString(k + 1, str); |
else |
else |
Line 1590 class Convert
|
Line 1608 class Convert
|
FM2SQL.ProgressDialog dialog = null; |
FM2SQL.ProgressDialog dialog = null; |
if (FM2SQL.fmInstance != null) |
if (FM2SQL.fmInstance != null) |
{ |
{ |
dialog = new FM2SQL.ProgressDialog(FM2SQL.fmInstance); |
dialog = new FM2SQL.ProgressDialog(FM2SQL.fmInstance,bean); |
dialog.setTitle("Conversion running ..."); |
dialog.setTitle("Conversion running ..."); |
dialog.title.setText("Getting table data ..."); |
dialog.title.setText("Getting table data ..."); |
dialog.setLocation(FM2SQL.fmInstance.getLocationOnScreen().x + (FM2SQL.fmInstance.getWidth() - 400) / 2, FM2SQL.fmInstance.getLocationOnScreen().y + (FM2SQL.fmInstance.getHeight() - 250) / 2); |
dialog.setLocation(FM2SQL.fmInstance.getLocationOnScreen().x + (FM2SQL.fmInstance.getWidth() - 400) / 2, FM2SQL.fmInstance.getLocationOnScreen().y + (FM2SQL.fmInstance.getHeight() - 250) / 2); |