We have moved to Github. Please open tickets there.

Opened 11 months ago

Last modified 11 months ago

#4595 new Enhancement

Optimizing ORDER BY by removing unnecessary CASTing of types

Reported by: srokap Owned by:
Priority: normal Milestone: Needs Review
Component: Core Version: 1.8
Severity: minor Keywords:
Cc: brett@… Difficulty:

Description

Previously discuissed here: https://docs.google.com/document/d/1NrxIj4YOTjNbeXDGW3tpz2lNvaRwL2NDPBNd7TgRfFk/edit?disco=AAAAAEr6svk

Me: CAST in ORDER BY statement seems to force filesorting anyway. Better to allow different metadata types than force only text values

(...)

Evan: I think we ought to push metastring values into the metadata table, and leave metastrings for denormalizing the keys. Then, on metadata save, we would save both the int value and the string value in two columns. I have this clear in my mind but I'm not sure if my explanation is getting it across.

Me: I had very similar solution in mind! It solves also problem with selecting entities without particular value - it will be possible now. I'm for this idea.

So we want in this ticket to

  • move VALUES if metadata to metadata table instead of utilizing metastrings
  • store integer value of the field in separate column and use it for ordering instead of casting text to int

Change History (1)

comment:1 Changed 11 months ago by srokap

  • Type changed from Defect to Enhancement
Note: See TracTickets for help on using tickets.