1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

Getting a "Create View" statement from metadata

Discussion in 'General' started by nightrider43, Nov 22, 2010.

  1. nightrider43

    nightrider43 Active Member

    Likes Received:
    Trophy Points:
    I'm trying to get the entire text of a Create View command. I need to obtain data from the word "Create" thru the end of the Create View statement. Get the data of a Cretae View from the SELECT word is easy.

    I suppose I can't use SQL Plus commands 'cause I need to obtain data via the execution of a SQL command from a Delphi application program(in the same way it would be a C++, C#, java, VB, etc program).

    I explain: The idea is compare metadata from an Oracle database with the metadata of a MS SQL Server database and left them with the same metada, e.g., views, indexes, primary keys, foreign keys, etc.

    Again, I suppose it isn't possible to use SQL Plus commands in this operation 'cause I need the data in an application program.

    I think it's possible because Toad For Oracle from Quest Software returns the entire Create View statements.

    Greetings from Sao Paulo - Brazil
  2. rajavu

    rajavu Forum Guru

    Likes Received:
    Trophy Points:
    @ Bangalore , India
    Why can't you try the DBMS_METADATA.GET_DDL ?

    Also, there is no different of trying the same from SQLPLUS or other tools for the same purpose.