Solved

Simple query pareto question

Posted on 2006-11-08
5
281 Views
Last Modified: 2012-05-05
I have two tables, 1 column each.  one has the values:

A
B
C

the other has the values:

1
2
3

they are unrelated.  i want the output to be 1 columns that looks like:

A 1
A 2
A 3
B 1
B 2
B 3
C 1
C 2
C 3

how can i do this? thanks
0
Comment
Question by:bdietz
  • 3
5 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 250 total points
ID: 17901169
select colA, colB
from tableA cross join TableB
0
 
LVL 1

Expert Comment

by:Aristo
ID: 17901693
select * from
table1, table2
0
 
LVL 32

Expert Comment

by:awking00
ID: 17901716
select letters.col1||nums.col1
from letters, nums
order by letters.col1;
0
 
LVL 32

Expert Comment

by:awking00
ID: 17901732
I think your acceptance was a little quick, since it returns two columns and not one as in your question.
0
 
LVL 32

Expert Comment

by:awking00
ID: 17901743
p.s. It also doesn't sort them in your desired order.
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Read about achieving the basic levels of HRIS security in the workplace.
Shadow IT is coming out of the shadows as more businesses are choosing cloud-based applications. It is now a multi-cloud world for most organizations. Simultaneously, most businesses have yet to consolidate with one cloud provider or define an offic…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

896 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now