-- ------------------------------------------------------------------------------------------------------------------------------------ IF OBJECT_ID('[sp_paf_selectByPostcode]', 'P') IS NOT NULL DROP PROC [sp_paf_selectByPostcode] GO -- Designed for use with Palace Stock Tracker only -- Do not edit this stored procedure because it may be updated and changes will be lost -- (C) 2019 Palace IT Limited /* Example: EXEC sp_paf_selectByPostcode @postCode='NW1 1AA' */ CREATE PROCEDURE [dbo].[sp_paf_selectByPostcode] @postCode varchar(8) = '' AS if @postCode = '' OR @postCode IS NULL BEGIN RAISERROR('@postCode is required', 16, 1) RETURN END SELECT * FROM [PAFData] WHERE [postCode] = @postCode GO -- ------------------------------------------------------------------------------------------------------------------------------------