我有這些表。我想寫更新查詢sql查詢2表來更新表
CREATE TABLE [dbo].[Feasibility](
[FeasibilityID] [int] IDENTITY(1,1) NOT NULL,
[orderstatus] [varchar](20) COLLATE SQL_Latin1_General_CP1_CI_AS NULL CONSTRAINT [DF_Feasibility_orderstatus] DEFAULT ('Not Placed')
CONSTRAINT [PK_Feasibility] PRIMARY KEY CLUSTERED
(
[FeasibilityID] ASC
)WITH (PAD_INDEX = OFF, IGNORE_DUP_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
CREATE TABLE [dbo].[OrderMaster](
[orderid] [int] IDENTITY(1,1) NOT NULL,
[feasibilityid] [int] NULL,
CONSTRAINT [PK_OrderMaster] PRIMARY KEY CLUSTERED
(
[orderid] ASC
)WITH (PAD_INDEX = OFF, IGNORE_DUP_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
我想在可行性表orderstatus更新到所有這些存在於ordermaster表
到目前爲止您試過了什麼? –