1

I have a table in MySql:

CREATE TABLE db.catalog (
    id varchar(36) NOT NULL,
    pictures json DEFAULT NULL
)

and declaration form code

public class catalog {        
   public string id { get; set; }
   public List<string> pictures { get; set; }
}

and I have data: pictures = ["JavaScript", "ES2015", "JSON"]

enter image description here

When you run the query through OrmLite deserializing is not correct...

It is evident that the deserialization as in the cases of key-value data.

I'm doing something wrong? or is it meant to be?

Thanks!

enter image description here

Mher Arsh
  • 588
  • 4
  • 21

1 Answers1

1

This code will help, the question is closed:

MySqlDialect.Provider.StringSerializer = new JsonDataContractSerializer();

Thanks @mythz: https://stackoverflow.com/a/35186935/7015077

Mher Arsh
  • 588
  • 4
  • 21