Support the ongoing development of Laravel.io →
posted 8 years ago
Eloquent
Last updated 2 years ago.
0

Have you considered to create a view and then query the view? Should be much faster

http://www.postgresql.org/docs/9.2/static/sql-createview.html

0

yep do a view

0

Also, how's your table in terms of indexes?

Don't go indexing blindly, i've seen people just go and non cluster every column in hopes of making a query more efficient. But clusters have their drawbacks that should been overcome by the advantages they bring for the desired scenarios.

Postgres has something called "execution plans" : http://www.postgresql.org/docs/9.2/static/sql-explain.html

I've never used that one in postgres. but in MsSql and MySql I have used them and they are worth considering.

0

Sign in to participate in this thread!

Eventy

Your banner here too?

Donny5300 donny5300 Joined 3 May 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.