Project-Path-of-Exile-Wiki / wiki

A repository for Project Path of Exile Wiki
https://www.poewiki.net/
GNU General Public License v3.0
51 stars 6 forks source link

There should be an easy way to query the most recent version of a map #125

Closed mark-phaedrus closed 1 year ago

mark-phaedrus commented 2 years ago

In order to put together some Cargo tables for maps, I need a way to query only the most recent version of a given map. Oddly, there doesn't appear to be a good way to do that. Filtering on drop_enabled=0 does too much -- in some cases, the most recent version of the map isn't drop-enabled either. In theory, it looks like I could look for the map with a given name with the highest items.release_version value; but that seems hellish to do from a Cargo query. (And there doesn't seem to be a way to do it using {{Item table}} either.)

angelic-knight commented 2 years ago

Are you asking for maps in the most recent map series, or the most recently released version of each map (including Perandus Manor and maps that are out of the rotation)?

mark-phaedrus commented 2 years ago

Well, we'll need both, I'm sure. :) But I was specifically asking about the most recently released version of each map. If I have that, I can further filter with properties like is_drop_disabled and removal_version to check for things like The Perandus Manor.

acbeaumo commented 2 years ago

It should be possible to get the most recent version of a map by joining the query with the map_series table.

acbeaumo commented 1 year ago

I left this issue open for a while in case anyone wanted to discuss it further. I'm closing it now, since there is already a way to query the most recent version of a map by joining on the map_series table and ordering by map_series.ordinal DESC.