I am trying to construct a single SQL statement that returns unique, non-null values from multiple columns all located in the same table.
SELECT distinct tb
try something like SubQuery:
SubQuery
SELECT derivedtable.NewColumn FROM ( SELECT code_1 as NewColumn FROM tbl_data UNION SELECT code_2 as NewColumn FROM tbl_data ) derivedtable WHERE derivedtable.NewColumn IS NOT NULL
The UNION already returns DISTINCT values from the combined query.
UNION