Inserted & deleted table

  • Hi,

    I have confused with below query . Could anyone please help me....

    Client have sent me one view query , there he put one condition----

    create and replace view vu_name(column1, column2,------) from table name

    where isnull(table name.deleted).

    I want to know what does that condition means "where isnull(table name.deleted)".

    Thanks in advance---

  • That's Oracle code, not SQL Server. Maybe ask on an Oracle forum?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • Hi Gail,

    Thanks for the reply....

    Actually I don't know much about the Oracle.

    Could you please tell me here deleted is the column name or table name, because in SQL SERVER we use inserted and deleted with the trigger not with the view, so that I am confused.

    Could you please help me on this....

  • Hi Gail,

    Thanks for the reply....

    Actually I don't know much about the Oracle.

    Could you please tell me here deleted is the column name or table name, because in SQL SERVER we use inserted and deleted with the trigger not with the view, so that I am confused.

    Could you please help me on this....

  • arooj300 (6/10/2013)


    Actually I don't know much about the Oracle.

    Could you please tell me here deleted is the column name or table name, because in SQL SERVER we use inserted and deleted with the trigger not with the view, so that I am confused.

    That's Oracle code, pl-sql.

    It is not SQL Server code, it's not valid and won't run. In SQL Server, inserted and deleted are tables visible in a trigger.

    If you want an explanation as to how the Oracle view that you posted will run or is supposed to do, ask on an Oracle forum.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • your code doesnt looks like a SQL code and as Gila said its an pl sql code so its good if you asked it on some Oracle forum

    _______________________________________________________________
    To get quick answer follow this link:
    http://www.sqlservercentral.com/articles/Best+Practices/61537/

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply