CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2005
    Posts
    2

    Question very urgent plsssssss.......

    DECODE(SIGN(TEST_RAG_BTNET.R-(0.2*50)),-1, '<p style="BACKGROUND-COLOR: GREEN"> ' || TEST_RAG_BTNET.R || ' </p>',(DECODE(SIGN(TEST_RAG_BTNET.R-(0.5*50)),-1,'<p style="BACKGROUND-COLOR: RED"> ' || TEST_RAG_BTNET.R || ' </p>','<p style="BACKGROUND-COLOR:#FFFF00"> ' || TEST_RAG_BTNET.R || ' </p>')))


    TEST_RAG_BTNET- table name

    R is the column name

    0.2 *50 is to take 20% of 50

    have to write a decode statement in which.. if the data is greter than 50% data should be in red color..and if grater tahn 80 .. blue and less tahn 50 then green

    this happens perfectly..

    but if the data is dot 50% .. it shows red
    but i want it in green
    this is my problem

  2. #2
    Join Date
    Jan 2004
    Location
    San Diego
    Posts
    148

    Re: very urgent plsssssss.......

    It appears you have set things up so your default color is red. So, you can try adding a special condition where if exactly 50% set color to green, or amend you comparison for green to be a less than or equal comparison.
    Death is life's special way of telling you you're fired.

    For I do not seek to understand in order to believe, but I believe in order to understand. For I believe this: unless I believe, I will not understand. - Anselm of Canterbury (1033–1109)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured