我是mdx查询的新手。 我有想要在geomondrian表中可视化的空间属性,这是 simple_geofoodmart.xml 的模式:
<!-- spatial store dimension -->
<Dimension name="Store" foreignKey="store_id">
<Hierarchy hasAll="true" primaryKey="store_id" primaryKeyTable="geostore_store">
<Join leftKey="store_city_id_fk" rightKey="store_city_id"
rightAlias="geostore_city">
<Table name="geostore_store" />
<Join leftKey="store_state_id_fk" rightKey="store_state_id"
rightAlias="geostore_state">
<Table name="geostore_city" />
<Join leftKey="store_country_id_fk" rightKey="store_country_id">
<Table name="geostore_state" />
<Table name="geostore_country" />
</Join>
</Join>
</Join>
<Level name="Store Country" table="geostore_country" column="store_country_name"
uniqueMembers="true">
<Property name="geom" column="store_country_geom" type="Geometry" />
</Level>
<Level name="Store State" table="geostore_state" column="store_state_name"
uniqueMembers="true">
<Property name="geom" column="store_state_geom" type="Geometry" />
</Level>
<Level name="Store City" table="geostore_city" column="store_city_name"
uniqueMembers="false">
<Property name="geom" column="store_city_geom" type="Geometry" />
</Level>
<Level name="Store Name" table="geostore_store" column="store_name"
uniqueMembers="true">
<Property name="Store Type" column="store_type"/>
<Property name="Store Manager" column="store_manager"/>
<Property name="Store Sqft" column="store_sqft" type="Numeric"/>
<Property name="Street address" column="store_street_address" type="String"/>
</Level>
</Hierarchy>
</Dimension>
我希望列中的“geom”比例和行中的产品
答案 0 :(得分:1)
通常你这样做:
SELECT
[Measure] ON COLUMNS,
NON EMPTY [Store].MEMBERS
DIMENSION PROPERTIES
[Store].[geom] ON ROWS
FROM [Cube]
列出尺寸轴
中的尺寸属性答案 1 :(得分:0)
实际上我通过欺骗 在localhost索引中的ad hoc GeoMDX查询 的基本界面中给出的mdx示例找到了一个解决方案
with member Measures.geo as [Store].CurrentMember.Properties("geom")
select {[Measures].geo} ON rows,
{[Store].[All Stores].[USA]} ON columns
from [Sales]