| От | John R Pierce |
|---|---|
| Тема | Re: which is better- storing data as array or json? |
| Дата | |
| Msg-id | 54E410EE.9050609@hogranch.com обсуждение исходный текст |
| Ответ на | Re: which is better- storing data as array or json? (zach cruise <zachc1980@gmail.com>) |
| Список | pgsql-general |
On 2/17/2015 8:00 PM, zach cruise wrote: > i can't keep creating tables or adding columns every time i need to > add a nickname- this happens a lot. > > so i want to put everything in an array or json. > > remember rows can have different number of nicknames. david was suggesting a join table. one table with names (id, first name, last name, other attributes...) with one row per person and another table with (id, names_id, nickname, nickname attribute) with as many rows as there are nicks and users... you'd join these to get all the nicks for a given name, or to get all the names for a given nickname, etc. -- john r pierce 37N 122W somewhere on the middle of the left coast
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера