Quantcast
Channel: Teradata Forums - Database
Viewing all articles
Browse latest Browse all 14773

Join two tables using like statement - response (4) by khatriprad

$
0
0

Hi Caka,
In order to join,you can use POSITION function to match the partial Strings in the two column 

select * from Table1 T1 left join Table2 T2
on (T1.ColB = T2.ColB  AND POSITION(TRIM(T1.ColA) IN TRIM(T2.ColA))>0)
where T2.ColC = 0;

There are other ways to accomplish the same as well For example:use of substring functions  

 


Viewing all articles
Browse latest Browse all 14773

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>