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.
43 lines
3.4 KiB
43 lines
3.4 KiB
USE [Vertragsverwaltung_20160404]
|
|
GO
|
|
/****** Object: StoredProcedure [dbo].[sp_get_LCdokumente] Script Date: 02.12.2016 09:08:53 ******/
|
|
DROP PROCEDURE [dbo].[sp_get_LCdokumente]
|
|
GO
|
|
/****** Object: StoredProcedure [dbo].[sp_get_LCdokumente] Script Date: 02.12.2016 09:08:55 ******/
|
|
SET ANSI_NULLS ON
|
|
GO
|
|
SET QUOTED_IDENTIFIER ON
|
|
GO
|
|
|
|
|
|
-- =============================================
|
|
-- Author: <Author,,Name>
|
|
-- Create date: <Create Date,,>
|
|
-- Description: <Description,,>
|
|
-- =============================================
|
|
Create PROCEDURE [dbo].[sp_get_LCdokumente]
|
|
---------------------------------------------------------------------------------
|
|
-- Stored procedure that will select all rows from the table 'Kuendigungsfrist'
|
|
-- Returns: @iErrorCode int
|
|
---------------------------------------------------------------------------------
|
|
@keyvalue int,
|
|
@doktype int,
|
|
@mitarbeiternr int
|
|
AS
|
|
SELECT 0 as DokIcon, dbo.lc_Dokument.DokumentNr, dbo.lc_Dokument.KeyValue, dbo.lc_Dokumenttyp.Bezeichnung as Dokumenttyp, dbo.lc_Dokument.Bezeichnung AS Bezeichnung, dbo.lc_Dokument.Beschreibung,
|
|
dbo.lc_Dokument.Filename, dbo.lc_Dokument.OriginalFilename_incl_Path, dbo.lc_Dokument.Version, dbo.lc_Dokument.VersionsNr, dbo.lc_Dokument.Versionsdatum,
|
|
dbo.lc_Dokument.Erstellt_am, dbo.lc_Dokument.Mutiert_am, dbo.lc_Dokument.Mutierer, dbo.lc_Dokument.Aktiv, dbo.lc_Dokument.DocImage, 0 as DokIdon
|
|
FROM dbo.lc_Dokument INNER JOIN
|
|
dbo.lc_Dokumenttyp ON dbo.lc_Dokument.DokumenttypNr = dbo.lc_Dokumenttyp.Dokumenttypnr
|
|
where Keyvalue = @keyvalue and doktype=@doktype
|
|
order by dbo.lc_dokument.erstellt_am desc
|
|
|
|
|
|
|
|
RETURN
|
|
|
|
|
|
|
|
|
|
GO
|