Hi there,

I am newbie to php. I was trying to use the ODBC function to connect to Ms Access 2000 database. I had set all the necessary information in the ODBC function in the Control Panel for Window NT. The problem is, the program can't even connect to the databse. It shows the following error message:

Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified, SQL state IM002 in SQLConnect in odbc.php3 on line 3

Can anyone help me, what the cause of the problem. Is it because of I don't have the php_odbc.dll file? Does anyone know where to download this file?

Thank you.

    I had the exact same problem but with Access 97, with a machine running Win2000 Pro.

    I tried in the odbc_connect using DNS="name" which cleared the message but gave a new one that is unable to find the database of that name.

    To check that the ODBC was working I used an ASP page to connect (which used ADO), and that worked. So I changed my code to use ADO on Win2000 instead of directly to ODBC.

    I'm not sure if this is a Win2000 ODBC problem or a PHP on Win2000 problem.

    But try using ADO instead (which in the end uses ODBC!!!).

      9 days later

      I read your problem, I am also newbie. Im too trying to use the ODBC function to connect to Ms Access 2000 or SQL database.

      I had set all the necessary information in the ODBC function in the Control Panel for Window NT.
      WHAT IS THIS NECESSARY INFO.
      The problem is, the program can't even connect to the databse. It shows the following error message:
      CAN YOU SEND ME THE FULL SYNTAX OF THE CONNECTION??to jgp@acropolis.com.ar
      I GET A PARSE ERROR!!
      Thanks
      Javier

      Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified, SQL state IM002 in SQLConnect in odbc.php3 on line 3

      Can anyone help me, what the cause of the problem. Is it because of I don't have the php_odbc.dll file? Does anyone know where to download this file?

        a month later

        Javier, have you solve the problem?
        I've the same, and you could help me.

        I'm from Spain, so you can write in Spanish if you prefer that . 🙂

          Can I use ADO to connect to Acces with php?

            Sole

            Estoy iniciandome en PHP, Linux, MySql, Apache y Samba.
            Lamentablemente aun no llegue al tópico de Access y PHP, pero me imagino que la conección se debe hacer a traves de ODBC.
            Ayer termine lograr que Linux me reconozca la placa de red. Sigo con apache, samba y cuando llegue a Access te cuento.
            Otro problema que me surgio es el de importar tablas Access en MySql, que tambien estoy analizando.
            Mantenéme informado de tus adelantos.
            Gracias
            Jgp@acropolis.com.ar
            Javier

            Sole wrote:

            Javier, have you solve the problem?
            I've the same, and you could help me.

            I'm from Spain, so you can write in Spanish if you prefer that . 🙂

              Write a Reply...