Storing a Dictionary in the database

前端 未结 3 529
有刺的猬
有刺的猬 2020-12-21 05:24

At some point in my code, I\'m creating a dictionary of type Dictionary and I\'m wondering what\'s the best way to store this in a databas

3条回答
  •  温柔的废话
    2020-12-21 05:57

    If you really want to store the full dictionary as a single string, then you could serialize your dictionary to JSON (or XML) and store the result to the database.

提交回复
热议问题