dbTalk Databases Forums  

MDX Square root or Power

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss MDX Square root or Power in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
stetou
 
Posts: n/a

Default MDX Square root or Power - 01-20-2006 , 02:13 PM






Hello,
How can we get the square root of a value with MDX?
I saw that some programmer use this "^" But, it doesn't work for me...
I thought it was an easy task...Maybe it is?
Thanks!


Reply With Quote
  #2  
Old   
Deepak Puri
 
Posts: n/a

Default Re: MDX Square root or Power - 01-20-2006 , 05:44 PM






It should work - what error do you get?

http://groups.google.com/group/micro...olap/msg/9ea49
17e0f679ba7
Quote:
Newsgroups: microsoft.public.sqlserver.olap
From: "Mosha Pasumansky [MS]"
Date: Mon, 10 Mar 2003 22:14:19 -0800

Subject: Re: SQR Function


Quote:
the vba!sqr function (or short sqr) does the trick.

Alternatively, you could use "^" operator in MDX - this should provide
better performance then calling into VBA. Example:

WITH MEMBER Measures.X AS ' 4 ^ 0.5 '
SELECT {X} on 0 FROM Sales


--
==================================================
Mosha Pasumansky (moshap at microsoft dot com)
Development Lead in the Microsoft Analysis Server team
More info at http://www.mosha.com/msolap
All you need is love (John Lennon)
Disclaimer : This posting is provided "AS IS" with no warranties, and
confers no rights.
==================================================
Quote:

- Deepak

Deepak Puri
Microsoft MVP - SQL Server

*** Sent via Developersdex http://www.developersdex.com ***


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.