Show all fields in the dashboard data view
The scenario typically goes like this:
- I'm debugging something
- I'm using the dashboard to reference data, changes to data, etc
- I observe a missing field and deduce something based on the missing field
- After running in circles for a bit I realize the field is being added at the end of the table only when it has a value for one of the currently visible rows
Sorting out my confusion often includes:
- Am I looking at the wrong table?
- Am I sure this field is in the schema?
- Didn't I just see this field and now it's gone?
- Scrolling and carefully looking at all of the field headers to make sure I'm not missing a field that's there
If my table has a schema, even if one of the fields has no value, I'd really like for it to be visible in the table view. When it changes dynamically, I've only ever seen that cost me time and a bit of lost hair 😄
Maybe this could be optional? My two cent would be to make all fields visible by default, as I suspect that will be the user's assumption, and optionally collapse/hide empty fields, as I realize some users have way too many fields and can't use the dashboard very well with all of them showing.
If Convex is tracking all field names for schema-less tables, I'd advocate to show all fields for those, too, as it'd be very helpful for grokking the difference between my mental model and what I've actually persisted. But I'm assuming Convex isn't keeping a list of fields in this case.
12 Replies
If the response is "yeah you can already do that, there's a setting" I will be tossing my computer down the hall lol
Does the “show schema” modal do enough about this? For a table you can see the declared and inferred field types. The inferred ones can even tell you when a field has a more specific type at times, eg if it’s always set / unset
Showing all the fields in a schema in the table view makes a lot of sense (I believe we show columns based on the fields present in data that's loaded, hence the dynamic behavior).
For the schema-less case, we do a best effort tracking of all field names, but give up at a certain point, but in a lot of cases we could show columns based off of that.
It's not that I need to know what's in the schema, I need to see a consistent set of all fields in the data table for when I'm combing through the data, especially during troubleshooting. It's like if you were using Excel and the columns keep relocating or disappearing based on the portion of data that's currently visible.
To clarify, “combing through” means applying filters?
Yeah, that's a large part of it
Currently the set of rendered columns changes often when the filter changes (in my case)
I'll also add, it would be really great to have fields in alphabetical order. I'm not sure how they're ordered now, but it feels random, and takes a while to find the right field on a table with even a medium amount of fields.
Actually seems like it's sorted alphabetically but in a few different passes. Table I'm looking at now seems to be fields broken into three alphabetical sets.
I think we remember your ordering if you reorder them so maybe we remembered the ordering before you added more? Interesting
ah, that could explain it
If you have an enforced schema specifying all the top level fields, we'll now show those as the columns in the data view
Perfect!! Thanks for the update!
@sshader just a bit of feedback, the behavior is still similar. I have all fields schema enforced for all tables, but the columns aren't in a predictable order. Even
_id
and _creationTime
vary in position. I have default fields created_at
and updated_at
first in every schema, they're also placed differently from table to table in the dashboard. Unset fields seem to get pushed to the end in some cases, but not others, not clear what the pattern is there.I think: The columns are sorted alphabetically unless you moved them.
They're sorted alphabetically (sort of) if they have a value, the unset fields are after the initial set of sorted fields
Looking through local storage to see what I've customized
Ah okay, some old custom ordering was throwing things off, it does look to be in alphabetical order, including unset fields. Thanks!