How to store a list in a db column

后端 未结 6 845
悲哀的现实
悲哀的现实 2020-11-30 19:25

I would like to store an object FOO in a database. Lets say FOO contains three integers and a list of \"Fruits\".

The list can have any len

6条回答
  •  有刺的猬
    2020-11-30 19:50

    Its technically possible but would be very poor design, imo.

    You could do it by building the string and storing it in a nvarchar(max) field (if using sql server or its equivalent).

提交回复
热议问题