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 .

Similar Messages

  • Cannot access remote FoxPro dbf file using jdbc-odbc and system DSN

    Hi all,
    I have a foxpro database sitting on remote server (netware server). the dbf folder is shared and I can access it using windows explore on my weblogic server (windows 2003). I created a system dsn for that. I can access the database from the a stand alone java program using
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    Connection surgConn = DriverManager.getConnection("jdbc:odbc:FoxDB", " ", " ");
    But when I use the same thing in my weblogic 8.1 application, I cannot access the database. I didn't config any data source in weblogic 8.1
    Why?
    When I try this on my own computer - windows 2000, weblogic 8.1 workshop. remote foxpro database dbf folder. it works.
    Any idea?
    Thanks very much

    Laura Ren wrote:
    Hi all,
    I have a foxpro database sitting on remote server (netware server). the dbf folder is shared and I can access it using windows explore on my weblogic server (windows 2003). I created a system dsn for that. I can access the database from the a stand alone java program using
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    Connection surgConn = DriverManager.getConnection("jdbc:odbc:FoxDB", " ", " ");
    But when I use the same thing in my weblogic 8.1 application, I cannot access the database.What exception do you get? WebLogic is just like any other Java App. That code
    should work OK (though I have a better way)... Be warned that the JDBC ODBC
    bridge is specifically dangerous. It is not threadsafe.
    Joe
    I didn't config any data source in weblogic 8.1
    Why?
    When I try this on my own computer - windows 2000, weblogic 8.1 workshop. remote foxpro database dbf folder. it works.
    Any idea?
    Thanks very much

  • 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

  • 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

  • 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

  • What's the URL in a JDBC-ODBC bridge driver connection?

    I'm trying to use a JDBC-ODBC bridge driver but I don't know what is the URL I need to put inside a the "getConnection (String URL, String userid, String passwd)" method.
    Connection conn = DriverManager.getConnection(URL, user, passwd);
    Can anybody help me?

    Yes Marc,
    but maybe Edgar should know that he first has to add a ODBC datasource.
    in WINNT
    Goto System ODBC Datasources and try to connect to your DB.
    If the test is working than you can use the name you have chosen
    as URL
    good luck
    Stefan

  • JDBC ODBC Bridge/Driver???

    Hi,
    Please can someone help me?
    I'm a 4th year computer science student and have a final year project to do using databases. My problem is finding a JDBC:ODBC driver/bridge(what's the difference?).Every tutorial on the web says use the
    sun.jdbc.odbc.JdbcOdbcDriver, that's all well and good but where do I get it?I've tried downloading JDBC API's but still no joy. When I do finally find a driver do I need to copy it to the folder where the rest of my project is,
    (that's what I had to do for a mysql driver I had to use before). I want to use Microsoft Access with the project for portability and ease of alteration, do I need to set up an ODBC driver for my database as well as using the JDBC:ODBC bridge?
    That probably came out like complete double dutch but I hope someone out there can make sense of it and help me.

    Please can someone help me?Start with a tutorial http://java.sun.com/docs/books/tutorial/jdbc/index.html
    Basic info on your particular problem:
    JDBC defines an 'interface' that allows one to access databases. That usually consists of serveral parts: the database, the interface layer, the jdbc driver and jdbc itself.
    JDBC comes with java. In addition a single jdbc driver, the 'jdbc-odbc bridge' driver comes with java. To use that particular driver you also need the 'interface layer' which for MS Acess will mostly already be available to you - basically the ODBC shell (not part of java) and the MS Access ODBC driver (also not part of java.)
    Keep in mind that the jdbc-odbc bridge driver uses the ODBC that is already on the box. ODBC itself is not part of the driver.
    You will probably need to configure ODBC for use as a 'DSN' (Data Source Name?). To do that you go to the control panel and use the ODBC (Data Sources) applet. Pick 'System DSN' (a panel in the dialog), push 'Add' and follow the prompts by picking a MS Access driver. You can either use 'create' or 'select' at the end to create or use an existing database.
    If this seems like too much work then search the JDBC forum using "DSN-less" as the search string. The discussions there will tell you how to set up a connect string without creating a DSN.
    If you have further questions on this particular subject it would be best to post them to the JDBC forum rather than here.

  • Com.mysql.jdbc.driver and jdbc:odbc bridge driver

    Hi All,
    I want to update mysql database from data in hashtable. My application already uses JDBC:OBDC bridge driver for retrieving data from excel sheet and putting in hashtable.
    For connecting to mysql i need to use com.mysql.jdbc.driver too in the same code.
    How to do that?
    my code uses.
    Read(String strFilePath,String strFileName)
               filepath = strFilePath;
               filename = strFileName;
                strDriver= "jdbc:odbc:Driver={MicroSoft Excel Driver (*.xls)}";Thanks

    Please stay with one thread:
    http://forum.java.sun.com/thread.jspa?threadID=5145466&tstart=0
    Please don't cross-post this way.

  • Can't find jdbc-odbc bridge driver

    Hi
    I've installed sdk 2.0 (v1.4.1) and am getting the runtime error:
    "Exception in thread main java.lang.NoClassDefFoundError <prog name>/class" from the java prompt.
    I suspect it is the jdbc-odbc bridge driver that is the problem. It should have downloaded with the SD 2.0 installation, but I can't find it on my NT PC.
    Any ideas?

    I suspect you are using,java <program_name>.class to execute your program.
    Then it will try to find the promram 'class' in the package '<program_name>'.
    You need to use, java <program_name>, thats all.
    For eaxample if you have Prg1.java, then use,
    'javac Prg1.java' to compile it and 'java Prg1' to run it.
    Sudha

  • JDBC-ODBC Bridge Driver Suitable?

    I'm implementing a web site for a small company, so will be using MS Access for the database.
    Will a JDBC-ODBC Bridge driver be suitable?
    I ask this as I have heard that JDBC-ODBC Bridge drivers are only suitable for testing purposes - not commercial use.
    Cheers

    Ideally, you should use a third-party driver in your implementation. Not that there's anything wrong with the JDBC-ODBC Driver, but like you said, Sun never really intended it to be used for mainstream applications. It was developed to serve as a generic driver until third party drivers could be developed and released. Now that there's plenty of good third party drivers out there, the use of the JdbcOdbcDriver is really not recommended. Here's a list of current drivers available for MS Access.
    http://servlet.java.sun.com/products/jdbc/drivers/search_results.jsp?jdbc_version=0&vendor_name=&cert_mode=and&jdbc_driver_type_mode=and&dbms=6&dbms_mode=and&features_mode=and&results_per_page=20&submit=Search

  • FILE DSN using JDBC-ODBC Bridge ?

    Please Give Me sample code for Making connection
    against a dbms using FILE DSN & JDBC ODBC Bridge

    What do you mean by FILE DSN? Can you be a little more specific?

  • 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.

  • Null Pointer Exception using JDBC-ODBC bridge on Linux

    Wonder if anyone can help me with this one?
    I am attempting to use the JDBC-ODBC bridge on Fedora with J2SDK 1.4.2_04, however I am getting a NullPointerException whenever I get the connection. I can get the JDBC connection to work but it is a requirement that ODBC be used.
    The code is as simple as it can get.
    import java.sql.*;
    public class TestClass
       public static void doConnection()
          try
               Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
               Connection cn = DriverManager.getConnection("jdbc:odbc:DB");
          catch (Exception e)
               e.printStackTrace();
       public static void main(String[] args)
          doConnection();
    }Running this program using java -verbose TestClass I get the following output.
    [Loaded sun.jdbc.odbc.JdbcOdbc from /usr/java/j2sdk1.4.2_04/jre/lib/rt.jar]
    [Loaded java.lang.UnsatisfiedLinkError from /usr/java/j2sdk1.4.2_04/jre/lib/rt.jar]
    [Loaded java.sql.SQLException from /usr/java/j2sdk1.4.2_04/jre/lib/rt.jar]
    [Loaded java.sql.SQLWarning from /usr/java/j2sdk1.4.2_04/jre/lib/rt.jar]
    java.lang.NullPointerException
    [Loaded java.lang.StackTraceElement from /usr/java/j2sdk1.4.2_04/jre/lib/rt.jar]
    at sun.jdbc.odbc.JdbcOdbcDriver.initialize(JdbcOdbcDriver.java:436)
    at sun.jdbc.odbc.JdbcOdbcDriver.connect(JdbcOdbcDriver.java:153)
    at java.sql.DriverManager.getConnection(DriverManager.java:512)
    at java.sql.DriverManager.getConnection(DriverManager.java:193)
    at TestClass.doConnection(TestClass.java:13)
    at TestClass.main(TestClass.java:96)
    [Loaded java.lang.Shutdown from /usr/java/j2sdk1.4.2_04/jre/lib/rt.jar]
    [Loaded java.lang.Shutdown$Lock from /usr/java/j2sdk1.4.2_04/jre/lib/rt.jar]
    The UnsatisfiedLinkError suggests to me that a library cannot be found, but I don't know what library.
    As far as I know I have configured ODBC correctly. I can achieve connectivity to my database using other tools and I still get this same error irrespective of whether the DSN is valid or not.
    I have installed the unixODBC rpm.
    Any help/insite would be greatly appreciated.

    This is the output of ldd. Everything appears to be resolved.
    linux-gate.so.1 => (0x00cf5000)
    libodbcinst.so => /usr/sybase/lib/libodbcinst.so (0x001d5000)
    libjava.so => libjava.so (0x008af000)
    libjvm.so => /usr/java/j2sdk1.4.2_04/jre/lib/i386/client/libjvm.so (0x002a7000)
    libc.so.6 => /lib/i686/libc.so.6 (0x00d77000)
    libdbtasks7.so => /usr/sybase/lib/libdbtasks7.so (0x00eb2000)
    libdl.so.2 => /lib/libdl.so.2 (0x00111000)
    libstdc++-libc6.2-2.so.3 => /usr/lib/libstdc++-libc6.2-2.so.3 (0x00115000)
    libm.so.6 => /lib/i686/libm.so.6 (0x008fb000)
    libverify.so => libverify.so (0x0016e000)
    libnsl.so.1 => /lib/libnsl.so.1 (0x00180000)
    libpthread.so.0 => /lib/i686/libpthread.so.0 (0x006d0000)
    /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x00157000)
    libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00b75000)
    The ODBC is a Sybase driver and is loaded from elsewhere. I will check for any known compatibility issues.

  • Java Web Analyzer security hole in SQL Query Spreadsheet using JDBC-ODBC bridge

    Hi,<BR><BR>I use Hyperion Analyzer 7.0.1 on Windows 2003 and relation database DB2 v8.2.<BR><BR>I did:<BR>1. log in to Java Web Analyzer<BR>2. button New<BR>3. Select Layout: Custom Report<BR>4. from toolbar pull down to desktop "SQL Spreadsheet" option<BR>5. "Enter SQL Query" window opens, from JDBC Driver drop down window select "JDBC-ODBC Bridge"<BR>6. in "JDBC Connection String" window replace "db1" string with database name<BR>7. leave JDBC Username and JDBC Password empty (this is default)<BR>8. click on "Test Connection" button.<BR>9. "Test Connection" window opens with message "Connection Succeded"!!! So connection to database without password succeeded.<BR>10. in "SQL Query window" write any SQL you wish and Database will execute the SQL.<BR><BR><b>Conclusion: Connecting Analyzer with SQL Spreadsheet option to relation database DB2 is possible without password.</b><BR><BR>Question: Is there any way to prevent users from executing "SQL Spreedsheet" option?<BR><BR>Thanks,<BR>Grofaty

    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

  • Crash of application using JDBC ODBC bridge

    Hello,
    Recently my java application started crashing everyday with this error:
    An unexpected exception has been detected in native code outside the VM.
    Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x77f8910e
    Function name=RtlEnterCriticalSection
    Library=C:\WINNT\system32\ntdll.dll
    Current Java thread:
    at sun.jdbc.odbc.JdbcOdbc.allocConnect(Native Method)
    at sun.jdbc.odbc.JdbcOdbc.SQLAllocConnect(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcDriver.allocConnection(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcConnection.initialize(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcDriver.connect(Unknown Source)
    at java.sql.DriverManager.getConnection(Unknown Source)
    at java.sql.DriverManager.getConnection(Unknown Source)
    at Terminal.getConnection(Terminal.java:152)
    at CnetworkFile.unloadBuchung(CnetworkFile.java:3049)
    at CnetworkFile.receiveIt(CnetworkFile.java:2693)
    at NACController.OnREQCHN(NACController.java:236)
    at nacmain.processREQCHN(nacmain.java:394)
    at nacmain.access$39(nacmain.java)
    at nacmain$IncommingEvents.run(nacmain.java:113)
    An unexpected exception has been detected in native code outside the VM.
    Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x77f8910e
    Function name=RtlEnterCriticalSection
    Library=C:\WINNT\system32\ntdll.dll
    Current Java thread:
    at sun.jdbc.odbc.JdbcOdbc.execDirect(Native Method)
    at sun.jdbc.odbc.JdbcOdbc.SQLExecDirect(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcStatement.execute(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcStatement.executeQuery(Unknown Source)
    at CnetworkFile$onlineAction.lastBookingInformation(CnetworkFile.java:395)
    at CnetworkFile$onlineAction.run(CnetworkFile.java:1005)
    An unexpected exception has been detected in native code outside the VM.
    Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x77f8910e
    Function name=RtlEnterCriticalSection
    Library=C:\WINNT\system32\ntdll.dll
    Current Java thread:
    at sun.jdbc.odbc.JdbcOdbc.disconnect(Native Method)
    at sun.jdbc.odbc.JdbcOdbc.SQLDisconnect(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcDriver.disconnect(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcConnection.close(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcConnection.finalize(Unknown Source)
    at java.lang.ref.Finalizer.invokeFinalizeMethod(Native Method)
    at java.lang.ref.Finalizer.runFinalizer(Unknown Source)
    at java.lang.ref.Finalizer.access$100(Unknown Source)
    at java.lang.ref.Finalizer$FinalizerThread.run(Unknown Source)
    And the list continues.
    The problem i am facing is that even on old versions of my application that had never had a crash befor now it is crashing !!!
    Please help !
    Time is critical !
    Thank you very much !
    Best regards,
    Mihai

    hmmm..... ntdll.dll
    i would try the following.
    1) reinstall the JVM
    2) reinstall the MDAC (M$ data access components)
    3) re-install NT.
    if you get errors of this type with code that worked before and you haven't changed anything it may just be that some windows files are corrupted and need to be replaced or in the worst case the whole system needs to be re-installed.
    you might want to consider not using the jdbc-odbc driver in future to eliminate MDAC and ODBC as possible causes of problems and errors.
    otherwise welcome to windows. generally i find NT systems need to be re-installed once every 3 to four months on average if you use them heavily.

Maybe you are looking for

  • MacBook Pro mid 2009 won't boot OSX

    Since today i have a strange problem booting into Mac. This is how it started out: I was inside of Mac, and decided to reboot to Windows, to play a match of MW2. I forgot to use the ALT button, so Mac was already booting. I used the on/off switch to

  • Flushing out old values from dimensions

    Hi BEX Gurus, I'm using transactional data in the cube level. Now I restrict majority of the dimensions using structures using the data. Like say, you have Male/Female ratio. I had loaded M & F during 1st load. Now, when I load the 2nd time as MALE &

  • Recordings not playing correctly when watching online

    It stops the playback at 45 minutes. I am still having the issue. 3 recordings tonight all at the same time and all 3 started 5-6 minutes in when watching online. All 3 play fine in my house. Kenal0

  • Internal speakers not working on windows 7 :(

    hi all ! i have a dv9702ea which since i bought it has not made even a whimper from its internal speakers. the headphones however work fine ? . i have tried everything like all drivers ,installing drivers in compatability mode, all software like quic

  • Front Row shows Aperture projects in different order than Aperture does

    I have a bunch of projects, carefully organized in such a way that I can find them easily. Front Row just seems to display them ordered randomly. Anyone aware of a fix for this?