KI-Kunst-Kirsten-Kloeckner/KiKunstDatenbank/dpo/StoredProcedures/spBildInfo_Insert.sql

17 lines
440 B
Transact-SQL

CREATE PROCEDURE [dbo].[spBildInfo_Insert]
@Id INT,
@Datum DATETIME2 ,
@Dateiname NCHAR(256) ,
@ImageModel NCHAR(32) ,
@WunschId INT
AS
BEGIN
INSERT INTO [dbo].[BildInfo] (Datum, Dateiname, ImageModel, WunschId)
VALUES (@Datum,
@Dateiname,
@ImageModel,
@WunschId);
SELECT Id FROM [dbo].[BildInfo] WHERE Id = CAST(SCOPE_IDENTITY() AS INT);
END