user_id | ym | a_score | b_score |
testid | 201201 | 1000 | 2000 |
testid | 201202 | 500 | 1500 |
testid | 201203 | 300 | 700 |
testid | 201204 | 300 | 400 |
testid | 201205 | 400 | 600 |
testid | 201206 | 1500 | 300 |
testid | 201207 | 200 | 1000 |
testid | 201208 | 300 | 700 |
testid | 201209 | 400 | 800 |
testid | 201210 | 500 | 900 |
testid | 201211 | 600 | 1000 |
testid | 201212 | 1000 | 2000 |
뷰 테이블은 다음과 같이 만드시면 되용..
CREATE OR REPLACE FORCE VIEW A_TABLE(user_id, reg_date, a_score) AS
SELECT * FROM A_TABLE_201201
UNION ALL
SELECT * FROM A_TABLE_201202
....
UNION ALL
SELECT * FROM A_TABLE_201212
CREATE OR REPLACE FORCE VIEW B_TABLE(user_id, reg_date, a_score) AS
SELECT * FROM B_TABLE_201201
UNION ALL
SELECT * FROM B_TABLE_201202
....
UNION ALL
SELECT * FROM B_TABLE_201212