Skip to content
Permalink
Browse files

Fixes #17450 by correctly setting the join info ordered list

  • Loading branch information
pblottiere committed Nov 15, 2017
1 parent b058df7 commit 333a8e9e9464f4901d185a410be64fcc2b1c2c9c
Showing with 3 additions and 4 deletions.
  1. +3 −4 src/core/qgsvectorlayerfeatureiterator.cpp
@@ -722,12 +722,11 @@ void QgsVectorLayerFeatureIterator::createOrderedJoinList()
int joinField = mOrderedJoinInfoList.at( i ).joinField;

QgsAttributeList attributes = mOrderedJoinInfoList.at( i ).attributes;
QgsAttributeList::const_iterator attIt = attributes.constBegin();
for ( ; attIt != attributes.constEnd(); ++attIt )
for ( int n = 0; n < attributes.size(); n++ )
{
if ( *attIt != joinField )
if ( n != joinField )
{
resolvedFields.insert( joinField < *attIt ? *attIt + offset - 1 : *attIt + offset );
resolvedFields.insert( joinField < n ? n + offset - 1 : n + offset );
}
}
}

0 comments on commit 333a8e9

Please sign in to comment.
You can’t perform that action at this time.