Problem/Motivation
This is follow up to #2429447: Use data table as views base table, if available. where uid_current filter was missed.
According to #2429447: Use data table as views base table, if available.:
Don't expose fields on the base table, if they are also available on the data table.
which the uid_current filter violates at present, but there is more to it. When building complex views involving multiple relationships using this filter prevents some configurations to be achievable from UI because it pulls in the users table with the INNER filtering out required rows and there is no way to work around it using View UI.
Proposed resolution
Move filter declaration from users table to users_field_data.
Issue fork drupal-3630222
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
rosk0Tests should pass now - forgot that views are storing table names in config as well.
My huge views SQL query lost two of nine joins after applying the patch, but most importantly, it now selects correct number of rows from the database!
Comment #4
smustgrave commentedThis seems like it could be a breaking change, may need to do a deprecation of some kind