Scraping a loop of URLs with odd first URL

Trying to scrape a list of URLs. Numbers 2-809 (news pages with 10 articles each) follow a standard format Главная | Оренбургское казачье войско (ataman-ovko.ru) so I should be able to tell Knime to iterate through loops by adding 1 each time.

However, first page is unnumbered and adding it into the data gathering file causes it not to work Главная | Оренбургское казачье войско (ataman-ovko.ru). Is there any way to do this programmatically?

Hi @drrarnold22,

if you loop over aa list of URLs, you could use aa simple Rule Node to check if the current iteration variable equals zero and return the desired value. To return the original value if the current iteration is not zero use TRUE

The rule might look like so:

$Current Iteration$$ = 0 = 0$
TRUE => $YOU DATA COLUMN$

Best
Mike

1 Like

That fixed it! Thanks!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.