Click here to Skip to main content
15,889,808 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all,

I don't know how to ask you, but i will explain you with a step by step and show you what I want.

I have a table that store like data below :
No Type
-------------------------------
1 1.Micro 1-1,500 1
2 2.Micro 1,501-2,000
3 3.Micro 2,001-3,000
4 4.Small 3,001-5,000
5 5.Small 5,001-10,000
6 6.Medium 10,001-30,000
7 7.SME 30,001-100,000


and one more table
Name
----------
0203
0204
0206
0303
and data I want is like this:
Name Type
----------------------------------
203 1.Micro 1-1,500
203 2.Micro 1,501-2,000
203 3.Micro 2,001-3,000
203 4.Small 3,001-5,000
203 5.Small 5,001-10,000
203 6.Medium 10,001-30,000
203 7.SME 30,001-100,000
204 1.Micro 1-1,500
204 2.Micro 1,501-2,000
204 3.Micro 2,001-3,000
204 4.Small 3,001-5,000
204 5.Small 5,001-10,000
204 6.Medium 10,001-30,000
204 7.SME 30,001-100,000
206 1.Micro 1-1,500
206 2.Micro 1,501-2,000
206 3.Micro 2,001-3,000
206 4.Small 3,001-5,000
206 5.Small 5,001-10,000
206 6.Medium 10,001-30,000
206 7.SME 30,001-100,000
303 1.Micro 1-1,500
303 2.Micro 1,501-2,000
303 3.Micro 2,001-3,000
303 4.Small 3,001-5,000
303 5.Small 5,001-10,000
303 6.Medium 10,001-30,000
303 7.SME 30,001-100,000



any body can help me please..........:(
Posted

Try this

SQL
SELECT  Name,  Type
     FROM FirstTable, Second Table;

The concept is called as CROSS JOIN.
Go through this link CROSS JOIN Example
 
Share this answer
 
v2
Great it works correctly and show what I want.
Thanks you very much pradiprenushe
 
Share this answer
 
Comments
Maciej Los 23-Jul-14 4:24am    
Not an answer. Please, delete it to avoid down-voting. To post comment, use "Have a question or comment" widget.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900