dbTalk Databases Forums  

Rowset Action with SQL statement

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


Discuss Rowset Action with SQL statement in the microsoft.public.sqlserver.olap forum.



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

Default Rowset Action with SQL statement - 08-30-2004 , 08:54 AM






Hello,

I understand it should be possible to define a Rowset Action that contains
an SQL query. Unfortunately I can't figure out what the syntax is of an SQL
statement within a Rowset Action.

Could anyone post an example of a SQL query that will function within a
Rowset Action (within the Foodmart 2000 Sales cube) ?

Thanks

Regards,

Mikey



Reply With Quote
  #2  
Old   
news.west.cox.net
 
Posts: n/a

Default Re: Rowset Action with SQL statement - 09-30-2004 , 01:30 AM






Take a look at the drillthrough syntax in BOL

"DRILLTHROUGH
SELECT [Warehouse].[All Warehouses].[Canada].[BC] ON ROWS,
[Time].[1998].[Q1] ON COLUMNS,
[Product].[All Products].[Drink] ON PAGES,
[Measures].[Units Shipped] ON SECTIONS
FROM [My Cube]"

Note the presence of quotations, this is by design so you can build a
dynamic statement using the dimension member in your cube.

This applies to all action types.



"Mikey" <dekkerm (AT) yahoo (DOT) com> wrote

Quote:
Hello,

I understand it should be possible to define a Rowset Action that contains
an SQL query. Unfortunately I can't figure out what the syntax is of an
SQL statement within a Rowset Action.

Could anyone post an example of a SQL query that will function within a
Rowset Action (within the Foodmart 2000 Sales cube) ?

Thanks

Regards,

Mikey




Reply With Quote
  #3  
Old   
François JEHL
 
Posts: n/a

Default RE: Rowset Action with SQL statement - 06-21-2009 , 07:42 AM



I've coded a little AS StoredProcedure that executes some SQL code on a server specified by an OLE DB connection string and returns the result as a DataTable. You can CALL it from a Rowset action your client application will be able to interpret it (at least Excel and OWC seem to do so). More information and the DLL here on my blog (sorry it's in french but you can Google-Translate it): http://fjehl.blogspot.com/2009/06/ss...procedure.html

Hope this helps

From http://www.developmentnow.com/g/112_...-statement.htm

Posted via DevelopmentNow.com Groups
http://www.developmentnow.com/g/

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.