Sunday, January 31, 2010

The Essbase API Can Sometimes Be Very Touchy

I am working on something this morning with the Java API and found something to be a bit touchy and, of course, thought I would share it in case someone else runs into something similar.  Specifically, I was using the IEssCube.queryMembers() method which very quickly returns member information.  This function is the Java version of the VB API EsbQueryDatabaseMembers and C API EssQueryDatabaseMembers functions.

Those API calls use a query language that is similar to, but different than, Essbase report scripting language.  In this scripting language, spacing matters.  Here is a screenshot of something that didn't work:








Note there is no space between the FORMAT and {MBRNAMES} clauses in the query.  I added a space and here is the result:








In this case, the API correctly returned the ancestors of Connecticut.

Lesson: Be aware that spaces can be important, in some places, when working with Essbase.

2 comments:

Anonymous said...

Tim,

Could you comment a bit on the use of the Java API vs. the VB one for Essbase? I know next to nothing about Java and I was wondering about the benefits of doing future development in Java.

Thanks,
Jared

Tim Tow said...

Great idea for a future blog post!

Thanks,

Tim