Connecting Tech Pros Worldwide Forums | Help | Site Map

Connecting to Oracle 9i Lite from VB.NET ODBC

Andrew McGregor
Guest
 
Posts: n/a
#1: Nov 20 '05

Hi,

I am trying to get a VB.NET application to connect to a local Oracle 9i Lite
database.

What is the correct form for a connect string?

cn = New
Microsoft.Data.Odbc.OdbcConnection("dsn=POLite;Tru sted_Connection=yes;User
Id=SYSTEM;Password=MANAGER")

raises the following exception:

could not open oracle connection: Microsoft.Data.Odbc.OdbcException: ERROR
[S1000][POL-2200] failed to create mapped file
ERROR [IM006] [Microsoft][ODBC Driver Manager] Driver's SQLSetConnectAttr
failed
ERROR [01000] [Microsoft][ODBC Driver Manager] The driver doesn't support
the version of the ODBC behaviour that the application requested (see
SQLSetEnvAttr)
at Microsoft.Data.Odbc.OdbcConnection.Open

I have also tried the following:

cn = New Microsoft.Data.Odbc.OdbcConnection("Driver={Oracle Lite 40 ODBC
Driver};DataBase=mobile;User Id=SYSTEM;Password=MANAGER;Persist Security
Info=False;DSN=POLite")

which provides a more serious failure:

OracleLiteTest.exe has encountered a problem and needs to be shut down.

and

could not open oracle connection: Microsoft.Data.Odbc.OdbcException:
ERROR - no error information available
at Microsoft.Data.Odbc.OdbcConnection.Open

Server Explorer displays some Data Connections, am I incorrectly mixing OLE
and ODBC?

Regards,

Andy



Cor Ligthert
Guest
 
Posts: n/a
#2: Nov 20 '05

re: Connecting to Oracle 9i Lite from VB.NET ODBC


Hi Andrew,

For Oracle related questions I advice you the newsgroup

Adonet
<news://msnews.microsoft.com/microsoft.public.dotnet.framework.adonet>

Web interface:
<http://communities2.microsoft.com/co...s/?dg=microsof
t.public.dotnet.framework.adonet>


I hope this helps a little bit?

Cor


thomas wenning
Guest
 
Posts: n/a
#3: Nov 20 '05

re: Connecting to Oracle 9i Lite from VB.NET ODBC



"Andrew McGregor" <andy@misk.co.uk> schrieb im Newsbeitrag
news:F9ANc.15577$7t5.12147@fe1.news.blueyonder.co. uk...[color=blue]
>
> Hi,
>
> I am trying to get a VB.NET application to connect to a local Oracle 9i[/color]
Lite[color=blue]
> database.
>
> What is the correct form for a connect string?
>
> cn = New
> Microsoft.Data.Odbc.OdbcConnection("dsn=POLite;Tru sted_Connection=yes;User
> Id=SYSTEM;Password=MANAGER")
>
> raises the following exception:
>
> could not open oracle connection: Microsoft.Data.Odbc.OdbcException:[/color]
ERROR[color=blue]
> [S1000][POL-2200] failed to create mapped file
> ERROR [IM006] [Microsoft][ODBC Driver Manager] Driver's SQLSetConnectAttr
> failed
> ERROR [01000] [Microsoft][ODBC Driver Manager] The driver doesn't support
> the version of the ODBC behaviour that the application requested (see
> SQLSetEnvAttr)
> at Microsoft.Data.Odbc.OdbcConnection.Open
>
> I have also tried the following:
>
> cn = New Microsoft.Data.Odbc.OdbcConnection("Driver={Oracle Lite 40 ODBC
> Driver};DataBase=mobile;User Id=SYSTEM;Password=MANAGER;Persist Security
> Info=False;DSN=POLite")
>[/color]

Hi Andrew,

i hope this help's http://www.connectionstrings.com/

Greeting

Thomas


Andrew McGregor
Guest
 
Posts: n/a
#4: Nov 20 '05

re: Connecting to Oracle 9i Lite from VB.NET ODBC


"thomas wenning" <nospam.thomas.wenning@gmx.de> wrote in message news:<uRGVJFIdEHA.2352@TK2MSFTNGP09.phx.gbl>...[color=blue]
> "Andrew McGregor" <andy@misk.co.uk> schrieb im Newsbeitrag
> news:F9ANc.15577$7t5.12147@fe1.news.blueyonder.co. uk...[color=green]
> >
> > Hi,
> >
> > I am trying to get a VB.NET application to connect to a local Oracle 9i[/color]
> Lite[color=green]
> > database.
> >
> > What is the correct form for a connect string?
> >
> > cn = New
> > Microsoft.Data.Odbc.OdbcConnection("dsn=POLite;Tru sted_Connection=yes;User
> > Id=SYSTEM;Password=MANAGER")
> >
> > raises the following exception:
> >
> > could not open oracle connection: Microsoft.Data.Odbc.OdbcException:[/color]
> ERROR[color=green]
> > [S1000][POL-2200] failed to create mapped file
> > ERROR [IM006] [Microsoft][ODBC Driver Manager] Driver's SQLSetConnectAttr
> > failed
> > ERROR [01000] [Microsoft][ODBC Driver Manager] The driver doesn't support
> > the version of the ODBC behaviour that the application requested (see
> > SQLSetEnvAttr)
> > at Microsoft.Data.Odbc.OdbcConnection.Open
> >
> > I have also tried the following:
> >
> > cn = New Microsoft.Data.Odbc.OdbcConnection("Driver={Oracle Lite 40 ODBC
> > Driver};DataBase=mobile;User Id=SYSTEM;Password=MANAGER;Persist Security
> > Info=False;DSN=POLite")
> >[/color]
>
> Hi Andrew,
>
> i hope this help's http://www.connectionstrings.com/
>[/color]

Yes it does, thank you. It proves that my first attempt was correct,
and I should of trusted the exception .NET captured, POL-2200.

I am concerned that I am even getting a POL-2200 exception at all on
any modern system, but that is for an Oracle or XP discussion.

Many thanks.

Andy
Closed Thread