Avatar of JGH5
JGH5
Flag for United States of America asked on

Oracle Roll Up Syntax Error

I am trying to perform a Roll Up in Toad for Oracle to produce results like this:

BEACH_NAMES    BEACH_NAMES_CNT
- ----------
0        103
1         87
2         71
3         52
4         88
5        113
6        163
7        412
8        537
9        592
        2218

Using this Query:

SELECT SUBSTR(BEACH_NAMES,1,1) BEACH_NAMES, COUNT(*) BEACH_NAMES_CNT FROM  BEACH_SEC_INFO GROUP BY ROLLUP SUBSTR(BEACH_NAMES,1,1));

I am getting a syntax error, I spend most of my time in SQL Server.  I have access to multiple instances and perhaps I need to include DBO?
Oracle Database

Avatar of undefined
Last Comment
MikeOM_DBA

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
MikeOM_DBA

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes