You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Originally posted by mnunezdm March 28, 2019 Is your feature request related to a problem? Please describe.
Extracting data with the sfdx force:data:tree:export only allows to extract one level of nested elements. I think it would be great to extract deeply nested plans like for example: Account->Case->Task
I managed to manually extract the data in two steps, manually edit the data plan, and insert them using the sfdx force:data:tree:import -p
Describe the solution you'd like
Ability to, for example, retrieve a list of queries and make the plan automatically for example:
$ sfdx force:data:tree:export -p -q "SELECT Id, Name (SELECT Origin FROM Cases) FROM Account"
"SELECT Id, (SELECT Id FROM Tasks), (SELECT Id FROM Events) FROM Case"
The text was updated successfully, but these errors were encountered:
mshanemc
added
feature
Issue or pull request for a new feature
bug
Issue or pull request that identifies or fixes a bug
and removed
feature
Issue or pull request for a new feature
labels
Jan 23, 2024
Thank you for filing this feature request. We appreciate your feedback and will review the feature at our next grooming or sprint planning session. We prioritize feature requests with more upvotes and comments.
The code here https://github.com/salesforcecli/plugin-data/blob/3036c362566026b0d67ce66feb7e925087fa72b8/src/api/data/tree/exportApi.ts#L334-L335
delete record[key];
will remove the child record. It should have, instead, looked through eachchildRecords
's fields to see if any of themhasNestedRecords
. Probably should also be a recursive function itself, modifying theobjects
.The CLI's code is what's preventing it from handling more than 2 levels of object. The API and SOQL support up to 5 these days.
Discussed in #2359
Originally posted by mnunezdm March 28, 2019
Is your feature request related to a problem? Please describe.
Extracting data with the
sfdx force:data:tree:export
only allows to extract one level of nested elements. I think it would be great to extract deeply nested plans like for example:Account->Case->Task
I managed to manually extract the data in two steps, manually edit the data plan, and insert them using the
sfdx force:data:tree:import -p
Describe the solution you'd like
Ability to, for example, retrieve a list of queries and make the plan automatically for example:
Describe alternatives you've considered
NA
Additional context
This is the workaround I did: https://salesforce.stackexchange.com/questions/240042/sfdx-forcedatatreeexport-beyond-1-level-deep/255711#255711
The text was updated successfully, but these errors were encountered: