# prefect-community

Sushma Adari

06/30/2022, 7:37 PM
Hi all, I am trying to pass parameters from the output of a Parent Task to a child flow. These parameters are dataframes that a few other child processes will use as well however I receive the below TypeError: My question is what is the best way to pass data from Parent to Child flows? I am trying to avoid querying multiple times since the query is intensive
TypeError: Object of type DataFrame is not JSON serializable

Anna Geller

07/01/2022, 1:10 AM
You can pass data between tasks, but it's much harder to do between flows since each flow may in theory even run on completely different machines You can either persist this data somewhere and retrieve it in your another flow, or try the get_task_run_result task
Btw in Prefect 2.0 this is way easier

Sushma Adari

07/11/2022, 5:49 PM
Do you have an example of this case? I want the ParentFlow to read a dataframe processed by a child flow. Would I save the child flow's result in a Result and then from the parent Flow try to use get_task_run_result? Also, I am not familiar with SLug IDs is this a return value from the create_flow_run?