2021年2月7日星期日

How can I set the user id as foreign key in model? [closed]

Some I am designing a bunch of databases for storing bookmarks.

Tag  ---  Id  Title  Description      Bookmark  --------  Id  UserId  TagId  Title  Url  

I knew Django already create and store users and unique user id when created an account. So I want to set the user id as a foreign key under table "Bookmark". What should I do?

https://stackoverflow.com/questions/66095218/how-can-i-set-the-user-id-as-foreign-key-in-model February 08, 2021 at 10:31AM

没有评论:

发表评论