Timeline for Optimizing a query by adding an index
Current License: CC BY-SA 4.0
12 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jan 7, 2020 at 22:25 | history | edited | CommunityBot |
added [postgresql-performance] to 571 questions - Shog9 (Id=1924)
|
|
Oct 22, 2019 at 7:19 | history | edited | Corentin S. | CC BY-SA 4.0 |
add table sizes
|
Oct 22, 2019 at 7:13 | comment | added | Corentin S. |
@Ronaldo I don't think I'm working with views, accounts_companyview is the name of the table. Or maybe I misunderstood something?
|
|
Oct 22, 2019 at 6:47 | history | edited | Corentin S. | CC BY-SA 4.0 |
added 138 characters in body
|
Oct 21, 2019 at 20:03 | answer | added | jjanes | timeline score: 1 | |
Oct 21, 2019 at 19:51 | answer | added | Laurenz Albe | timeline score: 1 | |
Oct 21, 2019 at 17:55 | comment | added | jjanes | In PostgreSQL, that is spelled track_io_timing. | |
Oct 21, 2019 at 17:16 | comment | added | Ronaldo | Sorry for my lack of attention, you're right. But I believe my point about the view having code that was meant to attend another query being the reason of your scans still stands. I don't believe Postgres differs from SQL Server on that point. Was the view created for this specific query? | |
Oct 21, 2019 at 17:07 | comment | added | Erwin Brandstetter | @Ronaldo: You are talking MS SQL Server, but this is about Postgres. | |
Oct 21, 2019 at 17:03 | comment | added | Ronaldo |
Could you please enable IO statistics: SET STATISTICS IO ON; and post the message from SSMS after running your query with it enabled? And since you're working with views it's possible that something on the view code (that was made for a different purpose ohter than the result of this specific query) is causing the scan.
|
|
Oct 21, 2019 at 16:10 | review | First posts | |||
Oct 21, 2019 at 16:14 | |||||
Oct 21, 2019 at 16:07 | history | asked | Corentin S. | CC BY-SA 4.0 |