Hans Bakker wrote:
The new feature explosion is now most implemented and shows , in speed
as a big improvement. However....
Part of the problem to select the respective variant is now done after
the features are selected. Because of the datamodel it takes a long time
to find the applicable variant if there are many.
this what i do now:
for every 'variant' in the ProductAssoc entity i check if the related
variant product has all the selected features as 'standard' in the
ProductFeatureAppl entity.

this however can take a long time....

How can we improve this?

If we could add a field to the ProductAssoc entity called
'standardFeatures' and we copy in here all the standard
productFeatureId's of a related variant separated with a '|' sign when
the features are updated, then we could find the related variant with
one read......
This copy can be done with an eca...

what is the opinion of the community?
I have this problem on a site we've been developing for a while. In my situation I want to actually show all the remaining valid features when one particular feature is selected as well as showing the final SKU when all features are selected.

I do the first by constructing a pretty ridiculous graph that I keep in memory on the server to track feature exclusion. Its a hack but I can afford to throw memory at the problem and there are few enough products that it works. Not a general solution though, the graph needs to be turned into some kind of distilled feature product relationship table.

I do the second by sorting the feature keys, concatenating them and then using that into a lookup of the actual variant. Probably kind of gross but it does the job.

--
Ean Schuessler, CTO
[EMAIL PROTECTED]
214-720-0700 x 315
Brainfood, Inc.
http://www.brainfood.com

Reply via email to