Обсуждение: Pgsql and .NET (Help!)

Поиск
Список
Период
Сортировка

Pgsql and .NET (Help!)

От
"Tommy"
Дата:
I have been trying for 3 days to connect to my postgres linux box via vb
.net on a windows box. I have to make this work somehow.

I found npgsql provider and tried it but could not make it connect either. I
would prefer to use the OleDbConnection if possible.

Has anyone been able to connect via the odbc driver and .NET?

I am getting despirate and not sure which way to turn now.

A snip of the code I have been using to try to connect is below.

Thanks in advance.

Tommy


Dim connstring As String = "Server=192.168.5.5;User
Id=myname;Password=mypassword;Database=mydbname"

Dim conn As New NpgsqlConnection(connstring)

conn.Open()

conn.Close()





Re: Pgsql and .NET (Help!)

От
"Dave Page"
Дата:

> -----Original Message-----
> From: Tommy [mailto:tmartin1@telocity.com]
> Sent: 28 October 2002 03:56
> To: pgsql-hackers@postgresql.org
> Subject: [HACKERS] Pgsql and .NET (Help!)
>
>
> I have been trying for 3 days to connect to my postgres linux
> box via vb .net on a windows box. I have to make this work somehow.
>
> I found npgsql provider and tried it but could not make it
> connect either. I would prefer to use the OleDbConnection if possible.
>
> Has anyone been able to connect via the odbc driver and .NET?

Yes, instructions are on http://odbc.postgresql.org, though they are for
C#, but they are using .Net. Npgsql does work quite well as well
though...

Regards, Dave