Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


Le 21/05/12 18:34, Jonathan Ryshpan a écrit :

Hi,

My particular system runs KDE, which requires iodbc for many
applications, so that is what I am using for the database interface.
Iodbc has two kinds of configuration files in two places, namely:
        /etc/odbc.ini
        /etc/odbcinst.ini

These are the system DSN and ODBC configuration files. You generally
need root/sudo access to change these files.


        ~/.odbc.ini
        ~/.odbcinst.ini  (maybe not used)

These are the hidden, user DSN and ODBC configuration files. These files
are used as a fallback, or in addition, if nothing is defined in the
system DNS/ODBC configuration files.


The iodbc web site has info about ~/.odbc.ini, and by implication
about /etc/odbc.ini, which contains (I believe) default info; but it has
nothing about /etc/odbcinst.ini.  Can someone enlighten me about the
relation about these files and what they are used for?


odbcinst.ini defines the name of the ODBC drivers present on the system,
and the locations/libraries to be used when an ODBC connection protocol
is invoked by a third party application, see the examples below that I
have on my Macbook :

[ODBC Drivers]
Actual SQL Server            = Installed
Actual Open Source Databases = Installed
Actual Oracle                = Installed
Actual Access                = Installed
MySQL ODBC 5.1 Driver        = Installed

[Actual SQL Server]
Driver = /Library/ODBC/Actual SQL Server.bundle/Contents/MacOS/atsqlsrv.so
Setup  =

[Actual Open Source Databases]
Driver = /Library/ODBC/Actual Open Source
Databases.bundle/Contents/MacOS/atopnsrc.so
Setup  =

[Actual Oracle]
Driver = /Library/ODBC/Actual Oracle.bundle/Contents/MacOS/atoradb.so
Setup  =

[Actual Access]
Driver = /Library/ODBC/Actual Access.bundle/Contents/MacOS/ataccess.so
Setup  =

[MySQL ODBC 5.1 Driver]
Driver = /usr/local/lib/libmyodbc5.so
SETUP  = /usr/local/lib/libmyodbc3S.so



odbc.ini defines the connection parameters to access a given data source
name (DSN), see my example below for my Macbook :


[ODBC Data Sources]
Actual_MAMP = Actual Open Source Databases
myodbc      = MySQL ODBC 5.1 Driver
IPDB_MAMP   = MySQL ODBC 5.1 Driver
ipdatabase  = MySQL ODBC 5.1 Driver

[ODBC]
Trace         = 0
TraceAutoStop = 0
TraceFile     =
TraceLibrary  =

[Actual_MAMP]
Driver       = /Library/ODBC/Actual Open Source
Databases.bundle/Contents/MacOS/atopnsrc.so
Description  = Actual Driver to MAMP
Database     = ipdatabase
Server       = localhost
Port         = 8889
IncludeViews = Yes
UserID       = alex
UseKeychain  = Yes

[myodbc]
Driver      = /usr/local/lib/libmyodbc5.so
Description = Generic myodbc connection
SERVER      = localhost
PORT        = 3306

[IPDB_MAMP]
Driver      = /usr/local/lib/libmyodbc5.so
Description = MyODBC Connection via Mamp port
Server      = 127.0.0.1
Port        = 8889

[ipdatabase]
Driver      = /usr/local/lib/libmyodbc5.so
Description = IP management db
Server      = 127.0.0.1
Port        = 3306



Entries defined in /etc/ are system-wide, i.e. in theory available to
every user declared on the system, entries put in the local user file
are only available to that particular user.



Alex





-- 
For unsubscribe instructions e-mail to: users+help@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.