You are here:  » Importing only certain items from a feed

Support Forum



Importing only certain items from a feed

Submitted by sdhunter on Wed, 2008-01-16 19:46 in

I have just purchased price tapesty and would like to know if i can display/import only a certain group of products from a feed.

Im guessing, but say if i wanted to show only all xbox 360 games from the play.com feed, i would have to alter the template to link to a xbox 360 category?

I would ideally only like to import these feeds so i can build a niche site. Would this be possible inside the script or would i have to edit the csv to only have those games listed, then import...?

thanks in advance! its gonna be a late one tonight :D

Steve

Submitted by support on Wed, 2008-01-16 19:52

Hello Steve,

One solution is the "Drop Record (IF NOT)" filter (part of the distribution), which you can apply to the Category field (if registered), which would then limit importing to a specific category. However, this is developed into a regular expression based filter, the code for which you will find in the following thread:

http://www.pricetapestry.com/node/1551

Then you'll be able to drop records that don't match a list of values, for example:

(XBOX|Wii|PS3)

Hope this helps!
Cheers,
David.

Submitted by sdhunter on Wed, 2008-01-16 20:08

Your a star.
Very impressed with the prompt response.

Thanks!

Steve

Submitted by sdhunter on Sun, 2009-03-15 16:04

Going back to this one dave, ive got a problem when filtering to (ipod|IPOD|iPod) it will pull in items such as tripod. Anyway around that one?

Submitted by support on Sun, 2009-03-15 16:13

Hi,

You can use the regular expression ^ (beginning) and $ (end) anchors to specify whole words only, for example:

(^ipod$|^IPOD$|^iPod$)

...however that may not be appropriate here if "ipod" is part of a longer category name - in which case combining the beginning/end of line anchors with either that or space should do the the trick, for example:

((^| )ipod($| )|(^| )IPOD($| )|(^| )iPod($| ))

Cheers,
David.