Pages

ORA S’ Corner : ORA-00937 not a single-group group function


                                                       


Recently, I came across issue when trying to include both a group function and individual column expression.

Cause: A SELECT list cannot include both a group function and an individual column expression, unless the individual column expression is included in a GROUP BY clause.

Example: 






















Workaround:

You can Drop either the group function or the column expression from the SELECT list or else add GROUP BY clause that includes all individual column expressions listed.


Walkthrough ORACLE 11g: Configuring for Recoverability

In the previous article “Shortcuts to losing your dataexplained why organizations expect zero data loss and importance of backup solutions. Not only for data protection, Backups also used for data preservation and historical retention as well.  However the main purpose of backup and recovery is to restore a failed database.


There are two types of Archive log modes ;

  •  * NOARCHIVELOG mode
  •  * ARCHIEVELOG mode 


NOARCHIVELOG is default mode and database runs normally, in this event you have to shut down the database in order to take the backup also which backups and recover to the point of the last backup only. Therefore before take the backup configure your database in ARCHIVELOG mode, because it allows backup the database while it is open. Also if backups are taken in ARCHIVELOG mode can be used to recover a database to past point in time.


Walkthrough Practice – Configuring ARCHIVELOG mode

 

1. Setup the Environment


SET ORACLE_SID=orcl

2. How to determine the archive mode

SQL> archive log list