Numeric cell with 0 not null I have the following query (in a Oracle Database):

          SELECT SUM (CANTITATE)
             FROM ANEXA2A_TABEL2_ROWS
            WHERE TIP_ACTIUNE = 'COLECTATE'
                  AND TIP_AMB = 'STICLA'
                  AND COD LIKE '%*'


The problem is that if I don't have any row with * in COD, the result is a empty cell and I want it 0. How can I do that?

Thanks!
Use NVL().

 SELECT NVL(SUM(CANTITATE),0)
             FROM ANEXA2A_TABEL2_ROWS
            WHERE TIP_ACTIUNE = 'COLECTATE'
                  AND TIP_AMB = 'STICLA'
                  AND COD LIKE '%*';


That'll make the SUM() function return 0 if it would ordinarily return NULL.