Follow us: Connect on YouTube Connect on YouTube Connect on YouTube

Pages

Sunday, 3 April 2016

Operators in PL/SQL

Arithmetic Operators
          *, /, +, -, ^
Comparison Operators
          >, < , >= , <= , <> , = , IN , BETWEEN, LIKE, IS
Logical Operators
          NOT, AND, OR
Other Operators

          .. , **, ||
Share this article :

2 comments:

  1. Hi There,


    Fully agree on Operators in PL/SQL. We’re seeing a lot of projects tackle big complex problems but few seem to have taken into consideration and in particular reasons to adopt.

    can you please help me out on this.

    The error what I am getting is (ORA-00904) highlighted at the end with RED color.
    Below is the process what followed.
    I think the issue with build query with QUOTES(').

    By the way do you have any YouTube videos, would love to watch it. I would like to connect you on LinkedIn, great to have experts like you in my connection (In case, if you don’t have any issues).


    Best Regards,
    Banu

    ReplyDelete
  2. Hello There,

    11/10!! Your blog is such a complete read. I like your approach with Operators in PL/SQL . Clearly, you wrote it to make learning a cake walk for me.

    there are TWO tables as below
    USER_DATA_B
    1>USER_ID
    2>CUST_ID
    3>CREATE_DT
    4>LOG_ID

    USER_LOGON_ID_CHANGE_B
    1> ID
    2>USER_ID
    3>NEW_LOGON_ID
    4>OLD_LOGON_ID
    5>OLD_CREATE_DT
    6>ROW_CREATE_DT

    the existing query to show the details in UI is as below

    SELECT USER_ID,OLD_CREATE_DT,ROW_CREATE_DT FROM USER_LOGON_ID_CHANGE_B WHERE OLD_LOGON_ID=?
    AND NEW_LOGON_ID IS NULL
    UNION
    SELECT USER_ID,CREATE_DT,NULL FROM USER_DATA_B WHERE LOG_ID=?
    ORDER BY OLD_CREATE_DT

    Now, my requirement is to join the above query with the following table
    CUSTOMER_ATTRIBUTE_B
    1>CUST_ID
    2> ATTRIBUTE_TYPE_CD
    3>ATTRIBUTE_DATA

    The new query output should be below
    1>USER_ID
    2>OLD_CREATE_DT,
    3>ROW_CREATE_DT
    4> ATTRIBUTE_TYPE_CD
    5>ATTRIBUTE_DATA

    Great effort, I wish I saw it earlier. Would have saved my day :)

    Thank you,
    Preethi.

    ReplyDelete