Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2009

    Unanswered: dbaccess command line help for newbie.


    I'm starting a new job and have no informix experience whatsoever. I'm trying to map common things I'd do in postgres to informix, and I'm not having much luck.

    The #1 thing I'm having a problem with is getting to be able to pipe in SQL commands contained in .sql files from the command line.

    If I do:

    $ dbaccess database_name testfile.sql

    I get back:

    951: Incorrect password or user username@mymachine-dat is not known on the database server.

    Is there some kind of configuration file I could use to fix this? It seems to be getting a network based username. I've talked to various people at my company, and no one seems to know how to get this working (or sees the utility in being able to execute sql files at the command line). Any help is much appreciated. I'm on my own here.

    Thanks in advance.


  2. #2
    Join Date
    Apr 2007
    Jundiai / SP - Brasil
    1) Informix use the OS user as default to authentication
    2) if executed the dbaccess from a remote machine, they use your logged user to connect, if they don't exists, you got this error 951)
    >finderr 951
    -951 User username is not known on the database server.

    The database server that you tried to access does not accept either
    your user ID, the login name that is specified for the desired server
    host in your ~/.netrc file, or the user name that is specified in the
    USER clause of a CONNECT statement. If you are explicitly specifying
    your user name in the ~/.netrc file or in a CONNECT statement, check
    that the name is correct. If you do not have a valid user ID on the
    server computer, see your system administrator. This message appears
    with Version 6.0 and later.
    3) dbaccess have some limitations with conection authentication...
    4) Have a several ways to solve this..
    a) configure a .netrc (client side)
    b) configure a hosts.equiv (server side)
    c) use the commando "connect" in your script and don't specify the database on the command: dbaccess - yourscript.sql
    check the manual for more information: CONNECT
    César Inacio Martins
    Jundiai / SP - Brasil - em Português - English (translated by Google).

  3. #3
    Join Date
    Dec 2009
    Thanks for your solution. It identified that I left out one important piece of information

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts