Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

For Discussion 


#

Comment
Owner
1Should Site Number & Name be unique ?

Site name could be duplicated. (The Surgery is a common name for a medical practice)

Site number should be unique.

Alistair Pringle (Unlicensed)

Break down of SiteNumber and SiteName NULL or NOT NULL values;


Code Block
sql
sql
select CASE WHEN SiteName IS NULL THEN 'NULL' ELSE 'NOT NULL' END SiteName, 
	   CASE WHEN SiteNumber IS NULL THEN 'NULL' ELSE 'NOT NULL' END SiteNumber, status, count(*) 
from [HEELIVE].[vwSite] 
group by CASE WHEN SiteName IS NULL THEN 'NULL' ELSE 'NOT NULL' END, 
	   CASE WHEN SiteNumber IS NULL THEN 'NULL' ELSE 'NOT NULL' END, status

...