Does each row have a unique identifier? If no, Tableau will tend to aggregate similar IDs, same dates etc. I've not worked so much with Json data, however if you can give each row a Unique ID, Tableau will then import all 22 rows as individual records. A field like [Row ID] with values 1, 2, 3, 4, 5 etc will do the job. This field must be unique per row, there shouldn't be any duplicates.
Hi, many thanks for replying to me.
So, unfortunately I cannot do anything on JSON structure and data and it hasn't rows with ids.
Anyway, I found that in the Measures panel there is: Number of Records per comments, Number of Records per answers etc.
Here they are correct. BUT, still one problem.
I cannot show this results in the dashboard. It shows ZERO.
So my idea was to put the total number of records per level in some parameters so that to show them in the dashboard, but still them are zero!
Although, JSON files are array datasets, internally the data is stored in some kind of rows and columns. You can only edit this if you have access to the source code.
I just downloaded a Json file from the internet and connected the file to Tableau. I noticed that a single Json file may have different schemas. You need to connect to every schema to see all the data. I'm not sure if this is relevant to your case.
I already connect to all schemas.
Could you give me an advice about the parameters?
I can't give much advice without seeing sample data.
What happens when you drag [paragraph], [comments] and [answer] fields to the rows shelf?
So, here it is the json
In the sheet Comparison I show the number of comments and the number of answers
I cannot view the 2 values in a pie chart, (considering that answers are a particular type o comments, I want to see the 2 percentages and total).
I cannot show those values in the dashboard.
If I create parameter from those measures, they are ZERO.
Here is the viz
I can add it to the dashboard without any problems. I did this in two ways. See the screenshots below.
Sheet 1 uses a calculated field. [Number of Comments]
"There are " + STR(SUM([Number of Records per comments])) + " comments"
Sheet 2 uses direct coding on the text marks card.
I can attach the workbook here, if you wish.
Hope this helps.
You created a sheet only to put this text string, and eventually you embed that sheet into the dashboard.
What a waste!
Is it really impossibile to simply use those numbers (eventually using parameters) to put directly into dashboard text field instead of creating sheets only for this purpose?
Further more, It would be useful to can create calculation like in Excel.
I mean, I would like to create a "Conversione rate" variable, given by answers/comments*100 %.
I have many difficulties not being able to do these things.