DSN for Ms Access

Discussion in 'Java' started by Grzesiek, Oct 25, 2007.

  1. Grzesiek

    Grzesiek Guest

    What is Data Source Name for MS Access database?

    "driver={Microsoft Access Driver (*mdb)};dbq=c:\myDataBase.mdl;"

    doesnt work

    Thanx

    :)
     
    Grzesiek, Oct 25, 2007
    #1
    1. Advertising

  2. Grzesiek

    Grzesiek Guest

    On 25 Pa , 20:27, Grzesiek <> wrote:
    > What is Data Source Name for MS Access database?
    >
    > "driver={Microsoft Access Driver (*mdb)};dbq=c:\myDataBase.mdl;"
    >
    > doesnt work
    >
    > Thanx
    >
    > :)


    Its easy:

    Driver={Microsoft Access Driver (*.mdb)};DBQ=C:
    \myDataBase.mdb;UID=;PWD=;

    Im the best :)
     
    Grzesiek, Oct 25, 2007
    #2
    1. Advertising

  3. Grzesiek

    Guest

    On Oct 25, 2:27 pm, Grzesiek <> wrote:
    > What is Data Source Name for MS Access database?
    >
    > "driver={Microsoft Access Driver (*mdb)};dbq=c:\myDataBase.mdl;"
    >
    > doesnt work
    >
    > Thanx
    >
    > :)


    A trick that used to work for me for stuff like this was create a new
    text file named "test.dsn". Then double-click it and Windows will
    prompt you with a dialogue to fill in the DSN details. Then after
    that, you open it up in Notepad again and read the connection string.
    But I can't test that right now because my current workstation keeps
    opening the file with VIM.
     
    , Oct 25, 2007
    #3
  4. Grzesiek

    Roedy Green Guest

    Roedy Green, Oct 25, 2007
    #4
  5. Grzesiek

    kcwong Guest

    On Oct 26, 2:53 am, wrote:
    > > On Oct 25, 2:27 pm, Grzesiek <> wrote:
    > > What is Data Source Name for MS Access database?

    >
    > > "driver={Microsoft Access Driver (*mdb)};dbq=c:\myDataBase.mdl;"
    > > doesnt work

    >
    > A trick that used to work for me for stuff like this was create a new
    > text file named "test.dsn". Then double-click it and Windows will
    > prompt you with a dialogue to fill in the DSN details. Then after
    > that, you open it up in Notepad again and read the connection string.
    > But I can't test that right now because my current workstation keeps
    > opening the file with VIM.


    Which version of Windows are you talking about? I'm using Windows XP,
    while .dsn has an icon defined, there's no default program to open it.
     
    kcwong, Oct 26, 2007
    #5
  6. Grzesiek

    Guest

    On Oct 25, 11:10 pm, kcwong <> wrote:
    > On Oct 26, 2:53 am, wrote:
    >
    > > > On Oct 25, 2:27 pm, Grzesiek <> wrote:
    > > > What is Data Source Name for MS Access database?

    >
    > > > "driver={Microsoft Access Driver (*mdb)};dbq=c:\myDataBase.mdl;"
    > > > doesnt work

    >
    > > A trick that used to work for me for stuff like this was create a new
    > > text file named "test.dsn". Then double-click it and Windows will
    > > prompt you with a dialogue to fill in the DSN details. Then after
    > > that, you open it up in Notepad again and read the connection string.
    > > But I can't test that right now because my current workstation keeps
    > > opening the file with VIM.

    >
    > Which version of Windows are you talking about? I'm using Windows XP,
    > while .dsn has an icon defined, there's no default program to open it.


    Hmm... I thought it was just my workstation here. Well, you could try
    creating the file, then going to Control Panels -> Admin Tools -> Data
    sources (ODBC)
    and then create a DSN from a file and choose the test.dsn you created.
    The connection string should be in the file.
     
    , Oct 26, 2007
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Otuatail

    Conecting to Access via DSN

    Otuatail, Dec 5, 2003, in forum: HTML
    Replies:
    3
    Views:
    426
    Whitecrest
    Dec 6, 2003
  2. madfisher

    Access DSN Connection String

    madfisher, Apr 26, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    6,059
    Jeff Dillon
    Apr 26, 2006
  3. Sandeep Gupta

    DSN Connection to Microsoft Access

    Sandeep Gupta, May 18, 2007, in forum: ASP .Net
    Replies:
    12
    Views:
    2,240
    Mark Rae
    May 25, 2007
  4. Replies:
    4
    Views:
    530
  5. Arpan

    System DSN Faster Than File DSN!

    Arpan, Jun 26, 2005, in forum: ASP General
    Replies:
    7
    Views:
    286
Loading...

Share This Page