Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
satish.gorijala
Posting Yak Master
182 Posts |
Posted - 2009-04-13 : 02:09:09
|
| Hi, i have one requirement.Table1Col1 Col2234 erekk450 rerere678 roroorTable2Col1 Col2234-45 rtr456-90 rtr234-56 rrl678-76 hhhNow i want to retive the data as For the col1 in Table1 contains the data in Tabl2 in Col1.i.e if i took 234 From table1, i want to know that what are the rows present in table2 starting with 234?OutputCol1 Col2234-45 rtr234-56 rrlG. Satish |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2009-04-13 : 02:40:39
|
| select * from table2 as t2 inner join table1 as t1 on t2.col2 like t1.col1+'%'where t1.col1=234MadhivananFailing to plan is Planning to fail |
 |
|
|
|
|
|