Hi,
I'm trying to do a search of the type:
"show me all assets where:
the asset's field X = "foo" AND
(the asset's field Y is either "bar" OR "baz")
originally my code looked like:
// first metadata fields , 'objCompositeKey'
constraint1 = new MBSearchConstraint();
meta1 = new MBMetadata();
meta1.mID = objCompositeKeyGuid;
meta1.mValue = objCompositeKey;
constraint1.mMetadata = meta1;
constraint1.mSearchOperator = "Equality";
constraint1.mBooleanOperator = MBBooleanOperator.AND;
constraints.Add(constraint1);
// second metadata field, amWingFilename, looking for value ".3dm" or ".3ds"
constraint = new MBSearchConstraint();
meta = new MBMetadata();
meta.IsMultipleValue = true;
meta.mID = amWingFilenameGuid;
meta.mValues = new String[2]{".3dm", ".3ds"};
constraint.mMetadata = meta;
constraint.mSearchOperator = "Equality";
constraint.mBooleanOperator = MBBooleanOperator.AND;
constraints.Add(constraint);
Somehow I got it into my head that using an array of values like I did was the correct way to search for multiple values matching a field (the "or" part)
This doesn't work:
MBException: Error in CMBVariant:

perator MB:

ataValuePtr(). Type of the variant not specified
and i'm pretty sure this approach is wrong.
I read in the API documentation that constrainst can be nested, which seems like the right approach, but I don't see in the docs, or in the object auto-completion, how to do this.
Can someone explain to me how to do these kinds of searches?
thanks for your time.
For one thing, the amWingFilename isn't a multipleValue field,