我正在尝试将此表转换为sqlite,似乎无法正确定义。
CREATE TABLE [dbo].[IdentityOneToManyChild]
(
[ParentId] [int] NOT NULL,
[ChildId] [int] IDENTITY(1,1) NOT NULL,
[Text] [nvarchar](50) NOT NULL,
PRIMARY KEY CLUSTERED ([ParentId] ASC, [ChildId] ASC)
) ON [PRIMARY]
以下对我有用的东西
CREATE TABLE [IdentityOneToOneChild] ( [ParentId] integer NOT NULL, [Text] nvarchar(50) NOT NULL COLLATE NOCASE, PRIMARY KEY ([ParentId]) , FOREIGN KEY ([ParentId]) REFERENCES [IdentityOneToOneParent]([ParentId]) );