RE: [JPivot-devel] Re: JPivot/Mondrian problem...
Brought to you by:
avix
From: Julian H. <jul...@sb...> - 2003-06-11 04:09:16
|
> > Is it possible to stream XML to the olap server instead of > > sending an > > XML file URI which will prevent unncessary creation of files if the > > levels change dynamically based on user selection on the UI? > > Ask Julian, afaik its not possible (we are generating schemas > too and store > them in files). Yes, it is possible to create a Mondrian schema programmatically, as opposed to by reading XML from a URI. I'd suggest that you create a starting schema XML file (maybe even empty), create a connection using that schema in the usual way, then do RolapSchema schema = (RolapSchema) connection.getSchema(); You can then use methods such as Schema.createDimension(Cube, String) to extend and modify the schema. The programmatic API is not widely tested, so look to the Mondrian source code (such as RolapSchema.load()) for examples. Also remember that in a multi-user environment, if you are modifying the schema, then other connections which have the same schema URL will be affected too. Julian |