Sub query with not equal Sub query with not equal  

table_1


col1
SV0362
RU0177CSPG
NO0124CSPG
VN3582
AT9923CSPG
BZ0324
PE0309
AS4293EXPT
ML0331OMKT

table 2

colA
OO56128665
OO56128665
OO56128665
OO56128665
US0170
US0170
US0170
US0170
US0170
US0170
US0170
US0170
US0170
US0170
OO56128665
OO56128665


I want to compare col1 of table1 with colA of table 2 and return the values which are not qual

something like this

select * from table1  where col1 &lt;> (select colA from table_2 a,table1 b where  b.col1=a.colA)

but this would give single row returns more than one subquery
You just need to use NOT IN

SELECT * FROM table1 WHERE col1 NOT IN (SELECT colA FROM table_2)