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 |
|
Bertrand82
Starting Member
7 Posts |
Posted - 2012-10-29 : 09:48:00
|
| Hi,I have a table [tablefruit] with column FruitsFruits Apple Banana OrangeI have another table [Fruitexpl] with column Fruit and FruitID Fruit FruitIDApple APPBanana BANOrange ORAI would like to create a Query which Extract all the data from [tablefruit] and transform the data to the FruitID data according to table [Fruitexpl]What will that statement look like?Br Bertrand |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2012-10-29 : 09:56:21
|
| [code]SELECT FruitIDFROM Fruitexpl feINNER JOIN tablefruit fON f.Fruits = fe.Fruit[/code]------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
anil_p
Starting Member
3 Posts |
Posted - 2012-10-29 : 10:03:06
|
| SELECT b.FruitID FROM Fruitexpl AS aINNER JOIN tablefruit AS b ON a.Fruits =b.Fruit |
 |
|
|
|
|
|