Qlik Community

Qlik Sense Integration, Extensions, & APIs

Discussion board where members can learn more about Integration, Extensions and API’s for Qlik Sense.

laurentpaume
New Contributor III

Displaying a master dimension in Qlik Sense App

Hi Qlik Devs,

I am currently working on my new extension and I am not finding the solution to create a master dimension and display it into my Sense app.

Here is the code to create the master dimension (tested in Engine Api Explorer) :

{

  "handle": 1,

  "method": "CreateDimension",

  "params": {

  "qProp": {

  "qInfo": {

  "qId": "Dimension21",

  "qType": "Dimension"

  },

  "qDim": {

  "qGrouping": 0,

  "qFieldDefs": [

  "LBL_STORE"

  ],

  "qFieldLabels": [

  "Store"

  ]

  },

  "qMetaDef": {}

  }

  }

}

It returns me the following response :

{

  "jsonrpc": "2.0",

  "id": 9,

  "result": {

  "qReturn": {

  "qType": "GenericDimension",

  "qHandle": 4,

  "qGenericType": "Dimension",

  "qGenericId": "72fa4096-c176-48dd-b71d-d8c0c9f74d0c"

  },

  "qInfo": {

  "qId": "72fa4096-c176-48dd-b71d-d8c0c9f74d0c",

  "qType": "Dimension"

  }

  },

  "change": [

  4

  ]

}

At this point when I get back to my app, I don't find the Master Dimension.

I don't know if I have to create an Hypercube to show this in my app or if I'm missing something.

Thanks for your help !

Regards,

Laurent.

Beasy.

1 Solution

Accepted Solutions
Employee
Employee

Re: Displaying a master dimension in Qlik Sense App

Hi Laurent,

It feels weird, but have you tried  "qType": "dimension" intead of "qType": "Dimension" , that works for me, for some reason.

Regards,

aiham

3 Replies
Employee
Employee

Re: Displaying a master dimension in Qlik Sense App

Hi Laurent,

It feels weird, but have you tried  "qType": "dimension" intead of "qType": "Dimension" , that works for me, for some reason.

Regards,

aiham

laurentpaume
New Contributor III

Re: Displaying a master dimension in Qlik Sense App

Completely Crazy, yes Aiham, it works but in a strange manner ...

I get an empty name for the dimension ... I will try to find why this afternoon.

Thanks a lot.

laurentpaume
New Contributor III

Re: Displaying a master dimension in Qlik Sense App

Ok everything's fine now :

This is the correct way of creating a dimension in QlikSense using the API :

{

  "handle": 1,

  "method": "CreateDimension",

  "params": {

  "qProp": {

  "qInfo": {

  "qId": "Dimension21",

  "qType": "dimension"

  },

  "qDim": {

  "qGrouping": 0,

  "qFieldDefs": [

  "LBL_STORE"

  ],

  "qFieldLabels": [

  "Store"

  ]

  },

  "qMetaDef": { "title": "Store Title goes here !"}

  }

  }

}

Community Browser