QuestionQ116Verified/Using Single-Row and Aggregate FunctionsCopy linkReport a problemAsk AstroTutorSave questionWhich two statements correctly describe the COUNT function?Choose twoACOUNT (*) returns the number of rows in a table including duplicate rows and rows containing NULLs in any column.BCOUNT (DISTINCT inv_amt) returns the number of rows excluding rows containing duplicates and NULLs in the INV_AMT column.CA SELECT statement using the COUNT function with a DISTINCT keyword cannot have a WHERE clause.DIt can only be used for NUMBER data types.ECOUNT (inv_amt) returns the number of rows in a table including rows with NULL in the INV_AMT column.Show AnswerAnswerExplanationCOUNT(*) returns the total number of rows, including duplicates and rows with null values. COUNT(DISTINCT inv_amt) returns the count of unique, non-null INV_AMT values. Oracle documents that COUNT(expr) counts only rows for which the expression is not null, while COUNT(*) includes duplicates and nulls.Learn moreOracle Database SQL Language Reference — COUNTShow comments0Show commentsCommunity DiscussionNo comments yet. Be the first to start the discussion!
Community Discussion