Showing posts with label BSO. Show all posts
Showing posts with label BSO. Show all posts

Thursday, October 27, 2016

Stupid Programming Tricks No. 30 -- FIXing Stupid Programming Tricks No. 15 with @SHARE and @REMOVE

For the love of Mike

I just wrestled with an Essbase calc script that humbled me because:  I couldn’t figure the !#$%ing thing out and I already dealt with this FOUR YEARS AGO (just about) in November 2012.  And I forgot that I did.  And I found out only when I searched for it on the web.  How embarrassing on several levels.  I am however happy to relate that I did figure this out (hence this post) and would ask you what exactly you were doing professionally four years ago.  Share your immediately referenced memories with me care of this site and please include estimated time between the previous sentence and recollection.
Yr. Obt. Svt. at work and play

So what didn’t work?

As I wrote back in Stupid Programming Tricks No. 15 @SHARE the pain with FIX, there is a bug (feature?) with FIX statements when allied to @REMOVE and shared member hierarchies.  To wit:  @REMOVEing shared members from within a FIX simply doesn’t work.  

To recap, here is Good Old Sample Basic aka MVFEDITWWW completely cleared out:

What I want to NOT do is write to the level zero descendants of Diet:  100-20, 200-20, and 300-30 but nowhere else.

One would think using FIX, @REMOVE, and @RELATIVE as follows would provide the desired result.  The idea being that if I use a @REMOVE function to remove the leaf Diet members – which are all shared – I will write to everything but 100-20, 200-20, and 300-30.  I will be disappointed.

By disappointed I mean this:

Ah.  That isn’t exactly what I wanted:  Essbase just wrote everywhere.  What went wrong other than it obviously isn’t working?

Why it went pear shaped

