Sean Dawson
Sean Dawson

Reputation: 1

QGIS Print Layout - How to Clear Cache for saved layouts?

I have an issue in my project which is causing me a lot of frustration. There seems to be some sort of cache or metadata or historical hidden thing that is causing me a lot of issues.

I have a layer which I am using as a coverage layer for an atlas in print composer.

The layer has a few columns for attributes and data of course, let's call it "NAME", "DATE", and "YEAR".

Now when i create a legend in the layout, and use an expression to pull data from the attribute table using [% "DATE" %] it doesn't pull the data from the "DATE" column, but rather it pulls the data from the "YEAR" column for some reason.

If i go into the layer properties and rename the "DATE" field to something like "DATE_NEW" then the legend expression of [% "DATE_NEW" %] pulls the proper data from the column "DATE_NEW". However if i use the expression [% "DATE" %] it still pulls the wrong data from the "YEAR" column, even though there is no column currently in the layer named "DATE". I Would rather not have my column permanently named as "DATE_NEW" even though the issue would be resolved temporarily.

Is this some sort of cache issue where it's remembering old data/attributes?

I have troubleshooted a bit by:

  1. Re-creating the atlas coverage layer from scratch, creating a new feature and manually recreating all of the columns with the same names and inputting the data (no copy pasting features or refactoring the original layer or loading attributes) and the issue still persists.

  2. Creating a new project and loading the same coverage layer, loading the layout as a template, issue still occurs.

  3. Creating a new project and loading the same coverage layer, creating a new layout form scratch, issue does not occur.

This leads me to believe that the error/old data whatever is causing this, is tied to the layout that i have saved and not the layer i am using for the atlas coverage.

I would really rather not re-create the entire layout from scratch (I only recreated a test layout with a new map and legend, not the entire thing)

Or is the layout somehow just corrupted?

Upvotes: 0

Views: 40

Answers (0)

Related Questions