I am using SQL2000 and I would like to join two table together based on their positions
For example consider the following 2 tables:
table1
-------
name
-
Absolutely. Use the following query but make sure that (order by) clause uses the same columns the order of rows will change which you dont want.
select
(
row_number() over(order by name) rno, * from Table1
) A
(
row_number() over(order by name) rno, * from Table2
) B
JOIN A.rno=B.rno
order by clause can be modified according to user linkings
The above query produces unique row_numbers for each row, which an be joined with row_numbers of the other table