Hi YiMing
1,How did you add the extended column, through the GUI or REST API?
I added the extended column through the GUI with kylin version 1.5.2.1.
When you defined a cube, it has two actions on the cube. The second is to edit
the json of the cube. In the json, it have measures which you defined. All you
have to do is to add json segment as fllows. The value (PROVINCE_ID) in
parameter is the PK in fact table and the value (PROVINCE_NAME) in
next_parameter is the FK in fact table.
{
"name": "3",
"function": {
"expression": "EXTENDED_COLUMN",
"parameter": {
"type": "column",
"value": "PROVINCE_ID",
"next_parameter": {
"type": "column",
"value": "PROVINCE_NAME",
"next_parameter": null
}
},
"returntype": "extendedcolumn(100)"
},
"dependent_measure_ref": null
}
2,Why the wrong json was introduced?
First time, I did not add the next_parameter like this. You need tell
kylin which is the PK and which is the FK.
{
"name": "3",
"function": {
"expression": "EXTENDED_COLUMN",
"parameter": {
"type": "column",
"value": "PROVINCE_ID",
"next_parameter": null
},
"returntype": null
},
"dependent_measure_ref": null
}
you can see details in KYLIN-1313
(https://issues.apache.org/jira/browse/KYLIN-1313).
------------------ ???????? ------------------
??????: "Yiming Liu";<[email protected]>;
????????: 2016??6??27??(??????) ????9:46
??????: "????????????????-??????"<[email protected]>;
????: "dev"<[email protected]>;
????: Re: EXTENDED_COLUMN-build error
Hi Leilei,
Could you explain a little more about the wrong json? How did you add the
extended column, through the GUI or REST API? Why the wrong json was
introduced?
2016-06-27 17:15 GMT+08:00 ????????????????-?????? <[email protected]>:
problem solved.
the json is wrong.
the right json is like this :
{
"name": "3",
"function": {
"expression": "EXTENDED_COLUMN",
"parameter": {
"type": "column",
"value": "PROVINCE_ID",
"next_parameter": {
"type": "column",
"value": "PROVINCE_NAME",
"next_parameter": null
}
},
"returntype": "extendedcolumn(100)"
},
"dependent_measure_ref": null
}
------------------ ???????? ------------------
??????: "ShaoFeng Shi";<[email protected]>;
????????: 2016??6??25??(??????) ????8:27
??????: "dev"<[email protected]>;
????: Re: EXTENDED_COLUMN-build error
hi leilei, no attachement received, seems Apache mailing list doesn't
support it; Could you please try some way else or send it to my mailbox?
Thanks;
2016-06-24 20:43 GMT+08:00 ????????????????-?????? <[email protected]>:
> hi all:
>
> I added a extended_column cell_name and when I build the cube it
> failed. I don't know why. The diagnosis zip is in the attachement.
>
>
>
--
Best regards,
Shaofeng Shi
--
With Warm regards
Yiming Liu (??????)