JDBC-ODBC Bridge to SPSS data files - Result Set Type is not supported

Hello,
As mentioned in the subject I am trying to read SPSS data files using the SPSS 32-Bit data driver, ODBC and the JDBC-ODBC Bridge.
Using this SPSS Driver I manged to read the data directly into an MS-SQL Server using:
SELECT [...] FROM
OPENROWSET(''MSDASQL.1'',''DRIVER={SPSS 32-BIT Data Driver (*.sav)};DBQ=' SomePathWhereTheFilesAre';SERVER=NotTheServer'', ''SELECT 'SomeSPSSColumn' FROM "'SomeSPSSFileNameWithoutExt'"'') AS a
This works fine!
Using Access and an ODBC System DNS works for IMPORTING but NOT for LINKING.
It is even possible to read the data using the very slow SPSS API.
However, when it comes to JDBC-ODBC the below code does only work in part. The driver is loaded successfully, but when it comes to transferring data into the resultset object the error
SQLState: null
Result Set Type is not supported
Vendor: 0
occurs.
The official answer from SPSS is to use .Net or to use their implementation with Python in their new version 14.0. But this is obviously not an option when you want to use only Java.
Does anybody have experience with SPSS and JDBC-ODBC??? I have tried the possible ResultSet Types, which I took from:
http://publib.boulder.ibm.com/infocenter/db2luw/v8/index.jsp?topic=/com.ibm.db2.udb.doc/ad/rjvdsprp.htm
and none of them worked.
Thank you in advance for your ideas and input & stay happy!
Here the code without all the rest of the class arround it:
// Module:  SimpleSelect.java
// Description: Test program for ODBC API interface.  This java application
// will connect to a JDBC driver, issue a select statement
// and display all result columns and rows
// Product: JDBC to ODBC Bridge
// Author:  Karl Moss
// Date:  February, 1996
// Copyright: 1990-1996 INTERSOLV, Inc.
// This software contains confidential and proprietary
// information of INTERSOLV, Inc.
public static void main1() {
  String url   = "jdbc:odbc:SomeSystemDNS";
  String query = "SELECT SomeSPSSColumn FROM 'SomeSPSSFileName'";
  try {
    // Load the jdbc-odbc bridge driver
    Class.forName ("sun.jdbc.odbc.JdbcOdbcDriver");
    DriverManager.setLogStream(System.out);
    // Attempt to connect to a driver.  Each one
    // of the registered drivers will be loaded until
    // one is found that can process this URL
    Connection con = DriverManager.getConnection (url);
    // If we were unable to connect, an exception
    // would have been thrown.  So, if we get here,
    // we are successfully connected to the URL
    // Check for, and display and warnings generated
    // by the connect.
    checkForWarning (con.getWarnings ());
    // Get the DatabaseMetaData object and display
    // some information about the connection
    DatabaseMetaData dma = con.getMetaData ();
    System.out.println("\nConnected to " + dma.getURL());
    System.out.println("Driver       " +
      dma.getDriverName());
    System.out.println("Version      " +
      dma.getDriverVersion());
    System.out.println("");
    // Create a Statement object so we can submit
    // SQL statements to the driver
    Statement stmt = con.createStatement(ResultSet.TYPE_FORWARD_ONLY ,ResultSet.CONCUR_READ_ONLY);
    // Submit a query, creating a ResultSet object
    ResultSet rs = stmt.executeQuery (query);
    // Display all columns and rows from the result set
    dispResultSet (rs);
    // Close the result set
    rs.close();
    // Close the statement
    stmt.close();
    // Close the connection
    con.close();
  }

Thank you for your reply StuDerby!
Actually the above script was before, as you suggested, leaving the ResultSetTeype default. This did not work...
I am getting gray hair with SPSS - in terms of connectivity and "integratebility" none of their solutions offered is sufficient from my point of view.
Variable definitions can only be read by the slow API, data can only be read by Python or Microsoft Products... and if you want to combine both you are in big trouble. I can only assume that this is a company strategy to sell their Dimensions Platform to companies versus having companies developping their applications according to business needs.
Thanks again for any furthur suggestions and I hope, that some SPSS Developper will see this post!
Cheers!!

Similar Messages

  • JDBC ODBC bridge connections using 2.1.1

    Hi,
    I have reviewed a lot of postings related to JDBC and third party drivers and understand how to connect to the packaged drivers such as MySQL and MS SQL Server/Sybase. Where I'm stuck is the reference in the Connections help to JDBC. We have a ODBC system DSN that's not part of the existing JDBC drivers. The help implies it's possible to create a JDBC:ODBC bridge connection and that JDBC:ODBC bridge functionality is part of the JDK therefore should not require additional jar files. However, the JDBC tab is not an available connection type by default. I traced the JDBC ODBC bridge to the rt.jar and tried adding that to the third party extensions but that has not resulted in the JDBC tab becoming available.
    Is the JDBC tab only available when using commercial JDBC ODBC bridge drivers ?
    For all other connections (DB2, TimesTen, Teradata etc) the help is very specific about which jar files you need and any other requirements but the JDBC section it is unclear how you enable JDBC connectivity.
    Thanks
    Steven
    Edited by: slisint on 14-Jan-2011 18:07

    We are using the JDBC-ODBC bridge to do a prepared
    statement. I have seen other bugs that suggest this
    is problematic with older version of JRE, but was
    supposedly fixed in later versions.
    java.sql.SQLException: General errorIf it is not too late, check the following link:
    http://java.sun.com/j2se/1.3/docs/guide/jdbc/getstart/GettingStartedTOC.fm.html
    Sections 6.1.3 and 8 (especially tables at the end).
    I had the same case, and the problem was that the field in the Oracle database was defined as NUMBER(4), witch is equivalent to INTEGER in JDBC types, and function setInt should be used with INTEGER, instead of setLong.
    This is explained in sections I mentioned.

  • Connecting remote FoxPro dbf file using jdbc odbc bridge driver?

    Hi all,
    I am new to this topic, (even I read some threads)
    I need to access some FoxPro tables (dbf files) and select some data and save to an oracle table. what is the best method to do this?
    If I use java as development tool. which other drivers or methods to use beside jdbc-odbc driver?
    I read from this link but I didn't understand.
    http://java.sun.com/products/jdbc/faq.html#5
    "5. How can I use the JDBC API to access a desktop database like Microsoft Access over the network?
    Most desktop databases currently require a JDBC solution that uses ODBC underneath. This is because the vendors of these database products haven't implemented all-Java JDBC drivers.
    The best approach is to use a commercial JDBC driver that supports ODBC and the database you want to use. See the JDBC drivers page for a list of available JDBC drivers.
    The JDBC-ODBC bridge from Sun's Java Software does not provide network access to desktop databases by itself. The JDBC-ODBC bridge loads ODBC as a local DLL, and typical ODBC drivers for desktop databases like Access aren't networked. The JDBC-ODBC bridge can be used together with the RMI-JDBC bridge, however, to access a desktop database like Access over the net. This RMI-JDBC-ODBC solution is free.
    "

    Another solution by using HXTT DBF, a commercial type 4 JDBC package: You should read Remote Access Questions section at http://www.hxtt.net/en/software/dbf/faq.html#remote .

  • To run a report from command line, when using jdbc-odbc bridge

    Hi,
    How to run a report from command line, when using jdbc-odbc bridge?
    Usually with tns, we do by "rwrun module=<> userid=<user>/<passwd>@tns".
    with odbc, we do by "rwrun module=<> userid=<user>/<passwd>@odbc:DSN"
    Please specify, what is command line arguments for jdbc-odbc bridge driver?
    Environment : Oracle 9i Report Builder on WinNT
    Database : Sybase
    Regards,
    Ramanan

    Hello Ramanan,
    Report Builder : connect JDBC Query in Report Builder is to through Connection Dialog in JDBC Query Editor. User can use a Sign on parameter (can use, default : P_JDBCPDS or can create new) to connect to JDBC Data Source. Connection once made will be mentioned and will be reused through out Reports Builder.
    JDBC PDS allows user to connect one or more same or different kind of databases.
    While running report through runtime or Server, user can pass the sign on parameter(connection string) value, like any other user parameter.
    Syntax for connection string : <username>/<password>@databaseURL . The syntax of database part of connection string depend on the type of JDBC Driver used to connect to Data Source while designing the JDBC Query. databaseURL refer to the location of the database and its format depend on the JDBCPDS river selected in design time while creating the JDBC Query.
    rwrun eg :
    rwrun report=jdbc_odbc.rdf destype=file desname=output.html desformat=html P_JDBCPDS=scott/tiger@database
    Server eg :
    http://server.com:8888/servlet/RWServlet?server=MyReportServer+report=jdbc_odbc.rdf+destype=cache+desformat=html+P_JDBCPDS=scott/tiger@database
    http :
    Please see ORACLE_HOME/reports/conf/jdbcpds.conf for more information.
    With Regards
    Reports Team

  • JDBC-ODBC Bridge seems to slow down after a while

    Hi,
    I've got a weird problem going on with an application I'm writing. I hope someone can tell me what I'm doing wrong.
    The problem I'm encountering is in he code shown below. The function getAllGamesForATeam is creating a list of items in an ArrayList and passing it back to an Event handler so that I can put it in the session of a servlet. The first time I run this code, it is fast. Fast enough to use on a servlet. The second time it runs, it is MUCH slower...too slow to use on a servlet. The third time it runs, it gets even worse.
    I am using the JDBC-ODBC bridge to access my database which is in Access 97. I do have connection pooling enabled on the database. Still it is slow.
    If you have any ideas, I would appreciate it. Here's the code:
    // GameBean.java
    // A class to represent a Game in my College Hockey Program
    // Based on Team and League tables.
    package MyBeans;
    import java.io.*;
    import java.sql.*;
    import java.util.*;
    import javax.servlet.http.*;
    * <p>This is the Java bean used to get and display information about
    * items for sale in our web based store.
    * @version 1.0.0 08/13/2001
    * @author Kevin Yetman
    * @see DBBeanBase
    public class GameBean extends DBBeanBase
    * <p>Default constructor, creates an empty {@link GameBean}.
    public GameBean()
    super();
    * <p>Copy constructor. This constructor creates a {@link GameBean} object
    * that is initially populated with a copy of the {@link java.util.Map} specified
    * as a parameter to this constructor. All {@link java.util.Map} Maps should
    * implement a copy constructor.
    * @param copyThisMap the {@link Map} used to initialize this {@link GameBean} object.
    public GameBean(Map copyThisMap)
    super(copyThisMap);
    * <p>This constructor creates an {@link GameBean} object and
    * populates it with the fields in a {@link java.sql.ResultSet}.
    * @param rs The {@link java.sql.ResultSet} object used to populate
    * this class with information about an item.
    * @throws java.sql.SQLException if there is an error iterating the
    * {@link java.sql.ResultSet}.
    protected GameBean(ResultSet rs) throws SQLException
    super(rs);
    * <p>This constructor creates an {@link GameBean} object associated with the
    * specified item id. If there is no record in the data source with the
    * specified item id, an exception is thrown.
    * @param conneciton The {@link java.sql.Connection} object used to execute
    * the select statement that will retrieve the item information.
    * @param iLeagueId specifies the league id used to populate this object.
    * @throws java.sql.SQLException if there is an error selecting the item
    * information.
    * @throws java.lang.Exception if the item id is invalid.
    public GameBean(Connection connection, int iGameId) throws SQLException, Exception
    super();
    String strSQL="SELECT GameIndex, Month, Day, Year, HomeTeamIndex, VisitorTeamIndex, HomeTeamScoredFirst, LeagueGame, NeutralSiteGame, PlayoffGame, HomeTeamGoals, VisitorTeamGoals FROM Game WHERE GameIndex=" + iGameId;
    Statement statement = connection.createStatement();
    ResultSet rs = statement.executeQuery(strSQL);
    if (rs.next())
    populateFromResultSet(rs);
    else
    throw new Exception("Invalid game Id: " + iGameId);
    putInTeamNames(connection);
    * <p>This method returns the league's index.
    * @return the league's index.
    public void putInTeamNames(Connection connection)
    throws SQLException
    String strSQL="SELECT TeamName FROM Team WHERE TeamIndex=" + getHomeTeamIndex();
    Statement statement = connection.createStatement();
    ResultSet rs = statement.executeQuery(strSQL);
    if( rs.next() )
    put("HOMETEAMNAME", rs.getString("TeamName"));
    strSQL="SELECT TeamName FROM Team WHERE TeamIndex=" + getVisitorTeamIndex();
    rs=statement.executeQuery(strSQL);
    if( rs.next() )
    put("VISITORTEAMNAME", rs.getString("TeamName"));
    * <p>This method returns the league's index.
    * @return the league's index.
    public String getGameIndex()
    return get("GAMEINDEX").toString();
    * <p>This method returns the name of the league.
    * @return the name of the league.
    public String getMonth()
    return get("MONTH").toString();
    * <p>This method returns the name of the league.
    * @return the name of the league.
    public String getDay()
    return get("DAY").toString();
    * <p>This method returns the name of the league.
    * @return the name of the league.
    public String getYear()
    return get("YEAR").toString();
    * <p>This method returns the name of the league.
    * @return the name of the league.
    public String getHomeTeamName()
    return get("HOMETEAMNAME").toString();
    * <p>This method returns the league's nickname.
    * @return the league's nickname.
    public String getVisitorTeamName()
    return get("VISITORTEAMNAME").toString();
    * <p>This method returns the name of the league.
    * @return the name of the league.
    public String getHomeTeamIndex()
    return get("HOMETEAMINDEX").toString();
    * <p>This method returns the league's nickname.
    * @return the league's nickname.
    public String getVisitorTeamIndex()
    return get("VISITORTEAMINDEX").toString();
    * <p>This method returns the league's nickname.
    * @return the league's nickname.
    public String getLeagueGame()
    return get("LEAGUEGAME").toString();
    * <p>This method returns the league's nickname.
    * @return the league's nickname.
    public String getNeutralSiteGame()
    return get("NEUTRALSITEGAME").toString();
    * <p>This method returns the league's nickname.
    * @return the league's nickname.
    public String getPlayoffGame()
    return get("PLAYOFFGAME").toString();
    * <p>This method returns the league's nickname.
    * @return the league's nickname.
    public String getHomeTeamScoredFirst()
    return get("HOMETEAMSCOREDFIRST").toString();
    * <p>This method returns the league's nickname.
    * @return the league's nickname.
    public String getHomeTeamGoals()
    return get("HOMETEAMGOALS").toString();
    * <p>This method returns the league's automatic bids.
    * @return the league's automatic bids.
    public String getVisitorTeamGoals()
    return get("VISITORTEAMGOALS").toString();
    * <p>This method returns a textual representation of this {@link ItemBean}.
    * @return a textual representation of this {@link ItemBean}.
    public String toString()
    StringBuffer sb=new StringBuffer();
    sb.append("GameIndex: " + getGameIndex() + "\n");
    sb.append("HomeTeamScoredFirst: " + getHomeTeamScoredFirst() + "\n");
    sb.append("PlayoffGame: " + getPlayoffGame() + "\n");
    sb.append("LeagueGame: " + getLeagueGame() + "\n");
    sb.append("NeutralSiteGame: " + getNeutralSiteGame() + "\n");
    sb.append("HomeTeamIndex: " + getHomeTeamIndex() + "\n");
    sb.append("VisitorTeamIndex: " + getVisitorTeamIndex() + "\n");
    sb.append("HomeTeamName: " + getHomeTeamName() + "\n");
    sb.append("VisitorTeamName: " + getVisitorTeamName() + "\n");
    sb.append("Month: " + getMonth() + "\n");
    sb.append("Day: " + getDay() + "\n");
    sb.append("Year: " + getYear() + "\n");
    return sb.toString();
    * <p>This method returns a {@link java.util.Collection} of all of the teams
    * in the data source.
    * @param connection The {@link java.sql.Connection} object used to execute
    * the select statement that will retrieve the teams.
    * @return a {@link java.util.Collection} of all of the teams in the data source.
    * @throws java.sql.SQLException if there is an error selecting the items.
    public static Collection getAllGames(Connection connection) throws SQLException
    Collection col=new ArrayList(1100);
    String strSQL = "SELECT GameIndex, Month, Day, Year, HomeTeamIndex, VisitorTeamIndex, HomeTeamScoredFirst, LeagueGame, NeutralSiteGame, PlayoffGame, HomeTeamGoals, VisitorTeamGoals FROM Game";
    Statement statement = connection.createStatement();
    ResultSet rs = statement.executeQuery(strSQL);
    while(rs.next())
    GameBean currentGame=new GameBean(rs);
    currentGame.putInTeamNames(connection);
    col.add(currentGame);
    return col;
    * <p>This method returns a {@link java.util.Collection} of all of the teams
    * in the data source.
    * @param connection The {@link java.sql.Connection} object used to execute
    * the select statement that will retrieve the teams.
    * @return a {@link java.util.Collection} of all of the teams in the data source.
    * @throws java.sql.SQLException if there is an error selecting the items.
    public static Collection getAllGamesForALeague(Connection connection, String leagueNickName) throws SQLException
    Collection col=new ArrayList(500);
    String strSQL = "SELECT LeagueIndex FROM League WHERE LeagueNickName='" + leagueNickName + "'";
    Statement statement = connection.createStatement();
    ResultSet rs = statement.executeQuery(strSQL);
    int leagueIndex=-1;
    if( rs.next() )
    leagueIndex=rs.getInt("LeagueIndex");
    strSQL = "SELECT GameIndex, Month, Day, Year, HomeTeamIndex, VisitorTeamIndex, HomeTeamScoredFirst, LeagueGame, NeutralSiteGame, PlayoffGame, HomeTeamGoals, VisitorTeamGoals FROM Game";
    strSQL+=" WHERE (HomeTeamIndex IN (SELECT TeamIndex FROM Team WHERE LeagueIndex=" + leagueIndex + ")) OR";
    strSQL+=" (VisitorTeamIndex IN (SELECT TeamIndex FROM Team WHERE LeagueIndex=" + leagueIndex + "))";
    strSQL+=" ORDER BY Year, Month, Day";
    statement = connection.createStatement();
    rs = statement.executeQuery(strSQL);
    while(rs.next())
    GameBean currentGame=new GameBean(rs);
    currentGame.putInTeamNames(connection);
    System.out.println(currentGame.getGameIndex());
    col.add(currentGame);
    return col;
    * <p>This method returns a {@link java.util.Collection} of all of the teams
    * in the data source.
    * @param connection The {@link java.sql.Connection} object used to execute
    * the select statement that will retrieve the teams.
    * @return a {@link java.util.Collection} of all of the teams in the data source.
    * @throws java.sql.SQLException if there is an error selecting the items.
    public static Collection getAllGamesForATeam(Connection connection, String teamName)
    throws SQLException
    Collection col=new ArrayList(50);
    String strSQL = "SELECT TeamIndex FROM Team WHERE TeamName='" + teamName + "'";
    Statement statement = connection.createStatement();
    ResultSet rs = statement.executeQuery(strSQL);
    int teamIndex=-1;
    if( rs.next() )
    teamIndex=rs.getInt("TeamIndex");
    strSQL = "SELECT GameIndex, Month, Day, Year, HomeTeamIndex, VisitorTeamIndex, HomeTeamScoredFirst, LeagueGame, NeutralSiteGame, PlayoffGame, HomeTeamGoals, VisitorTeamGoals FROM Game";
    strSQL+=" WHERE (HomeTeamIndex=" + teamIndex + ") OR";
    strSQL+=" (VisitorTeamIndex=" + teamIndex + ")";
    strSQL+=" ORDER BY Year, Month, Day";
    statement = connection.createStatement();
    rs = statement.executeQuery(strSQL);
    while(rs.next())
    GameBean currentGame=new GameBean(rs);
    currentGame.putInTeamNames(connection);
    col.add(currentGame);
    return col;
    // The unit test method public static void main(String[] args)
    // has been moved to ..\TestPrograms\TestItemBean.java so that this
    // class can be used in the package MyBeans.
    /////////////////////////////////// END OF FILE //////////////////////////////

    Where do you close the ResultSet?
    Where do you close the Statement?
    Presumably you only create one connection for all users or you close it somewhere.

  • Weblogic server using jdbc-odbc bridge

    I want to connect to database through jdbc-odbc bridge.I am using web logic server. When i creating new jdbc connection pool a error comes that driver class is not on classpath. how i rectify this problem? how I make weblogic to recognize sun.jdbc.odbc.JdbcOdbcDriver?

    like any other library...
    put the .jar file of the lib in the WEB-INF/lib of
    your webappWrong in so many ways.
    You don't add drivers to WEB-INF/lib if they're being acquired as datasources - the server needs access to the driver to create the data source. If you're not using a DataSource but materializing the connection directly, then this advice is semi-correct, but it's a crappy way to build a web app.
    You don't normally add a JAR for the Sun JDBC ODBC bridge anyway as it's present by default in their J2SE implementation.
    And finally, I think WebLogic doesn't use the Sun J2SE implementation anyway, so it's possible that the bridge is not available at all.
    So the correct answer is: Don't use the bridge driver. Acquire a driver for your specific database and use that. And make sure that it's available to the application server. If you absolutely must use the bridge driver, you're going to have to use the Sun J2SE implementation to run WebLogic - and I think you'll have to consult the WebLogic site for help with that.

  • JDBC-ODBC bridge connection failure.

    I'm new to JDBC and JDeveloper and am having some difficulty
    getting through the database applet tutorial.
    I'm trying to connect to a Microsoft Access database using the
    JDBC-ODBC Bridge. This is an interim stage before using a Linux
    Oracle database which is not yet up and running.
    When trying to add a data form, the database wizard fails at
    step 4 of 7 after selecting the Sun JDBC-ODBC bridge and the
    required data source the following error is presented:
    Connection error
    Vendor code 84
    [Microsoft][ODBC Microsoft Access 97 Driver]Driver not capable
    I also tried setting up (using ODBC manager) a System DSN for a
    text and Excel data source, but met similar problems e.g:
    [Microsoft][ODBC Excel Driver]Driver not capable
    Currently JDeveloper Beta 2.0 (build 184) and the ODBC source
    are on the same NT4.0 (SP4) machine.
    To confuse matters I'm actually running Access 95, rather than
    Access 97.
    I have previously successfully connected to an Access ODBC
    source via JDBC in a Java application (not applet) when
    following a tutorial example that comes with the Sun JDK 1.2. I
    note, however, that jdbcodbc.dll that's part of JDK 1.2 is newer
    (and bigger - 32K 01Dec98) than that supplied with the
    JDeveloper Beta 2.0 (22K 05Nov98)
    I'm a bit lost with this problem since nothing happens after
    pressing help on the error dialog, and I'm not sure where to
    look for log files etc. to further debug the problem. Any help
    would be gratefully received!
    null

    The error indicates that the bridge is making a call to the
    driver which it cannot handle -- either because the call is
    invalid/unreasonable or because the driver doesn't implement the
    functionality requested. An ODBC trace will determine which of
    the two is true. If the first, you need to contact the bridge
    provider to get a fix. If the second -- the ODBC driver
    provider.
    null

  • Help!  Crashing JVM while doing SELECT statement through JDBC-ODBC bridge

    Hi everyone,
    Help please. I am working on a project on my own computer using the jdk version 1.5.0_04.
    The project involves running a select on a Microsoft Access 2003 database via the JDBC-ODBC bridge. The database is registered in the ODBC database sources, and it works fine in those other projects.
    Yet, when I'm running similar code in this project, it crashes the Java Virtual Machine. I get the following in a log file:
    # An unexpected error has been detected by HotSpot Virtual Machine:
    # EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c901010, pid=2308, tid=1364
    # Java VM: Java HotSpot(TM) Client VM (1.5.0_04-b05 mixed mode, sharing)
    # Problematic frame:
    # C [ntdll.dll+0x1010]
    --------------- T H R E A D ---------------
    Current thread (0x000360f8): JavaThread "main" [_thread_in_native, id=1364]
    siginfo: ExceptionCode=0xc0000005, reading address 0x00000018
    Registers:
    EAX=0x00000004, EBX=0x26bb5250, ECX=0x7ffde000, EDX=0x00000004
    ESP=0x0007f8d8, EBP=0x0007f8f0, ESI=0x00000000, EDI=0x02ea1590
    EIP=0x7c901010, EFLAGS=0x00010246
    Top of Stack: (sp=0x0007f8d8)
    0x0007f8d8: 74355a16 00000004 02ea15b4 7432139f
    0x0007f8e8: 02ea15b4 02ea1590 0007f900 74322c5d
    0x0007f8f8: 02ea15b4 000361b4 0007f914 74325fa0
    0x0007f908: 02ea1590 74350000 00390000 0007f930
    0x0007f918: 7432740e 02ea1590 0007f950 00000003
    0x0007f928: 00aabe20 000361b4 0007f948 6d3e11da
    0x0007f938: 02ea1590 0007f950 000360f8 26bb5250
    0x0007f948: 0007f980 00ad826f 00000000 0007f99c
    Instructions: (pc=0x7c901010)
    0x7c901000: 90 90 90 90 90 64 8b 0d 18 00 00 00 8b 54 24 04
    0x7c901010: 83 7a 14 00 75 4f f0 ff 42 04 75 19 8b 41 24 89
    Stack: [0x00040000,0x00080000), sp=0x0007f8d8, free space=254k
    Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
    C [ntdll.dll+0x1010]
    C [ODBC32.dll+0x2c5d]
    C [ODBC32.dll+0x5fa0]
    C [ODBC32.dll+0x740e]
    C [JdbcOdbc.dll+0x11da]
    j sun.jdbc.odbc.JdbcOdbc.allocStmt(J[B)J+0
    j sun.jdbc.odbc.JdbcOdbc.SQLAllocStmt(J)J+47
    j sun.jdbc.odbc.JdbcOdbcConnection.createStatement(II)Ljava/sql/Statement;+27
    j sun.jdbc.odbc.JdbcOdbcConnection.createStatement()Ljava/sql/Statement;+7
    j LUDatabaseWorker.getBoxScoreFromDB(LStatisticalItems/BoxScore;)LStatisticalItems/BoxScore;+215
    j NewUSCHOLiveUpdate.processTheBoxScores()V+78
    j NewUSCHOLiveUpdate.main([Ljava/lang/String;)V+9
    v ~StubRoutines::call_stub
    V [jvm.dll+0x82696]
    V [jvm.dll+0xd6fd9]
    V [jvm.dll+0x82567]
    V [jvm.dll+0x895e6]
    C [java.exe+0x14c0]
    C [java.exe+0x64cd]
    C [kernel32.dll+0x16d4f]
    Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
    j sun.jdbc.odbc.JdbcOdbc.allocStmt(J[B)J+0
    j sun.jdbc.odbc.JdbcOdbc.SQLAllocStmt(J)J+47
    j sun.jdbc.odbc.JdbcOdbcConnection.createStatement(II)Ljava/sql/Statement;+27
    j sun.jdbc.odbc.JdbcOdbcConnection.createStatement()Ljava/sql/Statement;+7
    j LUDatabaseWorker.getBoxScoreFromDB(LStatisticalItems/BoxScore;)LStatisticalItems/BoxScore;+215
    j NewUSCHOLiveUpdate.processTheBoxScores()V+78
    j NewUSCHOLiveUpdate.main([Ljava/lang/String;)V+9
    v ~StubRoutines::call_stub
    --------------- P R O C E S S ---------------
    Java Threads: ( => current thread )
    0x00a6e550 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=2240]
    0x00a6d258 JavaThread "CompilerThread0" daemon [_thread_blocked, id=736]
    0x00a6c440 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=2252]
    0x00a47808 JavaThread "Finalizer" daemon [_thread_blocked, id=3352]
    0x00a46328 JavaThread "Reference Handler" daemon [_thread_blocked, id=1560]
    =>0x000360f8 JavaThread "main" [_thread_in_native, id=1364]
    Other Threads:
    0x00a67a68 VMThread [id=2700]
    0x00a6f8c8 WatcherThread [id=2480]
    VM state:not at safepoint (normal execution)
    VM Mutex/Monitor currently owned by a thread: None
    Heap
    def new generation total 576K, used 404K [0x22b90000, 0x22c30000, 0x23070000)
    eden space 512K, 70% used [0x22b90000, 0x22bea738, 0x22c10000)
    from space 64K, 66% used [0x22c20000, 0x22c2a990, 0x22c30000)
    to space 64K, 0% used [0x22c10000, 0x22c10000, 0x22c20000)
    tenured generation total 1408K, used 846K [0x23070000, 0x231d0000, 0x26b90000)
    the space 1408K, 60% used [0x23070000, 0x231438e0, 0x23143a00, 0x231d0000)
    compacting perm gen total 8192K, used 507K [0x26b90000, 0x27390000, 0x2ab90000)
    the space 8192K, 6% used [0x26b90000, 0x26c0ed38, 0x26c0ee00, 0x27390000)
    ro space 8192K, 66% used [0x2ab90000, 0x2b0e9dc0, 0x2b0e9e00, 0x2b390000)
    rw space 12288K, 46% used [0x2b390000, 0x2b927e98, 0x2b928000, 0x2bf90000)
    Dynamic libraries:
    0x00400000 - 0x0040c000      C:\jdk1.5.0_04\bin\java.exe
    0x7c900000 - 0x7c9b0000      C:\WINDOWS\system32\ntdll.dll
    0x7c800000 - 0x7c8f4000      C:\WINDOWS\system32\kernel32.dll
    0x77dd0000 - 0x77e6b000      C:\WINDOWS\system32\ADVAPI32.dll
    0x77e70000 - 0x77f01000      C:\WINDOWS\system32\RPCRT4.dll
    0x77c10000 - 0x77c68000      C:\WINDOWS\system32\MSVCRT.dll
    0x6d6b0000 - 0x6d839000      C:\jdk1.5.0_04\jre\bin\client\jvm.dll
    0x77d40000 - 0x77dd0000      C:\WINDOWS\system32\USER32.dll
    0x77f10000 - 0x77f56000      C:\WINDOWS\system32\GDI32.dll
    0x76b40000 - 0x76b6d000      C:\WINDOWS\system32\WINMM.dll
    0x629c0000 - 0x629c9000      C:\WINDOWS\system32\LPK.DLL
    0x74d90000 - 0x74dfb000      C:\WINDOWS\system32\USP10.dll
    0x6d2f0000 - 0x6d2f8000      C:\jdk1.5.0_04\jre\bin\hpi.dll
    0x76bf0000 - 0x76bfb000      C:\WINDOWS\system32\PSAPI.DLL
    0x6d680000 - 0x6d68c000      C:\jdk1.5.0_04\jre\bin\verify.dll
    0x6d370000 - 0x6d38d000      C:\jdk1.5.0_04\jre\bin\java.dll
    0x6d6a0000 - 0x6d6af000      C:\jdk1.5.0_04\jre\bin\zip.dll
    0x6d3e0000 - 0x6d3ed000      C:\jdk1.5.0_04\jre\bin\JdbcOdbc.dll
    0x74320000 - 0x7435d000      C:\WINDOWS\system32\ODBC32.dll
    0x5d090000 - 0x5d127000      C:\WINDOWS\system32\COMCTL32.dll
    0x7c9c0000 - 0x7d1d5000      C:\WINDOWS\system32\SHELL32.dll
    0x77f60000 - 0x77fd6000      C:\WINDOWS\system32\SHLWAPI.dll
    0x763b0000 - 0x763f9000      C:\WINDOWS\system32\comdlg32.dll
    0x773d0000 - 0x774d2000      C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.2180_x-ww_a84f1ff9\comctl32.dll
    0x20000000 - 0x20017000      C:\WINDOWS\system32\odbcint.dll
    0x774e0000 - 0x7761d000      C:\WINDOWS\system32\ole32.dll
    0x77120000 - 0x771ac000      C:\WINDOWS\system32\OLEAUT32.dll
    0x77fe0000 - 0x77ff1000      C:\WINDOWS\system32\Secur32.dll
    0x76fd0000 - 0x7704f000      C:\WINDOWS\system32\CLBCATQ.DLL
    0x77050000 - 0x77115000      C:\WINDOWS\system32\COMRes.dll
    0x77c00000 - 0x77c08000      C:\WINDOWS\system32\VERSION.dll
    0x0f9a0000 - 0x0f9ab000      C:\WINDOWS\system32\VBAJET32.DLL
    0x5ad70000 - 0x5ada8000      C:\WINDOWS\system32\uxtheme.dll
    VM Arguments:
    java_command: NewUSCHOLiveUpdate
    Environment Variables:
    JAVA_HOME=C:\jdk1.5.0_04
    CLASSPATH=C:\jdk1.5.0_04\bin\NewLiveUpdate;C:\jdk1.5.0_04\bin\NewLiveUpdate\StatisticalItems;C:\jdk1.5.0_04\bin\NewLiveUpdate\Exceptions;C:\jdk1.5.0_04\bin\NewLiveUpdate\Helper;
    PATH=C:\jdk1.5.0_04\bin;C:\JavaTools\ant\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\system32\WBEM;;c:\program files\devstudio\sharedide\bin\ide;c:\program files\devstudio\sharedide\bin;c:\program files\devstudio\vc\bin
    USERNAME=Kevin Yetman
    OS=Windows_NT
    PROCESSOR_IDENTIFIER=x86 Family 15 Model 4 Stepping 3, GenuineIntel
    --------------- S Y S T E M ---------------
    OS: Windows XP Build 2600 Service Pack 2
    CPU:total 2 family 15, cmov, cx8, fxsr, mmx, sse, sse2, ht
    Memory: 4k page, physical 1047020k(627436k free), swap 2518436k(2161900k free)
    vm_info: Java HotSpot(TM) Client VM (1.5.0_04-b05) for windows-x86, built on Jun 3 2005 02:10:41 by "java_re" with MS VC++ 6.0
    The code that is causing the problem is in the class shown below. It is in the method getBoxScoreFromDB. When it attempts to run the first select statement, it causes the crash that I showed above.
    The connection is set up by the calling class. The calling class constructs a LUDatabaseWorker, sets the necessary parameters (dbURL, driver class, username and password), and calls the openDBConnection().
    // LUDatabaseWorker.java
    import StatisticalItems.*;
    import java.sql.*;
    import java.util.*;
    public class LUDatabaseWorker
       private StatisticalItems.BoxScore m_CurrentBoxScoreInDB;
       private Connection                m_Connection;
       private String                    m_dbURL;
       private String                    m_dbUsername;
       private String                    m_dbPassword;
       private String                    m_dbDriverClass;
       public LUDatabaseWorker()
       public StatisticalItems.BoxScore getCurrentBoxScoreInDB()
       {  return m_CurrentBoxScoreInDB;
       public void setDBURL(String dbURL)
       {  m_dbURL=new String(dbURL);
       public void setDBUsername(String dbUsername)
       {  m_dbUsername=new String(dbUsername);
       public void setDBPassword(String dbPassword)
       {  m_dbPassword=new String(dbPassword);
       public void setDBDriverClass(String dbDriverClass)
       {  m_dbDriverClass=new String(dbDriverClass);
       public void openDBConnection()
          throws SQLException, ClassNotFoundException
          Class.forName(m_dbDriverClass);
          m_Connection=DriverManager.getConnection(m_dbURL, m_dbUsername, m_dbPassword);
       public void closeDBConnection()
          throws SQLException
          m_Connection.close();
       public Hashtable<String, Integer> getUSCHOCodeToMyTeamIndexMap()
          throws SQLException
          Hashtable<String, Integer> ht=new Hashtable<String, Integer>();
          String sqlQuery="SELECT TeamIndex, TeamCode FROM TeamLiveUpdateUSCHO";
          Statement st=m_Connection.createStatement();
          ResultSet rs=st.executeQuery(sqlQuery);
          while(rs.next())
             String uschoCode=new String(rs.getString(2));
             Integer myTeamIndex=new Integer(rs.getInt(1));
             ht.put(uschoCode, myTeamIndex);
          rs.close();
          st.close();
          return ht;
       public StatisticalItems.BoxScore getBoxScoreFromDB(StatisticalItems.BoxScore luBoxScore)
          throws SQLException
          StatisticalItems.BoxScore  boxScoreFromDB=new StatisticalItems.BoxScore();
          // get the basic game info from the live update box score.
          StatisticalItems.Game    luBasicGameData=luBoxScore.getBasicGameData();
          // get the basic game data.
          String sqlQuery="SELECT * FROM Game WHERE (Year=" + luBasicGameData.getYear() + ") AND (Month='";
          if( luBasicGameData.getMonth() < 10 )
          {  sqlQuery+="0";
          sqlQuery+=luBasicGameData.getMonth() + "') AND (Day='";
          if( luBasicGameData.getDay() < 10 )
          {  sqlQuery+="0";
          sqlQuery+=luBasicGameData.getDay() + "') AND (HomeTeamIndex=" + luBasicGameData.getHomeTeamIndex();
          sqlQuery+=") AND (VisitorTeamIndex=" + luBasicGameData.getVisitorTeamIndex() + ")";
          System.out.println(sqlQuery);
          Statement st=m_Connection.createStatement();
          ResultSet rs=st.executeQuery(sqlQuery);
          if( rs.next() )
             StatisticalItems.Game  dbGame=boxScoreFromDB.getBasicGameData();
             dbGame.setGameIndex(rs.getInt("GameIndex"));
             dbGame.setHomeTeamIndex(rs.getInt("HomeTeamIndex"));
             dbGame.setVisitorTeamIndex(rs.getInt("VisitorTeamIndex"));
             dbGame.setHomeTeamGoals(rs.getInt("HomeTeamGoals"));
             dbGame.setVisitorTeamGoals(rs.getInt("VisitorTeamGoals"));
             dbGame.setHomeTeamScoredFirst(rs.getString("HomeTeamScoredFirst"));
             dbGame.setYear(rs.getInt("Year"));
             dbGame.setMonth(rs.getInt("Month"));
             dbGame.setDay(rs.getInt("Day"));
             dbGame.setLeagueGame(rs.getBoolean("LeagueGame"));
             dbGame.setNeutralSiteGame(rs.getBoolean("NeutralSiteGame"));
             dbGame.setForfeitHome(rs.getBoolean("ForfeitHome"));
             dbGame.setForfeitVisitor(rs.getBoolean("ForfeitVisitor"));
             dbGame.setPlayoffGame(rs.getBoolean("PlayoffGame"));
             boxScoreFromDB.setBasicGameData(dbGame);
          StatisticalItems.Game  dbGame=boxScoreFromDB.getBasicGameData();
          // get the home team goals per period.
          sqlQuery="SELECT * FROM GameDetailGoalsPerPeriod WHERE (GameIndex=" + dbGame.getGameIndex() + ") AND ";
          sqlQuery+="(TeamIndex=" + dbGame.getHomeTeamIndex() + ")";
          rs=st.executeQuery(sqlQuery);
          if( rs.next() )
             StatisticalItems.GameDetailGoalsPerPeriod dbHomeGPP=boxScoreFromDB.getHomeTeamGoalsPerPeriod();
             dbHomeGPP.setGameDetailGoalsPerPeriodIndex(rs.getInt("GameDetailGoalsPerPeriodIndex"));
             dbHomeGPP.setGameIndex(rs.getInt("GameIndex"));
             dbHomeGPP.setTeamIndex(rs.getInt("TeamIndex"));
             dbHomeGPP.setPeriod1(new Integer(rs.getInt("GoalsFirstPeriod")));
             dbHomeGPP.setPeriod2(new Integer(rs.getInt("GoalsSecondPeriod")));
             dbHomeGPP.setPeriod3(new Integer(rs.getInt("GoalsThidPeriod")));
             dbHomeGPP.setOvertime(new Integer(rs.getInt("GoalsOvertime")));
             dbHomeGPP.setEmptyNetGoals(rs.getInt("EmptyNetGoals"));
             dbHomeGPP.setFoundInDatabase(true);
             boxScoreFromDB.setHomeTeamGoalsPerPeriod(dbHomeGPP);
          // get the visitor team goals per period. 
          sqlQuery="SELECT * FROM GameDetailGoalsPerPeriod WHERE (GameIndex=" + dbGame.getGameIndex() + ") AND ";
          sqlQuery+="(TeamIndex=" + dbGame.getVisitorTeamIndex() + ")";
          rs=st.executeQuery(sqlQuery);
          if( rs.next() )
             StatisticalItems.GameDetailGoalsPerPeriod dbVisitorGPP=boxScoreFromDB.getVisitorTeamGoalsPerPeriod();
             dbVisitorGPP.setGameDetailGoalsPerPeriodIndex(rs.getInt("GameDetailGoalsPerPeriodIndex"));
             dbVisitorGPP.setGameIndex(rs.getInt("GameIndex"));
             dbVisitorGPP.setTeamIndex(rs.getInt("TeamIndex"));
             dbVisitorGPP.setPeriod1(new Integer(rs.getInt("GoalsFirstPeriod")));
             dbVisitorGPP.setPeriod2(new Integer(rs.getInt("GoalsSecondPeriod")));
             dbVisitorGPP.setPeriod3(new Integer(rs.getInt("GoalsThidPeriod")));
             dbVisitorGPP.setOvertime(new Integer(rs.getInt("GoalsOvertime")));
             dbVisitorGPP.setEmptyNetGoals(rs.getInt("EmptyNetGoals"));
             dbVisitorGPP.setFoundInDatabase(true);
             boxScoreFromDB.setVisitorTeamGoalsPerPeriod(dbVisitorGPP);
          // get the home team shots per period.
          sqlQuery="SELECT * FROM GameDetailShotsPerPeriod WHERE (GameIndex=" + dbGame.getGameIndex() + ") AND ";
          sqlQuery+="(TeamIndex=" + dbGame.getHomeTeamIndex() + ")";
          rs=st.executeQuery(sqlQuery);
          if( rs.next() )
             StatisticalItems.GameDetailShotsPerPeriod dbHomeSPP=boxScoreFromDB.getHomeTeamShotsPerPeriod();
             dbHomeSPP.setGameDetailShotsPerPeriodIndex(rs.getInt("GameDetailShotsPerPeriodIndex"));
             dbHomeSPP.setGameIndex(rs.getInt("GameIndex"));
             dbHomeSPP.setTeamIndex(rs.getInt("TeamIndex"));
             dbHomeSPP.setPeriod1(new Integer(rs.getInt("ShotsFirstPeriod")));
             dbHomeSPP.setPeriod2(new Integer(rs.getInt("ShotsSecondPeriod")));
             dbHomeSPP.setPeriod3(new Integer(rs.getInt("ShotsThidPeriod")));
             dbHomeSPP.setOvertime(new Integer(rs.getInt("ShotsOvertime")));
             dbHomeSPP.setFoundInDatabase(true);
             boxScoreFromDB.setHomeTeamShotsPerPeriod(dbHomeSPP);
          // get the visitor team shots per period. 
          sqlQuery="SELECT * FROM GameDetailShotsPerPeriod WHERE (GameIndex=" + dbGame.getGameIndex() + ") AND ";
          sqlQuery+="(TeamIndex=" + dbGame.getVisitorTeamIndex() + ")";
          rs=st.executeQuery(sqlQuery);
          if( rs.next() )
             StatisticalItems.GameDetailShotsPerPeriod dbVisitorSPP=boxScoreFromDB.getVisitorTeamShotsPerPeriod();
             dbVisitorSPP.setGameDetailShotsPerPeriodIndex(rs.getInt("GameDetailShotsPerPeriodIndex"));
             dbVisitorSPP.setGameIndex(rs.getInt("GameIndex"));
             dbVisitorSPP.setTeamIndex(rs.getInt("TeamIndex"));
             dbVisitorSPP.setPeriod1(new Integer(rs.getInt("ShotsFirstPeriod")));
             dbVisitorSPP.setPeriod2(new Integer(rs.getInt("ShotsSecondPeriod")));
             dbVisitorSPP.setPeriod3(new Integer(rs.getInt("ShotsThidPeriod")));
             dbVisitorSPP.setOvertime(new Integer(rs.getInt("ShotsOvertime")));
             dbVisitorSPP.setFoundInDatabase(true);
             boxScoreFromDB.setVisitorTeamShotsPerPeriod(dbVisitorSPP);
          // get the home team special teams.
          sqlQuery="SELECT * FROM GameDetailSpecialTeams WHERE (GameIndex=" + dbGame.getGameIndex() + ") AND ";
          sqlQuery+="(TeamIndex=" + dbGame.getHomeTeamIndex() + ")";
          rs=st.executeQuery(sqlQuery);
          if( rs.next() )
             StatisticalItems.GameDetailSpecialTeams dbHomeST=boxScoreFromDB.getHomeTeamSpecialTeams();
             dbHomeST.setGameDetailSpecialTeamsIndex(rs.getInt("GameDetailSpecialTeamsIndex"));
             dbHomeST.setGameIndex(rs.getInt("GameIndex"));
             dbHomeST.setTeamIndex(rs.getInt("TeamIndex"));
             dbHomeST.setPowerplayGoals(rs.getInt("PowerPlayGoals"));
             dbHomeST.setShorthandedGoals(rs.getInt("ShortHandedGoals"));
             dbHomeST.setPowerplayOps(rs.getInt("PowerPlayOps"));
             dbHomeST.setShorthandedOps(rs.getInt("ShortHandedOps"));
             dbHomeST.setPenalties(rs.getInt("Penalties"));
             dbHomeST.setPenaltyMinutes(rs.getInt("PenaltyMinutes"));
             dbHomeST.setFoundInDatabase(true);
             boxScoreFromDB.setHomeTeamSpecialTeams(dbHomeST);
          // get the home team special teams.
          sqlQuery="SELECT * FROM GameDetailSpecialTeams WHERE (GameIndex=" + dbGame.getGameIndex() + ") AND ";
          sqlQuery+="(TeamIndex=" + dbGame.getVisitorTeamIndex() + ")";
          rs=st.executeQuery(sqlQuery);
          if( rs.next() )
             StatisticalItems.GameDetailSpecialTeams dbVisitorST=boxScoreFromDB.getVisitorTeamSpecialTeams();
             dbVisitorST.setGameDetailSpecialTeamsIndex(rs.getInt("GameDetailSpecialTeamsIndex"));
             dbVisitorST.setGameIndex(rs.getInt("GameIndex"));
             dbVisitorST.setTeamIndex(rs.getInt("TeamIndex"));
             dbVisitorST.setPowerplayGoals(rs.getInt("PowerPlayGoals"));
             dbVisitorST.setShorthandedGoals(rs.getInt("ShortHandedGoals"));
             dbVisitorST.setPowerplayOps(rs.getInt("PowerPlayOps"));
             dbVisitorST.setShorthandedOps(rs.getInt("ShortHandedOps"));
             dbVisitorST.setPenalties(rs.getInt("Penalties"));
             dbVisitorST.setPenaltyMinutes(rs.getInt("PenaltyMinutes"));
             dbVisitorST.setFoundInDatabase(true);
             boxScoreFromDB.setVisitorTeamSpecialTeams(dbVisitorST);
          rs.close();
          st.close();
          return boxScoreFromDB;    
       public void updateBoxScoreInDB(StatisticalItems.BoxScore  dbBoxScore,
                                      StatisticalItems.BoxScore  luBoxScore,
                                      LUBoxScoreComparator       bsc)
          throws SQLException
          if( bsc.getGameChanged() )
             updateGameInDB(dbBoxScore, luBoxScore);
          if( bsc.getHomeGoalsPerPeriodChanged() )
             updateHomeGoalsPerPeriod(dbBoxScore, luBoxScore);
          if( bsc.getVisitorGoalsPerPeriodChanged() )
             updateVisitorGoalsPerPeriod(dbBoxScore, luBoxScore);
          if( bsc.getHomeShotsPerPeriodChanged() )
             updateHomeShotsPerPeriod(dbBoxScore, luBoxScore);
          if( bsc.getVisitorShotsPerPeriodChanged() )
             updateVisitorShotsPerPeriod(dbBoxScore, luBoxScore);
          if( bsc.getHomeSpecialTeamsChanged() )
             updateHomeSpecialTeams(dbBoxScore, luBoxScore);
          if( bsc.getVisitorSpecialTeamsChanged() )
             updateVisitorSpecialTeams(dbBoxScore, luBoxScore);
       protected void updateGameInDB(StatisticalItems.BoxScore dbBoxScore,
                                     StatisticalItems.BoxScore luBoxScore)
          throws SQLException
          // the only fields that NEED to be updated are HomeTeamGoals, VisitorTeamGoals, HomeTeamScoredFirst,
          // and LeagueGame.  You can't determine from the LU box Score:
          // Forfeits, NeutralSite, or Playoff.
          // the GameIndex, Both team indexes, and the game date will NEVER change from the database.
          Statement st=m_Connection.createStatement();
          String sqlStmt="UPDATE Game SET ";
          sqlStmt+="HomeTeamGoals=" + luBoxScore.getBasicGameData().getHomeTeamGoals() + ", ";
          sqlStmt+="VisitorTeamGoals=" + luBoxScore.getBasicGameData().getVisitorTeamGoals() + ", ";
          sqlStmt+="HomeTeamScoredFirst='" + luBoxScore.getBasicGameData().getHomeTeamScoredFirst() + "', ";
          sqlStmt+="LeagueGame=" + luBoxScore.getBasicGameData().getLeagueGame() + " ";
          sqlStmt+="WHERE GameIndex=" + dbBoxScore.getBasicGameData().getGameIndex();
          st.executeUpdate(sqlStmt);
          st.close();
       protected void updateHomeGoalsPerPeriod(StatisticalItems.BoxScore dbBoxScore,
                                               StatisticalItems.BoxScore luBoxScore)
          throws SQLException
          Statement st=m_Connection.createStatement();
          String sqlStmt="";
          if( dbBoxScore.getHomeTeamGoalsPerPeriod().getFoundInDatabase() )
             sqlStmt="UPDATE GameDetailGoalsPerPeriod SET ";
             sqlStmt+="GameIndex=" + dbBoxScore.getHomeTeamGoalsPerPeriod().getGameIndex() + ", ";
             sqlStmt+="TeamIndex=" + luBoxScore.getHomeTeamGoalsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+="GoalsFirstPeriod=" + luBoxScore.getHomeTeamGoalsPerPeriod().getPeriod1() + ", ";
             sqlStmt+="GoalsSecondPeriod=" + luBoxScore.getHomeTeamGoalsPerPeriod().getPeriod2() + ", ";
             sqlStmt+="GoalsThirdPeriod=" + luBoxScore.getHomeTeamGoalsPerPeriod().getPeriod3() + ", ";
             sqlStmt+="GoalsOvertime=" + luBoxScore.getHomeTeamGoalsPerPeriod().getOvertime() + ", ";
             sqlStmt+="EmptyNetGoals=" + luBoxScore.getHomeTeamGoalsPerPeriod().getEmptyNetGoals() + " ";
             sqlStmt+="WHERE GameIndex=" + dbBoxScore.getHomeTeamGoalsPerPeriod().getGameIndex() + " AND ";
             sqlStmt+="TeamIndex=" + luBoxScore.getHomeTeamGoalsPerPeriod().getTeamIndex();
          else
             sqlStmt="INSERT INTO GameDetailGoalsPerPeriod ";
             sqlStmt+="(GameIndex, TeamIndex, GoalsFirstPeriod, GoalsSecondPeriod, GoalsThirdPeriod, ";
             sqlStmt+="GoalsOvertime, EmptyNetGoals) VALUES(";
             sqlStmt+=dbBoxScore.getBasicGameData().getGameIndex() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamGoalsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamGoalsPerPeriod().getPeriod1() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamGoalsPerPeriod().getPeriod2() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamGoalsPerPeriod().getPeriod3() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamGoalsPerPeriod().getOvertime() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamGoalsPerPeriod().getEmptyNetGoals() + ")";
          st.executeUpdate(sqlStmt);
          st.close();
       protected void updateVisitorGoalsPerPeriod(StatisticalItems.BoxScore dbBoxScore,
                                                  StatisticalItems.BoxScore luBoxScore)
          throws SQLException
          Statement st=m_Connection.createStatement();
          String sqlStmt="";
          if( dbBoxScore.getVisitorTeamGoalsPerPeriod().getFoundInDatabase() )
             sqlStmt="UPDATE GameDetailGoalsPerPeriod SET ";
             sqlStmt+="GameIndex=" + dbBoxScore.getVisitorTeamGoalsPerPeriod().getGameIndex() + ", ";
             sqlStmt+="TeamIndex=" + luBoxScore.getVisitorTeamGoalsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+="GoalsFirstPeriod=" + luBoxScore.getVisitorTeamGoalsPerPeriod().getPeriod1() + ", ";
             sqlStmt+="GoalsSecondPeriod=" + luBoxScore.getVisitorTeamGoalsPerPeriod().getPeriod2() + ", ";
             sqlStmt+="GoalsThirdPeriod=" + luBoxScore.getVisitorTeamGoalsPerPeriod().getPeriod3() + ", ";
             sqlStmt+="GoalsOvertime=" + luBoxScore.getVisitorTeamGoalsPerPeriod().getOvertime() + ", ";
             sqlStmt+="EmptyNetGoals=" + luBoxScore.getVisitorTeamGoalsPerPeriod().getEmptyNetGoals() + " ";
             sqlStmt+="WHERE GameIndex=" + dbBoxScore.getVisitorTeamGoalsPerPeriod().getGameIndex() + " AND ";
             sqlStmt+="TeamIndex=" + luBoxScore.getVisitorTeamGoalsPerPeriod().getTeamIndex();
          else
             sqlStmt="INSERT INTO GameDetailGoalsPerPeriod ";
             sqlStmt+="(GameIndex, TeamIndex, GoalsFirstPeriod, GoalsSecondPeriod, GoalsThirdPeriod, ";
             sqlStmt+="GoalsOvertime, EmptyNetGoals) VALUES(";
             sqlStmt+=dbBoxScore.getBasicGameData().getGameIndex() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamGoalsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamGoalsPerPeriod().getPeriod1() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamGoalsPerPeriod().getPeriod2() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamGoalsPerPeriod().getPeriod3() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamGoalsPerPeriod().getOvertime() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamGoalsPerPeriod().getEmptyNetGoals() + ")";
          st.executeUpdate(sqlStmt);
          st.close();
       protected void updateHomeShotsPerPeriod(StatisticalItems.BoxScore dbBoxScore,
                                               StatisticalItems.BoxScore luBoxScore)
          throws SQLException
          Statement st=m_Connection.createStatement();
          String sqlStmt="";
          if( dbBoxScore.getHomeTeamShotsPerPeriod().getFoundInDatabase() )
             sqlStmt="UPDATE GameDetailShotsPerPeriod SET ";
             sqlStmt+="GameIndex=" + dbBoxScore.getHomeTeamShotsPerPeriod().getGameIndex() + ", ";
             sqlStmt+="TeamIndex=" + luBoxScore.getHomeTeamShotsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+="ShotsFirstPeriod=" + luBoxScore.getHomeTeamShotsPerPeriod().getPeriod1() + ", ";
             sqlStmt+="ShotsSecondPeriod=" + luBoxScore.getHomeTeamShotsPerPeriod().getPeriod2() + ", ";
             sqlStmt+="ShotsThirdPeriod=" + luBoxScore.getHomeTeamShotsPerPeriod().getPeriod3() + ", ";
             sqlStmt+="ShotsOvertime=" + luBoxScore.getHomeTeamShotsPerPeriod().getOvertime() + " ";
             sqlStmt+="WHERE GameIndex=" + dbBoxScore.getHomeTeamShotsPerPeriod().getGameIndex() + " AND ";
             sqlStmt+="TeamIndex=" + luBoxScore.getHomeTeamShotsPerPeriod().getTeamIndex();
          else
             sqlStmt="INSERT INTO GameDetailShotsPerPeriod ";
             sqlStmt+="(GameIndex, TeamIndex, ShotsFirstPeriod, ShotsSecondPeriod, ShotsThirdPeriod, ";
             sqlStmt+="ShotsOvertime) VALUES(";
             sqlStmt+=dbBoxScore.getBasicGameData().getGameIndex() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamShotsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamShotsPerPeriod().getPeriod1() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamShotsPerPeriod().getPeriod2() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamShotsPerPeriod().getPeriod3() + ", ";
             sqlStmt+=luBoxScore.getHomeTeamShotsPerPeriod().getOvertime() + ")";
          st.executeUpdate(sqlStmt);
          st.close();
       protected void updateVisitorShotsPerPeriod(StatisticalItems.BoxScore dbBoxScore,
                                                  StatisticalItems.BoxScore luBoxScore)
          throws SQLException
          Statement st=m_Connection.createStatement();
          String sqlStmt="";
          if( dbBoxScore.getVisitorTeamShotsPerPeriod().getFoundInDatabase() )
             sqlStmt="UPDATE GameDetailShotsPerPeriod SET ";
             sqlStmt+="GameIndex=" + dbBoxScore.getVisitorTeamShotsPerPeriod().getGameIndex() + ", ";
             sqlStmt+="TeamIndex=" + luBoxScore.getVisitorTeamShotsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+="ShotsFirstPeriod=" + luBoxScore.getVisitorTeamShotsPerPeriod().getPeriod1() + ", ";
             sqlStmt+="ShotsSecondPeriod=" + luBoxScore.getVisitorTeamShotsPerPeriod().getPeriod2() + ", ";
             sqlStmt+="ShotsThirdPeriod=" + luBoxScore.getVisitorTeamShotsPerPeriod().getPeriod3() + ", ";
             sqlStmt+="ShotsOvertime=" + luBoxScore.getVisitorTeamShotsPerPeriod().getOvertime() + " ";
             sqlStmt+="WHERE GameIndex=" + dbBoxScore.getVisitorTeamShotsPerPeriod().getGameIndex() + " AND ";
             sqlStmt+="TeamIndex=" + luBoxScore.getVisitorTeamShotsPerPeriod().getTeamIndex();
          else
             sqlStmt="INSERT INTO GameDetailShotsPerPeriod ";
             sqlStmt+="(GameIndex, TeamIndex, ShotsFirstPeriod, ShotsSecondPeriod, ShotsThirdPeriod, ";
             sqlStmt+="ShotsOvertime) VALUES(";
             sqlStmt+=dbBoxScore.getBasicGameData().getGameIndex() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamShotsPerPeriod().getTeamIndex() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamShotsPerPeriod().getPeriod1() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamShotsPerPeriod().getPeriod2() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamShotsPerPeriod().getPeriod3() + ", ";
             sqlStmt+=luBoxScore.getVisitorTeamShotsPerPeriod().getOvertime() + ")";
          st.executeUpdate(sqlStmt);
          st.close();
       protected void updateHomeSpecialTeams(StatisticalItems.BoxScore dbBoxScore,
                                             StatisticalItems.BoxScore luBoxScore)
          throws SQLException
          Statement st=m_Connection.createStatement();
          String sqlStmt="";
          if( dbBoxScore.getHomeTeamSpecialTeams().getFoundInDatabase() )
             sqlStmt="UPDATE GameDetailSpecialTeams SET ";
             sqlStmt+="GameIndex=" + dbBoxScore.getHomeTeamSpecialTeams().getGameIndex() + ", ";
             sqlStmt+="TeamIndex=" + luBoxScore.getHomeTeamSpecialTeams().getTeamIndex() + ", ";
             sqlStmt+="PowerplayGoals=" + luBoxScore.getHomeTeamSpecialTeams().getPowerplayGoals() + ", ";
             sqlStmt+="PowerplayOps=" + luBoxScore.getHomeTeamSpecialTeams().getPowerplayOps() + ", ";
             sqlStmt+="ShorthandedGoals=" + luBoxScore.getHomeTeamSpecialTeams().getShorthandedGoals() + ", ";
             sqlStmt+="ShorthandedOps=" + luBoxScore.getHomeTeamSpecialTeams().getShorthande                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    its because you use hungarian notation - that was the hollywood squares answer.
    It looks like a bug in either the ntdll or the JdbcOdbc dll, so I'd see if you can't isolate the problem (like using a smaller bit of code) and file a bug report. Find out exacty what your sql statement is which causes this to crash - hint : line 215

  • Oracle RDB Driver fails with JDBC/ODBC Bridge

    Has anyone experienced problems using the latest Oracle RDB
    Driver (3.0.2.0) with the JDBC/ODBC Bridge.
    We have been using the Oracle ODBC Driver for RDB (2.10.17)
    successfully on NT, but it is not supported on W2K. The new
    drivers work fine for Access etc., but fail with the bridge.
    Specifically, you can step thru a result set, but getObject()
    returns null for all fields.
    Any suggestions?
    Joe

    This forum is for general suggestions and feedback about the OTN
    site. For technical question about an Oracle product, you can
    select the appropriate discussion forum in our 'Discussions'
    section at: http://forums.oracle.com/forums/homepage.jsp
    Best regards, OTN Team

  • Problem using Jdbc-Odbc Bridge

    Hi,
    I am using Java 2 SDK and I am trying to access MS Access database on my machine using Jdbc-Odbc bridge. I have set up the DSN in ODBC. But I get the following error when I run my program -
    'No Suitable Driver'
    Here's my code snippet-
    Class.forName ("sun.jdbc.odbc.JdbcOdbcDriver");
    String dsn = "jdbc:odbc:DriverInfoDB";
    Connection con = DriverManager.getConnection(dsn,"","");
    con.setAutoCommit(false);
    Statement stmt;
    String query = null; // SQL select string
    ResultSet rs; // SQL query results
    stmt = con.createStatement();
    .....etc etc...
    Where is the error in this code??
    Help Needed!!
    Thanks
    Vivek.

    try
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    Connection con = DriverManager.getConnection(dsn,"guest","guest");
    OR DriverManager.getConnection(dsn);
    System.out.println("Conection's opened");
    catch(ClassNotFoundException cnfe)
    System.err.println(cnfe);
    catch(SQLException sqle)
    System.err.println(sqle);
    try that code and double check you DSN Name . it's a good practice to greate a system DSN.
    i hope that helps.
    FEEL FREE TO ASK. WON'T BITE U
    ABDUL

  • How to create db conn for JDBC-ODBC Bridge for MS Access in ADF APP?

    Sir,
    How to create db conn for JDBC-ODBC Bridge for MS Access in ADF APP?
    Regards

    Hello Every Body!
    I succeeded in getting connect to the ms access database in adf application in jdeveloper as below:
    First in control panel to to admin tools and  go to data source(odbc) and create system dsn as bellow pic
    Then go to jdeveloper resources ide conn and then database and new database conn and then select jdbc-odbc briddge and then give custom jdbc url as bellow pic
    Cheers
    tanvir

  • Access MS-Access using JDBC ODBC bridge from Sun AMD64

    Hi,
    We are trying to configure a communication channel using the JDBC adapter. We are setting the driver to the JDBC-ODBC bridge driver and trying to access an MS Acess database from the PI server(sun amd64). When we set the driver to the JDBC-ODBC bridge, the J2EE engine tries to restart immediately and does not start. The std_server.out contains the following error:
    Service com.sap.aii.adapter.jdbc.svc started. (234 ms).
    1016 sun.io.CharToByteASCII::convert (370 bytes)
    1017 ! com.sap.sql.jdbc.common.CommonPreparedStatement::close (119
    bytes)
    ld.so.1: jlaunch: fatal: relocation error:
    file /usr/j2se/jre/lib/amd64/libJdbcO
    dbc.so: symbol SQLAllocEnv: referenced symbol not found
    Has anybody been able to configure the JDBC-ODBC bridge driver for MS Access? Also, has anybody used the database vendor(MS) drivers? If so, where are they available.
    Thanks in advance
    Vipin

    Hi
    Please go through below links that would be helpful to you
    SAP Network Blog: Connecting to MS Access using receiver JDBC Adapter (Without DSN)
    /people/sameer.shadab/blog/2005/10/24/connecting-to-ms-access-using-receiver-jdbc-adapter-without-dsn
    /people/sap.user72/blog/2005/06/01/file-to-jdbc-adapter-using-sap-xi-30
    If required Try the following driver. I havent used it but its available.
    HXTT Access is such a type 4 driver at http://www.hxtt.net/en/software/access/document.html .
    Thanks
    Swarup

  • SQL Developer 2.1.1 : JDBC/ODBC Bridge

    Hi, I am running SQL Developer 2.1.1 and would like to to access databases other than those formally supported.
    I am happy to use the JDBC/ODBC Bridge - although additional JDBC connectivity would be ideal, I gather that it is not supported.
    Googling, and searching on this forum, implies that I should install the appropriate JDBC driver for the Bridge, list it on the third party JDBC drivers Preferences page, and that a 'Create Connection' dialog JDBC tab would then appear on restarting SQL Developer, as happens when you install the supported MySQL JDBC driver, for example.
    I am sorry to be dim, but I cannot track down a jar file containing the JDBC/ODBC Bridge that is supported by SQL Developer to the extent of enabling the JDBC tab. The rt.jar shipped in SQL Developer's JRE does not do the job. Checking for updates from the Help menu lists nothing that looks even remotely relevant. Where should I be looking?
    Thanks a lot
    Mandy Shaw
    Edited by: 845622 on Mar 18, 2011 10:59 AM - Clarified - sorry

    The additional connection types only appear for supported databases.
    I haven't tried this, but I vaguely remember some discussions from a long time ago.
    Make sure the jar file (and any supporting DLLs) are on your classpath (probably dropping them in the extensions directory will do it) and then in the new connection dialog select 'Advanced' connection type. This lets you enter a JDBC URL in any format so you can enter what is required for your additional databases.
    If this works, the most it will get you is a SQL Worksheet with no completion insight or syntax checking. Because SQL Developer doesn't know how to use the database catalogue, the object navigator won't work.

  • MS SQL Server 7 thru JDBC:ODBC bridge

    Hi,
    I am trying to access MS SQL server 7 thru JDBC ODBC bridge. I am finding my varchar data is being truncated to 255 characters. Any help on this would be appreciated.

    Any body know of a good type 4 jdbc driver for SQL
    Server 7. There is one for SQL server 2000
    downloadable from micrsoft site, but does it work for
    sql server 7 too ?Older betas of this driver suported SQL Server 7, but I believe the plan is to specifically remove that capability in its final release.
    My biased opinion would be to try the driver from DataDirect. http://www.ddtek.com Its their driver (an older version) that Microsoft has licensed for MS SQl 2000.
    Getting it from DataDirect has a couple obvious advantages:
    1. Its a later, more stable, better performing version
    2. It will continue to Support MS SQL 7
    3. It's suported by 24/7 phone,email and web tech support.
    4. And, early this week, you should be able to get the latest 3.0 release which promises to be even more robust, in addition to conforming to the new specs.
    5. its not free, but then again- you get what you pay for...

  • JDBC-ODBC Bridge with iAS on UNIX

    Can the Sun JDBC-ODBC bridge be used with iAS on UNIX (Solaris)? If possible, can someone share the basic steps. For example, what parameters to enter when configuring the bridge as a datasource and also how to pass needed environment variables (LD_LIBRARY_PATH has to have the path of the ODBC driver manager).
    I need to connect to a ODBC driver on UNIX, no JDBC driver is available for this data source, nor is a Windows solution acceptable.
    I have iAS 6.0 SP3 with iWS 4.1 SP9 on Solaris 8.

    Hi,
    I'm not sure if there is a free download available, but you can find some help by visiting the following URL http://www.dbmaker.com/Header/Frame_Forum.htm
    For the exact steps, I think this would be more helpful http://www.dbmaker.com/reference/technotes/jdbc.html
    Please let me know if this helps.
    Regards
    Raj

Maybe you are looking for