Friday 15 January 2010

mysql - Extracting a part of table name and printing it on console -



mysql - Extracting a part of table name and printing it on console -

how extract part of table name in oracle 11g , print on console?

for illustration have tables in next manner:

table name: college_football_players attributes name , age. table name: college_volleyball_players attributes name , age.

now need print age , name of players playing both games repetition(if any).

the code used is:

select * college_football_players union college_volleyball_players;

in add-on need add together game played player should extracted name of table. there possible way without adding column tables?

thanks in advance.

select f.*, 'football' game college_football_players f union select v.*, 'volleyball' college_volleyball_players v;

mysql oracle oracle11g oracle10g sqlplus

No comments:

Post a Comment