# OLAP and Models / ActiveRecord etc etc

**URL:** <https://www.ruby-forum.com/t/olap-and-models-activerecord-etc-etc/107481>\
**Category:** Rails\
**Created:** [June 22, 2007, 4:44am UTC](https://www.ruby-forum.com/t/olap-and-models-activerecord-etc-etc/107481 "2007-06-22T04:44:53Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeannibee](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/85e7bf/32.png) [@jeannibee](https://www.ruby-forum.com/u/jeannibee)\
**Post date:** [June 22, 2007, 4:44am UTC](https://www.ruby-forum.com/t/olap-and-models-activerecord-etc-etc/107481/1 "2007-06-22T04:44:53Z")

</div>

How would you handle reporting on an OLAP database?

I have no issues whatsoever using the Rails ActiveRecord way of doing  
things for my OLTP setup, but for OLAP it “seems” (I haven’t tried it  
yet) to be one heck of a bunch of overhead.

Then again if there’s a way to have a series of related tables in a star  
schema like customer\_dimension -\> sales\_facts \<- time\_dimension; and  
just execute a query with my aggregate functions / groupings and then  
find a Model to map the ResultSet to I’d be home free. Seems to me  
straight to the DB could accomplish this easily.

Now to end all this, I am aware of the ActiveWarehouse ‘plugin’ to  
rails… it’s interesting, I’m just curious if people are foregoing  
ActiveRecord for OLAP solutions and going straight to the DB.

---

<div class="post-metadata">

**Author:** ![jeannibee](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/85e7bf/32.png) [@jeannibee](https://www.ruby-forum.com/u/jeannibee)\
**Post date:** [June 22, 2007, 5:13am UTC](https://www.ruby-forum.com/t/olap-and-models-activerecord-etc-etc/107481/2 "2007-06-22T05:13:21Z")

</div>

Our app has an OLAP aspect within an OLTP app. The schema is a  
standard star schema.

For many things we use custom SQL to get subqueries for the  
aggregates. For data management we use AR.

Michael
