Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Python Tool

Shyam12
7 - Meteor

I have my output from the python tool as a Panda Dataframe. How should I input this to the workflow ? Can someone please help

6 REPLIES 6
Maskell_Rascal
13 - Pulsar

Hi @Shyam12 

 

I'm not sure I entirely understand your problem. Are you just needing to write the data from the Python tool to your workflow?

 

You can specify the output connector and the dataframe to write using the command:

Alteryx.write([your dataframe],1)

 

The number in you use specifies which connector number to output the data. So in the below code for example, I'm using pandas to read a zip file, and then outputting the data to connector one. 

Maskell_Rascal_0-1614874516519.png

 

Let me know if that makes sense or if this solves your issue please mark the answer as correct, if not let me know!

 

Thanks!

Phil

 

Shyam12
7 - Meteor

Hey Phil !

 

I have a dataframe as the output of my python tool. I wanted to know how I input this dataframe to my workflow. 

 

Maskell_Rascal
13 - Pulsar

Hi @Shyam12 

 

I'm still not understanding what you're asking. Can you provide a screenshot or a sample workflow for me to trouble shoot?

 

If you already have the data in the Python tool, you can just connect the Python tool to another tool in your workflow. 

 

Thanks!

Phil 

Shyam12
7 - Meteor

I try connecting the browse tool with the Python tool and this error pops up.

 

Shyam12_0-1614881392700.png

 

The output is of the type Pandas Dataframe. I've attached the entire workflow. Kindly help

 

Maskell_Rascal
13 - Pulsar

Hey @Shyam12 

 

This is a known error with the Python tool. I receive the same error when I open up any workflow with Python. 

Maskell_Rascal_0-1614884344787.png

The problem is that the Python tool doesn't save or pass metadata in a workflow. The error message should go away if you hit run on your workflow. 

 

Here some more info on it where this was brought up to Alteryx with a need to change the ideation behind how the Python tool operates. 

 

Thanks!

Phil

Shyam12
7 - Meteor

Hey Phil !

 

It now works perfectly fine and I am able to view the data stored as columns.

 

Thanks for all the help.

 

Cheers

Shyam

Labels