4 Replies Latest reply: Feb 4, 2013 2:59 PM by 988998 RSS

    Hide rows which are null in report

    988998
      Hi All,

      I have a requirement where the report should display only the rows of the column if it has a value and should not display the rows if it has a null value .I have been trying with the Sql but couldnt find any result.I dont know if there is a way through which i can hide the rows which has null in the template.

      Please let me know about this.

      Thanks in Advance!!!
        • 1. Re: Hide rows which are null in report
          Avinash_Varma
          say IND is the column you are checking for null and you dont want the rows where IND IS null

          you can have the code like below

          G_1 is the loop and IND is the checking column

          <?for-each:G_1[IND!='']?><?IND?><?EMP_ID?><?AMOUNT?><?end for-each?>
          • 2. Re: Hide rows which are null in report
            988998
            Hi Avinash,

            Thanks for the quick reply.

            I am actually confused with the code you have sent .In the code i see there are 2 columns AMOUNT and emp_id apart from Ind.I want to know that are you trying to give me an example with two columns or only one as i have only one column .My column is customers_added for which i want to hide the rows which are null or blank.

            Thanks in Advance!!!

            Edited by: user12263415 on Feb 4, 2013 7:52 AM

            Edited by: user12263415 on Feb 4, 2013 7:55 AM
            • 3. Re: Hide rows which are null in report
              Avinash_Varma
              my intention in showing that sample like that is to just show how you can form code you can keep what ever the column needed between the for loop.

              <?for-each:G_1[IND!='']?> you can keep any thing here <?end for-each?>

              you can edit your for each loop code like above by keeping condition as i shown above . if you want to add multiple conditions for ind you can try like below

              <?for-each:G_1[IND!='' or IND='0']?>

              if you still have confusion you can try like this also

              <?for-each:G_1?><?if:IND!=''?>YOUR COLUMNS <?end if?><?end for-each?>
              • 4. Re: Hide rows which are null in report
                988998
                Thanks Avinash for the reply

                I will check with my code in the report and let you know whether it worked or not.

                The code worked for me thanks once again for the help!!!

                Edited by: user12263415 on Feb 4, 2013 12:59 PM