DBA Geral (instalação, configuração do banco, scripts do Sql*Plus, shell scripts, batch scripts, etc...)
Rafael Bertoco
Rank: Estagiário Júnior
Posts: 1 Joined: Wed, 17 Aug 2016 9:41 am
Wed, 17 Aug 2016 9:47 am
Good morning, friends.
I need to create a view in Oracle, which contains the table in Select Dynamics. Example: Select * from usina2016;
This 2016 from the end of the table name, I have to pick up from the sysdate the current year and concatenate with the plant.
Do you know how to help me?
souldeath
Rank: Programador Sênior
Posts: 48 Joined: Wed, 25 Aug 2010 9:39 am
Location: Limeira
Wed, 31 Aug 2016 1:35 pm
rafael bertooc , complementing the response of stcoutinho , you could put the dynamic SQL logic in a function that returns a cursor and the view you put the select command by calling the result of this FUNCTION.
Users browsing this forum: No registered users and 20 guests