Rahul S. figured this out in his blog post FIX, REMOVE, and CLEARBLOCK, You may end up with No data ;).  Essentially (basically?) trying to remove shared members from a FIX statement using @RELATIVE results in a union of the two halves of the statement, i.e:  FIX(@REMOVE(@RELATIVE("Product", 0), @RELATIVE("Diet", 0)).  The first @RELATIVE selects all of the level 0 descendants of Product, the second @RELATIVE selects the shared 100-20, 200-20, and 300-30.  When these two @RELATIVE functions are surrounded by the @REMOVE the second set is removed from the first and then unioned with the now-reduced first set.  In other words, the shared members are removed and then they are added back in.  Go Read The Whole Thing but at the end you’ll join me in a despairing “Bugger”.  Double Bugger because this isn’t in any way, shape, manner, or form how Essbase deals with @REMOVE when the scope doesn’t address shared members; that works exactly as expected.  Triple Bugger.

As I noted in my blog post four years ago, there are three ways round this:
  1. Explicitly list all of the members to be excluded in that second set.
  2. Use a UDA to exclude the members in that second set.
  3. Use the EXCLUDE..ENDEXCLUDE grammar.

I’m rejecting all three approaches on the grounds of OMG-you-have-to-be-kidding-me (do I really need to detail why doing this for three members is annoying but for 30 or 120 is utter madness?), OMG-this-is-redundant, and OMG-it-doesn’t-freaking-work.

In order:
  1. Listing shared members in code is just dumb on effort, maintenance, and ascetic grounds.
  2. Assigning members to an alternate hierarchy and then assigning a UDA to those members as well is also dumb from an effort, maintenance, and ascetic perspective.
  3. EXCLUDE..ENDEXCLUDE doesn’t work.

The first two points are arguably subjective but the issue around EXCLUDE..ENDEXCLUDE one is not.  I am here to tell you that it flat out doesn’t work when applied to large data sets.  Don’t believe me?  What does this tell you when EXCLUDE..ENDEXCLUDE is applied to a real database?

Full system utilization or crap code?  I vote for the latter and the blame is squarely laid at the feet of EXCLUDE.  Oh EXCLUDE..ENDEXCLUDE, don’t you know you’ve broken my heart?  Such wasted promise.

So what are my choices?
  1. Give up.  All life is an illusion.  Seemingly insoluble FIX logic binds one to the Wheel of Things.
  2. Figure out another way round this.  Surely there has to be a way.

Fix it or ignore it

It occurred to me that if FIX was the issue, there might be another way to address members.  Of course there is but it is not typically used in the context of selecting sparse members:  I am speaking of an IF formula in a calculation block.  Before you start with, “Always FIX on sparse, IF on dense” I’m here to tell you that particular rule of thumb sucks eggs.  The only things that matter are:  does it work and the how does it perform.  The latter measure in BSO is always driven by the number of blocks accessed (assuming EXCLUDE..ENDEXCLUDE isn’t driving you round the bend).  Fast code that doesn’t work is trumped by maybe-slightly-slower code that does.

Let’s look at my “wrong” code:
The code still focuses on level 0 members of Product but instead of using FIX to identify members in the Diet hieararchy I’ve used an outline test to see if a member is a descendant of Diet or not.  To that point about an IF statement on sparse being bad by addressing every block without constraint this code doesn’t allow that because the containing FIX on level 0 Product defines the absolute limit of members to be tested; the IF statement just performs an outline query within that FIX.

And what do we get?

Ah, relief.  This really does the trick:  exclude the shared members within the hierarchy Diet from operations against the overall hierarchy of Product.

Sample.Basic is one thing.  What about a real database?  I am happy to share that it is fast as it doesn’t significantly address more blocks than the hoped-for @REMOVE statement would.  Yes, it is arguable that FIXing on everything and then testing for inclusion in a shared hierarchy is slower than never touching that hierarchy’s members but cf. that comment about fast code that doesn’t work.

What, if anything, have we (I) learnt?

  1. Try to remember what you did in the past.  I actually (now) remember writing that post.  It was a real stinker figuring out what didn’t work.  
  2. Has this unintuitive behavior been documented by Oracle?  Has it been fixed (this is not what any reasonable geek expects)?  Has EXCLUDE..ENDEXCLUDE been changed to actually work?  No, no, and no.
  3. Don’t focus on, “It has to work, it just has to.”  No it doesn’t.  Think Of Another Way.  There often is one in Essbase-land if not always in life.

Also, I have solved this !@$%ing problem.  And closed down one of my more painful Stupid Trick posts.

Be seeing you.

Thursday, August 25, 2016

Yup, another South Florida EPM meetup and the best yet

Yup, another one and the best yet

I just attended my sixth (I think it was the sixth but it’s all beginning to blur a bit.  Fifth?  Fourth?  No matter.) South Florida meetup out of the 15 or so meetup groups ODTUG have appleseeded.  Wherever they are, meetups are in one word fantastic.  Why?
  1. They’re informal
  2. They’re grassroots
  3. They’re inclusive
  4. They’re free
  5. They’re educational
  6. They’re awesome

Six reasons aren’t enough?  One would hope so.  If you’re not convinced let me review for you what made the latest meetup on 18 August 2016 in Miami, Florida so special.

The sponsors

While meetups can run on a shoestring – and sometimes these are the best of all – this latest event was a wee bit more organized and thus took money but not to the attendees.  Yup, you read that right:  this mini conference was free, gratis, sans frais, and geen kosten.  Did I mention I like ODTUG meetups?  Why yes I did.

ARC EPM, Secure24, and Top Down Consulting all generously contributed.  Thanks, Jessica Cordova, Monica Gordy, and John Riley.  It wouldn’t have happened without you.

What happened?

Good grief there was an awful lot going on.

The kickoff

Jessica, meetup organizer extraordinaire as well as ODTUG EPM Community meetup lead, kicked it off.  I’ve talked to Jessica in my role as the ODTUG board’s EPM liaison and she’s gone from nervous neophyte to seasoned practitioner.  Let her use her experience to help you set up a local meetup.


Who says there’s no such thing as a free lunch?  ‘Cos there was.  I had the chicken.  It sure beats the PB&J I typically have whilst working at home.

Speed dating without pain

Having once witnessed that as a disinterested observer (they were going through existential angst, I was having a Rob Roy at the bar), I’m entirely happy to relate that wasn’t occurring at the meetup.  What actually was happening was geek speed networking which happily misses the aforementioned exercise’s desperation but shares the notion of enabling EPM geeks to meet fellow EPM geeks.  

There, I’ve probably insulted half of my readers although I think it’s debatable which group I’ve insulted with what.  Sometimes I amaze myself, but almost always in a bad way.  Whew.   

Clawing my way back to relevance, it was a fun and effective way of meeting perfect strangers.  My only complaint is that we didn’t have enough time to do this for everyone (not all of us could meet everyone) but it was a big group (22 not including Yr. Obt. Svt. and two others).  This is a nice problem to have.

Some of us really got into it.  And why not?

The presentations

As noted Yr. Obt. Svt. reprised the Kscope16 presentation Jason Jones and I had on PBCS administration vs. on-premises.  Jason, I mangled the bit about your PBJ API framework for PBCS but I blundered through to the best of my ability.  Here I am rehearsing that morning disheveled, unshaven, and unshowered.  Eeek.  See, Gentle Reader, I do this all for you.

The dog seemed to like it.

Ron Moore and Ludovic de Paz presented their “(Keep) Pushing the Envelope with New Calcs Features”.  I used Ron’s section on FIXPARALLEL directly after the meetup to parallelize a DATACOPY section of an administrative currency conversion fx calc script.  One can’t ask for more than that when it comes to actionable information.  I should note that long ago in another professional life Ron Moore taught me ASO in one of his classes.  I’ve presented with Ludovic as well as Paul Hoch re Calculation Manager usage.  I guess my point is both of them know me, both of them knew I would be there, and both of them showed up anyway.  Thanks, guys.

Do people value these things?

Do you see that upper left photo in the collage below?  That’s Dhaval Shah and he drove two hours to attend the meetup.  He even won my latest book.  That’s hunger for knowledge.

You’re going to be at the next one, right?  

Or start up your own in your area if one doesn’t exist?  Right?  Why not?  Reach out to ODTUG and git a goin’.

Be seeing you.

Saturday, June 18, 2016

Kscope16 sessions I want (and maybe even will) attend

Will I?  Will I?  Maybe.

Ah, another year, another Kscope, another series of missed session opportunities.   No, not your opportunity to see better content when you avoid my sessions, but instead my never-ending and quite-likely-never-to-be-fulfilled desire to see all of Kscope all at once.  

For real and for true, even for the technologies I know Zip-a-Dee-Doo-Dah about, I wish I could attend each and every session no matter the subject.  Kscope16 is the very best place there is to know everything there is to know in Oracle-land except of course for Kscope17 and Kscope18 and so on till the end of time (or at least until I retire – après moi le déluge).

Yes, yes, all Kscope sessions are recorded and yes, yes, you can watch them after the conference but while as wonderful as that may be, nothing beats actually being there.  And that is what I (or you) cannot do.  As I like to quote, Ah, but a man's reach should exceed his grasp, Or what's a heaven for?.  Robert Browning I’m not, but at least I can appreciate his work and reflect upon the irony of practically failing out of a class on William Blake (mandatory English “elective”, and the professor really did try) and then actually enjoying poetry as an ostensibly adult geek.  Appreciation is an inadequate term – I love Kscope – I will not fail out of Kscope (not actually possible, but you know what I mean), and I will enjoy it to the very best of my ability.

That’s all a very long way of saying:  Kscope is awesome, Kscope is cool, if you don’t go to Kscope then you’re a fool.  ←Yes, I just made that up, and based on the quality of that ditty I won’t be OTN’s ACE Director in the Poet Laureate area.  Alas.

What am I really interested in?  Carnac knows.

So, silliness aside, below are the sessions I’m most keenly interested in separated by topic.  If you’re not already going to them, give them some consideration.  I think they’re going to be the highlights of the conference.

Cool titles

When: Jun 29, 2016, Session 17, 3:15 pm - 4:15 pm
Topic: EPM Applications - Subtopic: Planning

Coffee?  ‘Nuff said.

When: Jun 29, 2016, Session 18, 4:30 pm - 5:30 pm
Topic: EPM Applications - Subtopic: EPM Reporting

PBCS and BICS – who would not want to be there?

Co-presenter(s): Nick Scott, SC&H
When: Jun 29, 2016, Session 16, 2:00 pm - 3:00 pm
Topic: EPM Applications - Subtopic: Planning

Sandwiches, yum.

Cloud

There are lots and lots of sessions on this, too many to note, and two of which I am co-presenting.  Okay, I lie:  there’s over 50.   Take your pick but know that Cloud is the future.

Tuning

When: Jun 27, 2016, Session 4, 2:00 pm - 3:00 pm
Topic: EPM Platform - Subtopic: Essbase

Tim does brilliant, painstaking work which is just the sort of approach to figure this all out.  I’m particularly interested in his Hybrid session.

When: Jun 27, 2016, Session 2, 10:15 am - 11:15 am
Topic: EPM Platform - Subtopic: Essbase

Ibid.

Hybrid

When: Jun 28, 2016, Session 10, 2:00 pm - 3:00 pm
Topic: EPM Platform - Subtopic: Essbase

People ask, “Is Hybrid for real?”  This panel ought to answer the question.

When: Jun 29, 2016, Session 15b, 11:30 am - 12:30 pm
Topic: EPM Platform - Subtopic: Essbase

More Real World Hybrid.  Good stuff.

Data integration

When: Jun 28, 2016, Session 12, 4:45 pm - 5:45 pm
Topic: EPM Platform - Subtopic: Essbase

Focused aggregations for Planning, but far more dynamic and far cooler.

Co-presenter(s): Rodrigo Radtke de Souza, Dell
When: Jun 27, 2016, Session 6, 4:30 pm - 5:30 pm
Topic: EPM Platform - Subtopic: EPM Data Integration

The two Crazy (Brilliant) Brazilians.  They love ODI and you will too if you attend their session.

Two unfortunate men

Will Jason and Tim ever learn?  

Cameron Lackpour, ARC EPM
Co-presenter(s): Jason Jones, Applied OLAP
When: Jun 27, 2016, Session 3a, 12:45 pm - 1:45 pm
Topic: EPM Applications - Subtopic: Planning

This session is aimed at two different audiences:  on-premises Planning administrators who wonder what all the fuss is about PBCS from their perspective as well as PBCS admins who are looking to go beyond the in-built tools.  It’s a very practical and pragmatic approach to figuring out what the best way to manage your Planning apps and why PBCS is just better and easier to manage vs. on-premises. 

Cameron Lackpour, ARC EPM
Co-presenter(s): Tim German, Qubix
When: Jun 29, 2016, Session 17, 3:15 pm - 4:15 pm
Topic: EPM Platform - Subtopic: Essbase

If you’re in any way, shape, manner or form interested in Essbase in the cloud, you should come to this session.  You’ll hear Oracle’s take on EssCS at the Sunday Symposium.  Come to our session to see what it’s really like.

Extensibility

When: Jun 28, 2016, Session 9, 11:15 am - 12:15 pm
Topic: EPM Platform - Subtopic: Essbase

Dmitry is brilliant.  This is seriously good stuff when it comes extending Essbase.  

When: Jun 27, 2016, Session 5, 3:15 pm - 4:15 pm
Topic: EPM Platform - Subtopic: Essbase

My younger, smarter, taller brother from other parents keeps on teasing that this is cool stuff. The Calc Mgr team does sterling work with the developer community so I’m anxious to see what this is all about.

Co-presenter(s): Philip Hulsebosch, Trexco
When: Jun 29, 2016, Session 16, 2:00 pm - 3:00 pm
Topic: EPM Platform - Subtopic: Essbase

This is some cool $hit.  Yes, I really went there.  And yes it really is that awesome.

Smart View

The two G’s are the two Greats.  Or Geeks.  Or Great Geeks.  Or Geek Greats.  You decide.

When: Jun 28, 2016, Session 9, 11:15 am - 12:15 pm
Topic: EPM Applications - Subtopic: EPM Reporting

I love it:  George is bending Smart View to his will for (hopefully) the Forces of Good.

When: Jun 29, 2016, Session 15b, 11:30 am - 12:30 pm
Topic: EPM Applications - Subtopic: EPM Reporting

Gary is a sucker who fell for my pitch valued and generous EPM Community leader.  Gary, strangely, loves Smart View and is dedicated to making it better and better.  I’ve heard about, but have not seen, this add-in.  It’s supposed to be The Berries.

See you there

It’s going to be GREAT!  Content, content, content is king and Kscope is the place to see it.  There’s tons more than I’ve outlined above.  

Join us, won’t you?

Popular Posts