Dataset schema view
# apify-platform
b
Hey, in the dataset schema view, we can either show all data or apply a transformation like "flatten". Is it possible to do both: extract certain fields that may be more important to their own columns, but still have an
object
field for the full data (some field are less important and potentially empty)? When I do it at the moment the data is shown as
undefined
. I'm adding my code and the resulting views as screenshot, hope this helps understanding what I'm describing. Relevant docs I've used for reference: https://docs.apify.com/platform/actors/development/actor-definition/dataset-schema
h
Someone will reply to you shortly. In the meantime, this might help:
m
I'm not sure if I understand your question correctly, but you can adjust the output schema by defining “flatten” fields for “data”. I hope the solution in the example is understandable. https://cdn.discordapp.com/attachments/1317914817243381770/1317934058075848744/image.png?ex=67607d3d&is=675f2bbd&hm=3174fbeb421fed10d61e6493486eeef4297f542da6606029e9d14abb4fa7cc6d&
b
I want to extract some fields from a dict called
data
(using
flatten
or
unwind
), but also show the full
data
dict as an object (similarly to
metadata
in my screenshot). I haven't found a way to make it work so far,
data
ends up showing as
undefined