26 if ( pkAttributes.isEmpty() )
28 return QString::number( feature.
id() );
32 QgsAttributeList::const_iterator it = pkAttributes.constBegin();
33 if ( it != pkAttributes.constEnd() )
35 pkValues.append( feature.
attribute( *it ).toString() );
44 if ( pkAttributes.isEmpty() )
47 for (
const QString &serverFid : serverFids )
49 fids.insert( serverFid.toLongLong() );
52 return featureRequest;
56 for (
const QString &serverFid : serverFids )
61 if ( expList.count() == 1 )
67 QString fullExpression;
68 for (
const QString &exp : qgis::as_const( expList ) )
70 if ( !fullExpression.isEmpty() )
72 fullExpression.append( QStringLiteral(
" OR " ) );
74 fullExpression.append( QStringLiteral(
"( " ) );
75 fullExpression.append( exp );
76 fullExpression.append( QStringLiteral(
" )" ) );
81 return featureRequest;
88 if ( pkAttributes.isEmpty() )
95 QString expressionString;
96 QStringList pkValues = serverFid.split(
pkSeparator() );
97 int pkExprSize = std::min( pkAttributes.size(), pkValues.size() );
98 for (
int i = 0; i < pkExprSize; ++i )
102 expressionString.append( QStringLiteral(
" AND " ) );
105 QString fieldName = fields[ pkAttributes.at( i ) ].name();
109 return expressionString;
114 return QStringLiteral(
"@@" );