I had a big argument with Oracle Support over this.

There are examples of doing exactly this sort of thing in the Data Warehousing guide, but they said that they couldn't help me with my problem (which was actually to do with getting a fast refresh) because this was not a supported methodology.

Anyway, as pando points out there are some severe restrictions that you have to respect and which depend on your version number. I would wonder whether that user-defined function might be a problem, myslef.