> Hi,
>
> I got stuck with the following problem and strangely couldn't find
> anything similar in the list:
>
> Assume two tables:
> table: warehouse, columns: id, incoming, outgoing
> table: articles, columns: id, articles_in_stock
>
> All I want is to create a rule, that everytime when articles leave or
> get in the warehouse, the sum of articles is updated in articles database.
>
Why are you trying rules? Trigger function would be much more logical
choice. There are some limitations in RULE syntax that won't let you use
all SQL statements there, so trigger might be your only way out
Peter