Hi, I am willing to make an insight that represent...
# gooddata-cloud
n
Hi, I am willing to make an insight that represents the trend of Institute ranks over the years and tried to do so, but I am getting an error which I am not able to understand. Can you help me understand this?(My column has only numeric data type) Can you guide me on the best way to be able to represent the trends of rank over the years? I am using the GoodData Cloud Free Trial Version.
f
Hi Nikita, thanks for posting! Can you tell us a bit more about the Ranks metric there? How is it built? Do you have its MAQL code?
n
Ranks is a column from one of the tables in our data model, we are trying to use the values directly.
f
Just to confirm, so the main metric is a simple SUM of a numeric value that is coming from your source data, right? By the error, it looks like the
Hybrid Ranks 2
fact has some values that are not being recognized as numeric. You mentioned that the whole column is already numeric, so it’s possible that the error message is bogus. Would you care to confirm the Data Type of this column on the source data?
n
We want to be able to represent the trend of Ranks of an Institute over Years. I am willing to learn how I can do that, also how can I use the values from my Rank column as is without any aggregate function applied on it and represent it on the line chart?. We have a column in our table that represents Rank, initially we kept the Data Type as Integer, when we did so, we were not able to have that as a Filter on the dashboard, also we could not get the desired output on the line chart as it was applying aggregate function on it. So, we tried to change the Data Type to string and use other types of charts, when we did so and kept the Ranks column as a filter it showed value selection options as 1,10,11,100,12... instead of 1,2,3,4.. To overcome this we tried to change the values on our source data as 001,002..010,011..100 and tried again, this time the filters looked fine, But still we could not get our insight the way we want it to be, we changed the column as fact in the data model, still we cannot get any values on the insight. We would like to understand how we can use our Rank column to make a line chart that shows it's trends for an Institute over the years.
j
The problem is that fact Management_ranking.hybridranks2 is declared as STRING in data model (check “View details” and “Dataset mapping” in modeler). It is perhaps CHAR or VARCHAR data type in database and needs to be converted to numeric data type there. You will need to refresh content of data source and save model with updated data type after change in database. You can also convert dataset to SQL dataset and apply the type casting to numeric data type in SQL query there.
n
I followed as you guided, I was able to build an insight, can you help me understand how I can change the order of ranks on Y-axis, so the institute with say Rank '4' appears above Rank '5'.
j
You can perhaps use following MAQL expression to get negative number
Copy code
SELECT -MIN(fact/institute_rank2})
together with format
[<=0]##0
. Then you can configure Y axis label format to use the metric format by option Format: “inherit”.
n
Thank you Jakub, I will try this..
This worked perfectly. Thank you so much @Jakub Sterba @Francisco Antunes 🙂
🙌 1