Skip to content
  • There are no suggestions because the search field is empty.

T SQL Script: BACAS Get All Live Grave Memorials

T SQL Script: BACAS Get All Live Grave Memorials

SELECT     TOP 100 PERCENT dbo.tblMainLocation.Description AS Cemetery, dbo.getSubLocationDesc(dbo.tblDetailedLocation.[Sub Location Id]) AS Area, 
                      dbo.getGraveDesc(dbo.tblDetailedLocation.ID) AS GraveNo, dbo.tblResource.Description AS Memorial
FROM         dbo.tblMemorialInformation INNER JOIN
                      dbo.tblMemorialLocation ON dbo.tblMemorialInformation.ID = dbo.tblMemorialLocation.MemorialID INNER JOIN
                      dbo.tblResource ON dbo.tblMemorialInformation.ResourceID = dbo.tblResource.ID RIGHT OUTER JOIN
                      dbo.tblDetailedLocation ON dbo.tblMemorialLocation.DetailedLocationID = dbo.tblDetailedLocation.ID RIGHT OUTER JOIN
                      dbo.tblMainLocation ON dbo.tblDetailedLocation.[Main Location Id] = dbo.tblMainLocation.ID
WHERE (dbo.tblMemorialInformation.EndDate > GETDATE())
ORDER BY Cemetery, Area, GraveNo