title: odbcinst: SQLGetPrivateProfileString failed with Unable to find component name
body: <p>I am able to use unixodbc without any problem with my default user. But when I switch to another user, I get an error.</p>
  
  <pre><code>[centos@ ~]$ odbcinst -q -s
  [ODBC]
  [Amazon Redshift DSN 32]
  
  [centos@ ~]$ su ruser
  Password:
  [ruser@ centos]$ odbcinst -q -s
  odbcinst: SQLGetPrivateProfileString failed with Unable to find component name.
  </code></pre>
  
  <p>Environment variables are set in both of the users:</p>
  
  <pre><code>AMAZONREDSHIFTODBCINI=/etc/amazon.redshiftodbc.ini
  ODBCSYSINI=/usr/local/odbc
  ODBCINI=/etc/odbc.ini
  LD_LIBRARY_PATH=/usr/local/lib
  LD_PRELOAD=/usr/local/lib/libodbcinst.so
  </code></pre>
  
  <p>Odbc configuration is as follows:</p>
  
  <pre><code>[ruser@ centos]$ odbcinst -j
  unixODBC 2.3.4
  DRIVERS............: /usr/local/odbc /odbcinst.ini
  SYSTEM DATA SOURCES: /usr/local/odbc /odbc.ini
  FILE DATA SOURCES..: /usr/local/odbc /ODBCDataSources
  USER DATA SOURCES..: /etc/odbc.ini
  SQLULEN Size.......: 8
  SQLLEN Size........: 8
  SQLSETPOSIROW Size.: 8
  </code></pre>
  
  <p>By the way, I don't understand why there are spaces in the above paths. I don't know if there is a way to change them. Any ideas to solve this issue? Overall odbc configuration seems the same in both of the users.</p>