select with "group by" and "having"
Posted: Wed Dec 26, 2007 1:05 pm
Hello,
I am a oracle database developer. Today I first tried "OpenOffice Base". I have a ods-spreadsheet with a list of persons (first name, last name , address, telephon number, email,...). I created a Base Database with my spreadsheet as existing database. Then I opened the SQL-Editor and tried following statement:
But this doesn't work. The second column "quantity" is always empty. I would like to find all duplicate email. With "Oracle-SQL" I would write the query as I show before. Is there a possibility to find out all duplicate email in "OpenOffice Base"
For me it seems that "group by" doesn't work in "OpenOffice Base". The query
have the same result as
I tried all these queries with Open Office Base 2.2 and 2.3
~Bernd
I am a oracle database developer. Today I first tried "OpenOffice Base". I have a ods-spreadsheet with a list of persons (first name, last name , address, telephon number, email,...). I created a Base Database with my spreadsheet as existing database. Then I opened the SQL-Editor and tried following statement:
Code: Select all
select email, count(*) as quantity
from person
group by email
having count(*) > 1
For me it seems that "group by" doesn't work in "OpenOffice Base". The query
Code: Select all
select last_name
from person
group by last_name
Code: Select all
select last_name
from person
~Bernd