Skip to main content
Filter by
Sorted by
Tagged with
48 votes
1 answer
52k views

I'd like to better understand Connection Pooling when using Npgsql for Postgres. (http://www.npgsql.org/) When I use the connection string: UserID=root;Password=myPassword;Host=localhost;Port=5432;...
Chris's user avatar
  • 3,323
5 votes
3 answers
6k views

I´ve had the problem, that my AspNetCore.App-metapackage referenced a lower Version of EntityFrameworkCore (2.1.2), than a EfCore provider package (NpgSql, referencing 2.1.3). The result was the ...
Joshit's user avatar
  • 1,347
114 votes
15 answers
177k views

I have common problem. Cannot write DateTime with Kind=UTC to PostgreSQL type 'timestamp without time zone' And I want to enable Legacy Timestamp behavoour as is documented here: https://github.com/...
mbrc's user avatar
  • 4,053
9 votes
7 answers
27k views

I use Entity Framework 7 with Npgsql adapter. Sql generated by EF seems like SELECT "r"."Id", "r"."Name" FROM "public"."Role" AS "r" and it doesn't work in Postgres, because case-sensitive policy. To ...
user3272018's user avatar
  • 2,451
6 votes
3 answers
16k views

I have looked into materials in www.npgsql.org, but couldn't find how to solve my problem... Table, PostgreSQL [City], [State] "Austin", "TX" "Houston", "TX" "Los Angeles", "CA" "San Diego", "CA" "...
Chris Moon's user avatar
10 votes
4 answers
22k views

I'm trying to insert a row into a PostgreSQL table with a serial primary key and I need to retrieve this column after it was inserted. I got something like this: The table "pais" has 3 columns: id, ...
Cheluis's user avatar
  • 1,412
6 votes
5 answers
7k views

I'm trying to create a small POC for my boss about the hybrid of npgsql 12 and ef6, created a new project on visual studio created a sample database created the corresponding classes and the dbcontext ...
Koby Yehezkel's user avatar
5 votes
1 answer
4k views

I'm trying to use dapper to parameterize a postgres anonymous function i've written to do an upsert. Here's the code: private static int UpsertProductPrice( IDbConnection connection, ...
Perry R's user avatar
  • 53
3 votes
1 answer
3k views

While using a PostgreSQL database with Entity Framework on Mono using the packages Npsql and Npsql.EntityFramework I get an exception while trying to run Code First migrations from a Console app. The ...
user2609980's user avatar
  • 10.5k
1 vote
2 answers
7k views

Postgresql 9.1 NPGSQL 2.0.12 I have binary data I am wanting to store in a postgresql database. Most files load fine, however, a large binary (664 Mb) file is causing problems. When trying to load ...
Jayden's user avatar
  • 2,787
13 votes
2 answers
24k views

Passing a null value using Npgsql looks something like this: using (NpgsqlCommand cmd = new NpgsqlCommand("insert into foo values (:TEST)", conn)) { cmd.Parameters.Add(new NpgsqlParameter("TEST", ...
Hambone's user avatar
  • 16.5k
11 votes
3 answers
23k views

As far as I've understood it, there is no option in EF (and EF Core) to explicitly lock resources which I'm querying, but I'll need this functionality quite often and don't really feel like falling ...
peter's user avatar
  • 15.3k
8 votes
1 answer
10k views

I'm trying to use a TransactionScope with the Npgsql provider. I found in an old question (provider for PostgreSQL in .net with support for TransactionScope) that Npgsql didn't supported it yet. Now, ...
Federico Orlandini's user avatar
6 votes
3 answers
10k views

I am attempting to set up my application to use Entity Framework with PostgreSQL, but I have run up against a problem. I have added Npqsql via nuget, and added the following provider factory to web....
jcvandan's user avatar
  • 14.4k
5 votes
1 answer
25k views

I just learn how to connect C# and PostgresSQL. I want to INSERT data from tb1(Textbox) and tb2 to database. But I don't know how to code My previous code is SELECT from database. this is my code ...
user1479013's user avatar
4 votes
2 answers
24k views

My asynchronous function tries to select a single record from a table. This function accepts a few arguments passed from another function. So, some processes (6 at least) can use it simultaneously. ...
Alex's user avatar
  • 715
4 votes
1 answer
3k views

I have been messing with the following for a few days now. I have a Nancy app running on Mono, with EntityFramework with Repository pattern and UnitOfWork, and Postgres. Nancy uses TinyIoC as it's ...
Corstiaan's user avatar
  • 1,114
3 votes
2 answers
14k views

I pass the parameters in the sql query using the driver npgsql: SqlCommand = new NpgsqlCommand(); .... SqlCommand.CommandText = "SELECT id,name FROM table1 WHERE field1=:param2 ORDER BY name;"; ...
user3788853's user avatar
3 votes
1 answer
3k views

I'm trying to return a custom (composite) type based on an implicit table type. I have this table definition: CREATE TABLE app_user (id CHAR(36) PRIMARY KEY, name TEXT); Which is mapped to this ...
user955629's user avatar
3 votes
2 answers
7k views

Sometimes I really start wondering what's going on in my sourcecode: I'm trying to connect to PostGres 9.0 using npgsql 2.0.11.0, which I'm damn sure I already did, but right now, my program throws a ...
Sebastian Edelmeier's user avatar
2 votes
3 answers
8k views

I've spent a day trying to migrate an Entity Framework 6 SQL Server CE to PostgreSQL. I've copied the database over fine, but I can't seem to get the data provider to work. Firstly I tried the older ...
Nintynuts's user avatar
1 vote
2 answers
5k views

I have a long running query that times out after about 48 minutes. The command time-out is set to 2 hours and the connection time-out is set to 17 minutes. What would cause the query to raise a time-...
Mr Shoubs's user avatar
  • 15.6k
1 vote
2 answers
1k views

I am using Dapper with Postgres npgsql and I am having trouble executing an SQL command using INTERVAL. The command works fine outside my code. I get the error Npgsql.PostgresException: '42601: ...
jason.kaisersmith's user avatar
0 votes
2 answers
3k views

ActiveRecord mape: [ActiveRecord("JobTitle",Schema="public")] public class JobTitle :ActiveRecordValidationBase<JobTitle> { [PrimaryKey(Column = "Id")] public virtual int Id { get; ...
Elyor's user avatar
  • 865
39 votes
3 answers
57k views

I am using Entity Framework Core with npgsql postgresql for Entity Framework Core. My question is, using migrations, how do I mark a class property to generate a JSONB column type? For example: ...
bruno.almeida's user avatar

1
2 3 4 5