Hi Nick,<br> As you suggested i have used strace and found out that, command "<b>odbcinst -u -s -l -n MSSQLTestServer</b>" is deleting the UserDSN not the system DSN. I have added the details below. <br>
In that you can see that <b>/root/.odbc.ini</b> is user_data sources and so user dsn only keep changing not the system dsn.<br><br>/**************************************************************************************************<br>
root@sathiya:/home/sathiya# cat /root/.odbc.ini<br>root@sathiya:/home/sathiya# odbcinst -i -s -h -f tds.dsn.template <br>root@sathiya:/home/sathiya# cat /root/.odbc.ini<br>[MSSQLTestServer]<br>Driver = MySQL<br>Description = Northwind sample database<br>
Trace = No<br>Server = 192.168.1.25<br>Port = 1433<br>Database = Northwind<br><br>root@sathiya:/home/sathiya# odbcinst -i -s -l -f tds.dsn.template <br>root@sathiya:/home/sathiya# odbcinst -u -s -l -n MSSQLTestServer<br>
odbcinst: DSN removed (if it existed at all). ODBC_BOTH_DSN was used as the search path.<br>root@sathiya:/home/sathiya# cat /root/.odbc.ini<br>root@sathiya:/home/sathiya# odbcinst -j<br>unixODBC 2.2.15pre<br>DRIVERS............: /usr/local/etc/odbcinst.ini<br>
SYSTEM DATA SOURCES: /usr/local/etc/odbc.ini<br>FILE DATA SOURCES..: /usr/local/etc/ODBCDataSources<br>USER DATA SOURCES..: /root/.odbc.ini<br>SQLULEN Size.......: 4<br>SQLLEN Size........: 4<br>SQLSETPOSIROW Size.: 2<br>
root@sathiya:/home/sathiya#<br><br>*********************************************************************************************************/<br><br>Any idea regarding this..<br><br>Regards,<br>Sathiya.<br><br><br><br><div class="gmail_quote">
On Mon, Apr 19, 2010 at 5:51 PM, Nick Gorham <span dir="ltr"><<a href="mailto:nick.gorham@easysoft.com">nick.gorham@easysoft.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">sathiya dasan wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Am using version unixODBC 2.2.15pre.<br>
</blockquote></div>
Not sure what to suggest, using current source here lets -l and -h select where the dsn is removed from, user or system dsn.<br>
<br>
Try strace as I suggested, and also try odbcinst --version to check you are running the command you think you are.<div><div></div><div class="h5"><br>
<br>
-- <br>
Nick<br>
_______________________________________________<br>
unixODBC-support mailing list<br>
<a href="mailto:unixODBC-support@mailman.unixodbc.org" target="_blank">unixODBC-support@mailman.unixodbc.org</a><br>
<a href="http://mailman.unixodbc.org/mailman/listinfo/unixodbc-support" target="_blank">http://mailman.unixodbc.org/mailman/listinfo/unixodbc-support</a><br>
</div></div></blockquote></div><br>