You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
103 lines
4.8 KiB
103 lines
4.8 KiB
USE [Vertragsverwaltung_20160404]
|
|
GO
|
|
/****** Object: StoredProcedure [dbo].[pr_LC_Dokument_Insert] Script Date: 02.12.2016 09:08:54 ******/
|
|
DROP PROCEDURE [dbo].[pr_LC_Dokument_Insert]
|
|
GO
|
|
/****** Object: StoredProcedure [dbo].[pr_LC_Dokument_Insert] Script Date: 02.12.2016 09:08:54 ******/
|
|
SET ANSI_NULLS ON
|
|
GO
|
|
SET QUOTED_IDENTIFIER ON
|
|
GO
|
|
|
|
|
|
|
|
---------------------------------------------------------------------------------
|
|
-- Stored procedure that will insert 1 row in the table 'LC_Dokument'
|
|
-- Gets: @iDokumentNr int
|
|
-- Gets: @iKeyValue int
|
|
-- Gets: @iDokType int
|
|
-- Gets: @iDokumenttypNr int
|
|
-- Gets: @sBezeichnung varchar(50)
|
|
-- Gets: @sBeschreibung varchar(2048)
|
|
-- Gets: @sFilename varchar(255)
|
|
-- Gets: @sOriginalFilename_incl_Path varchar(255)
|
|
-- Gets: @sVersion varchar(50)
|
|
-- Gets: @sVersionsNr varchar(50)
|
|
-- Gets: @daVersionsdatum datetime
|
|
-- Gets: @daErstellt_am datetime
|
|
-- Gets: @daMutiert_am datetime
|
|
-- Gets: @iMutierer int
|
|
-- Gets: @bAktiv bit
|
|
-- Gets: @iSecurityLevelNr int
|
|
-- Gets: @blobDocImage image
|
|
-- Returns: @iErrorCode int
|
|
---------------------------------------------------------------------------------
|
|
CREATE PROCEDURE [dbo].[pr_LC_Dokument_Insert]
|
|
@iDokumentNr int,
|
|
@iKeyValue int,
|
|
@iDokType int,
|
|
@iDokumenttypNr int,
|
|
@sBezeichnung varchar(50),
|
|
@sBeschreibung varchar(2048),
|
|
@sFilename varchar(255),
|
|
@sOriginalFilename_incl_Path varchar(255),
|
|
@sVersion varchar(50),
|
|
@sVersionsNr varchar(50),
|
|
@daVersionsdatum datetime,
|
|
@daErstellt_am datetime,
|
|
@daMutiert_am datetime,
|
|
@iMutierer int,
|
|
@bAktiv bit,
|
|
@iSecurityLevelNr int,
|
|
@blobDocImage image,
|
|
@iErrorCode int OUTPUT
|
|
AS
|
|
SET NOCOUNT ON
|
|
-- INSERT a new row in the table.
|
|
INSERT [dbo].[LC_Dokument]
|
|
(
|
|
[DokumentNr],
|
|
[KeyValue],
|
|
[DokType],
|
|
[DokumenttypNr],
|
|
[Bezeichnung],
|
|
[Beschreibung],
|
|
[Filename],
|
|
[OriginalFilename_incl_Path],
|
|
[Version],
|
|
[VersionsNr],
|
|
[Versionsdatum],
|
|
[Erstellt_am],
|
|
[Mutiert_am],
|
|
[Mutierer],
|
|
[Aktiv],
|
|
[SecurityLevelNr],
|
|
[DocImage]
|
|
)
|
|
VALUES
|
|
(
|
|
@iDokumentNr,
|
|
@iKeyValue,
|
|
@iDokType,
|
|
@iDokumenttypNr,
|
|
@sBezeichnung,
|
|
@sBeschreibung,
|
|
@sFilename,
|
|
@sOriginalFilename_incl_Path,
|
|
@sVersion,
|
|
@sVersionsNr,
|
|
@daVersionsdatum,
|
|
@daErstellt_am,
|
|
@daMutiert_am,
|
|
@iMutierer,
|
|
@bAktiv,
|
|
@iSecurityLevelNr,
|
|
@blobDocImage
|
|
)
|
|
-- Get the Error Code for the statement just executed.
|
|
SELECT @iErrorCode=@@ERROR
|
|
|
|
|
|
|
|
GO
|