Page 1 of 1

Storing JSON objects

Posted: Tue 04 May 2021 12:15
by RobertK
database: postgres

In Entity Developer, what column data type do you use to store JSON objects?

Re: Storing JSON objects

Posted: Wed 05 May 2021 10:45
by Shalex
JSON is mapped to System.String. Refer to https://www.devart.com/dotconnect/postg ... pping.html.

JIC: you can change default mapping via Visual Studio > Tools > Entity Developer > Options > Devart Entity Developer > Servers Options > PostgreSQL.

Re: Storing JSON objects

Posted: Tue 11 May 2021 07:54
by RobertK
what would you select for the datatype? jsonobject?

https://pasteboard.co/K1mNhHp.png

Re: Storing JSON objects

Posted: Thu 13 May 2021 13:00
by Shalex
If you work with Devart EF Core Model (*.efml) using Npgsql provider, you can map JSON to JsonDocument and JsonElement.

Refer to https://www.devart.com/entitydeveloper/ ... story.html:
6.11.1213 01-Apr-21
System.Text.Json (JsonDocument and JsonElement as property types) is supported for Pomelo.EntityFrameworkCore.MySql and Npgsql in EF Core Model