3
votes
Accepted
sum() of aggregate count()?
ROLLUP
select count(regexp_replace( email_id , '^[^@]+@','')) as count, regexp_replace( email_id , '^[^@]+@','') as domain from logins
where last_login between '2024-08-06' and '2024-09-06'
group ...
2
votes
Copy where clause on both joined tabled, equivalence
The answer is yes, the queries are the same due to the use of equivalence classes.
It works only for equality (=42) but not (yet) for more complicated cases (inequality, IN...).
Reference: Postgres ...
1
vote
"Wrong affix file formate for flag" while loading dictionaries from LibreOffice in PostgreSQL 9.3
I had a lot of trouble implementing the Dutch ispell/hunspell dictionaries. Similar complaints about affix flags.
Problem – at least for the more recent Dutch ones that are provided by OpenTaal – was ...
1
vote
sum() of aggregate count()?
No need to use regular expressions at all (the code below can be found on the fiddle here:
To resolve this, I did the following:
CREATE TABLE logins
(
email_id TEXT NOT NULL
);
and populate:
INSERT ...
1
vote
PostgreSQL: Is there any way to differentiate an actual Disk I/O from system cache hit?
Since the system cache belongs to the system, you mostly need to use system tools to assess it. vmstat being the preeminent one for me. Unless you have a lot of non-PostgreSQL related things also ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
postgresql × 17164performance × 1330
postgresql-performance × 1078
index × 902
database-design × 782
query-performance × 669
replication × 547
postgresql-9.3 × 494
postgresql-9.6 × 445
postgresql-9.4 × 419
json × 407
plpgsql × 396
join × 387
optimization × 375
trigger × 365
backup × 358
functions × 352
psql × 325
amazon-rds × 310
postgresql-10 × 306
query × 295
postgresql-9.5 × 294
permissions × 287
mysql × 285
aggregate × 271