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

19 lines
498 B
Transact-SQL

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