1

I have Solution in vs 2010 with many projects that are build in .net 2.0, but now I want to add a project that will make Npgsqlconnection, the issue is that I don't know how to find Npgsql.dll for .net 2.0. Any suggestions please. I can't upgrade project to higher .net version.

3
  • 2
    Thanks to Npgsql being open source you can download it, switch the target version to .NET 2.0, fix compile errors, run tests and fix their errors Commented Jun 22, 2020 at 7:40
  • 2
    The version 2.2.7 download on nuget has binaries for net20 and net35 (which uses the 2.0 runtime). Of course it's nearly five years old and may not work against modern versions of PostgreSQL. Commented Jun 22, 2020 at 7:41
  • I have downloaded the version 2.2.7 and now how do i include it in my project? Thanks a lot, i`m new in this and i know that maybe this may be silly question but i hope you can help . Commented Jun 22, 2020 at 8:06

1 Answer 1

2

By having a look at their repository you can see that the latest nuspec-file that contains a reference to .Net Framework 2.0 is tagged with version 2.2.7. So you should be able to use that version from Nuget. However, this is two major versions behind the current version (and the next major version is available as an alpha) so you might have some problems finding relevant API documentation for your version.

Also note that this release is from 2015, so it might not work properly or support all features found in PostgreSQL versions from after that.

Sign up to request clarification or add additional context in comments.

6 Comments

I have downloaded the version 2.2.7 and now how do i include it in my project? Thanks a lot, i`m new in this and i know that maybe this may be silly question but i hope you can help
Look into how to add a nuget package as a reference to your project. It varies a bit depending on your version av Visual Studio.
Alternatively if you can't make nuget work you can unzip the nupkg file and take the DLLs from the lib\net20 folder. But I'd recommend using nuget if you can.
Thanks a lot for the help, i`ll try and let you know.
Can you upgrade to the latest version of .NET 2 at least, so that you can then load this assembly? If not, I'd check out the v2.2.7 tag from Karl-Johan's GitHub link and build it yourself then.
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.