我有一个带有资产列表的数据库及其从表“tbl_info”中提取的信息,并且解决方案在 sql 中签出,但是在提交后它不会更新表。我不知道我错在哪里。我对存储过程和不错的 w/sql 相当陌生。
这是我的代码。
CREATE PROCEDURE [update_TBL_INFO_4]
(@ASSET_NUMBER [nvarchar],
@PORT_NUMBER [nvarchar],
@MACHINE_NAME [nvarchar],
@TYPE [nvarchar],
@BRANCH [nvarchar],
@BUILDING_NUMBER [nvarchar],
@FLOOR [nvarchar],
@ROOM_NUMBER [nvarchar],
@TELEPHONE_NUMBER [nvarchar],
@USERS [nvarchar],
@SERIAL [nvarchar])
AS
BEGIN
UPDATE [datasystems].[dbo].[TBL_INFO]
SET [ASSET_NUMBER] = @ASSET_NUMBER,
[PORT_NUMBER] = @PORT_NUMBER,
[MACHINE_NAME] = @MACHINE_NAME,
[TYPE] = @TYPE,
[BRANCH] = @BRANCH,
[BUILDING_NUMBER] = @BUILDING_NUMBER,
[FLOOR] = @FLOOR,
[ROOM_NUMBER] = @ROOM_NUMBER,
[TELEPHONE_NUMBER] = @TELEPHONE_NUMBER,
[USERS] = @USERS,
[SERIAL] = @SERIAL
WHERE
( [ASSET_NUMBER] = @ASSET_NUMBER AND
[PORT_NUMBER] = @PORT_NUMBER AND
[MACHINE_NAME] = @MACHINE_NAME AND
[TYPE] = @TYPE AND
[BRANCH] = @BRANCH AND
[BUILDING_NUMBER] = @BUILDING_NUMBER AND
[FLOOR] = @FLOOR AND
[ROOM_NUMBER] = @ROOM_NUMBER AND
[TELEPHONE_NUMBER] = @TELEPHONE_NUMBER AND
[USERS] = @USERS AND
[SERIAL] = @SERIAL)
END
GO