Update scratchpad.ipynb
parent
bffda402cb
commit
71559b7894
320
scratchpad.ipynb
320
scratchpad.ipynb
|
|
@ -9,7 +9,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 293,
|
||||
"execution_count": 127,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
|
|
@ -26,22 +26,61 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 294,
|
||||
"execution_count": 128,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"outputs": [
|
||||
{
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"None\n",
|
||||
"('1', '<Node ToolID=\"1\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.TextInput.TextInput\">\\n <Position x=\"54\" y=\"54\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <NumRows value=\"3\" />\\n <Fields>\\n <Field name=\"Column1\" />\\n <Field name=\"Column 2\" />\\n </Fields>\\n <Data>\\n <r>\\n <c>1</c>\\n <c>4</c>\\n </r>\\n <r>\\n <c>2</c>\\n <c>5</c>\\n </r>\\n <r>\\n <c>3</c>\\n <c>6</c>\\n </r>\\n </Data>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxTextInput\" />\\n </Node>\\n ')\n",
|
||||
"('2', '<Node ToolID=\"2\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.AlteryxSelect.AlteryxSelect\">\\n <Position x=\"186\" y=\"54\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <OrderChanged value=\"False\" />\\n <CommaDecimal value=\"False\" />\\n <SelectFields>\\n <SelectField field=\"Column1\" selected=\"True\" type=\"Int64\" size=\"8\" />\\n <SelectField field=\"Column 2\" selected=\"False\" type=\"WString\" size=\"3\" />\\n <SelectField field=\"*Unknown\" selected=\"False\" />\\n </SelectFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxSelect\" />\\n </Node>\\n ')\n",
|
||||
"('3', '<Node ToolID=\"3\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.BrowseV2.BrowseV2\">\\n <Position x=\"318\" y=\"54\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <TempFile>C:\\\\Users\\\\Casey\\\\AppData\\\\Local\\\\Temp\\\\Engine_4072_8b6c0740e308d445ab856d90eb0e4ee9_\\\\Engine_4072_93f5c2999bcb8c478c002b15166e2b45~.yxdb</TempFile>\\n <TempFileDataProfiling />\\n <Layout>\\n <View1>\\n <Hints>\\n <Table />\\n </Hints>\\n </View1>\\n </Layout>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxBrowseV2\" />\\n </Node>\\n ')\n",
|
||||
"('4', '<Node ToolID=\"4\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.TextInput.TextInput\">\\n <Position x=\"54\" y=\"246\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <NumRows value=\"3\" />\\n <Fields>\\n <Field name=\"Column 3\" />\\n <Field name=\"Column 4\" />\\n <Field name=\"Ham\" />\\n <Field name=\"Cheese\" />\\n </Fields>\\n <Data>\\n <r>\\n <c>5</c>\\n <c>8</c>\\n <c>z</c>\\n <c>a</c>\\n </r>\\n <r>\\n <c>6</c>\\n <c>9</c>\\n <c>b</c>\\n <c>d</c>\\n </r>\\n <r>\\n <c>7</c>\\n <c>10</c>\\n <c>c</c>\\n <c>c</c>\\n </r>\\n </Data>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxTextInput\" />\\n </Node>\\n ')\n",
|
||||
"('5', '<Node ToolID=\"5\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.AlteryxSelect.AlteryxSelect\">\\n <Position x=\"174\" y=\"246\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <OrderChanged value=\"False\" />\\n <CommaDecimal value=\"False\" />\\n <SelectFields>\\n <SelectField field=\"Column 3\" selected=\"True\" rename=\"Col_3_renamed\" />\\n <SelectField field=\"Column 4\" selected=\"False\" />\\n <SelectField field=\"*Unknown\" selected=\"True\" />\\n </SelectFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxSelect\" />\\n </Node>\\n ')\n",
|
||||
"('6', '<Node ToolID=\"6\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Formula.Formula\">\\n <Position x=\"174\" y=\"330\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <FormulaFields>\\n <FormulaField expression=\"[Count] + 10\" field=\"MoreCount\" size=\"4\" type=\"Int32\" />\\n </FormulaFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>MoreCount = [Count] + 10\\n</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxFormula\" />\\n </Node>\\n ')\n",
|
||||
"('7', '<Node ToolID=\"7\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Join.Join\">\\n <Position x=\"318\" y=\"258\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration joinByRecordPos=\"False\">\\n <JoinInfo connection=\"Left\">\\n <Field field=\"Ham\" />\\n <Field field=\"Cheese\" />\\n </JoinInfo>\\n <JoinInfo connection=\"Right\">\\n <Field field=\"Ham\" />\\n <Field field=\"Cheese\" />\\n </JoinInfo>\\n <SelectConfiguration>\\n <Configuration outputConnection=\"Join\">\\n <OrderChanged value=\"False\" />\\n <CommaDecimal value=\"False\" />\\n <SelectFields>\\n <SelectField field=\"Right_Ham\" selected=\"True\" rename=\"Right_Ham\" input=\"Right_\" />\\n <SelectField field=\"Right_Cheese\" selected=\"True\" rename=\"Right_Cheese\" input=\"Right_\" />\\n <SelectField field=\"Right_Column 3\" selected=\"True\" rename=\"Right_Column 3\" input=\"Right_\" type=\"V_String\" size=\"11\" />\\n <SelectField field=\"Right_Column 4\" selected=\"True\" rename=\"Right_Column 4\" input=\"Right_\" type=\"Int64\" size=\"8\" />\\n <SelectField field=\"*Unknown\" selected=\"True\" />\\n </SelectFields>\\n </Configuration>\\n </SelectConfiguration>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxJoin\" />\\n </Node>\\n ')\n",
|
||||
"('10', '<Node ToolID=\"10\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.BrowseV2.BrowseV2\">\\n <Position x=\"414\" y=\"342\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <TempFile>C:\\\\Users\\\\Casey\\\\AppData\\\\Local\\\\Temp\\\\Engine_4072_8b6c0740e308d445ab856d90eb0e4ee9_\\\\Engine_4072_ab9b90f8fc991440905d667f1d5c7325~.yxdb</TempFile>\\n <TempFileDataProfiling />\\n <Layout>\\n <View1>\\n <Hints>\\n <Table />\\n </Hints>\\n </View1>\\n </Layout>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxBrowseV2\" />\\n </Node>\\n ')\n",
|
||||
"('11', '<Node ToolID=\"11\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Formula.Formula\">\\n <Position x=\"270\" y=\"474\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <FormulaFields>\\n <FormulaField expression=\"[Engine.TempFilePath]\" field=\"Path\" size=\"1073741823\" type=\"V_WString\" />\\n </FormulaFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>Path = [Engine.TempFilePath]\\n</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxFormula\" />\\n </Node>\\n ')\n",
|
||||
"('12', '<Node ToolID=\"12\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Sample.Sample\">\\n <Position x=\"150\" y=\"474\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <Mode>First</Mode>\\n <N>1</N>\\n <GroupFields orderChanged=\"False\" />\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>First 1</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxSample\" />\\n </Node>\\n ')\n",
|
||||
"('13', '<Node ToolID=\"13\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.BrowseV2.BrowseV2\">\\n <Position x=\"366\" y=\"474\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <TempFile>C:\\\\Users\\\\Casey\\\\AppData\\\\Local\\\\Temp\\\\Engine_4072_8b6c0740e308d445ab856d90eb0e4ee9_\\\\Engine_4072_dd72ded80941104b9b9be56761379cb2~.yxdb</TempFile>\\n <TempFileDataProfiling />\\n <Layout>\\n <View1>\\n <Hints>\\n <Table />\\n </Hints>\\n </View1>\\n </Layout>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxBrowseV2\" />\\n </Node>\\n ')\n",
|
||||
"('14', '<Node ToolID=\"14\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.DbFileOutput.DbFileOutput\">\\n <Position x=\"522\" y=\"258\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <File MaxRecords=\"\" FileFormat=\"0\">.\\\\SimpleWorkflowOut.csv</File>\\n <Passwords />\\n <Disable>False</Disable>\\n <FormatSpecificOptions>\\n <LineEndStyle>CRLF</LineEndStyle>\\n <Delimeter>,</Delimeter>\\n <ForceQuotes>False</ForceQuotes>\\n <HeaderRow>True</HeaderRow>\\n <CodePage>28591</CodePage>\\n <WriteBOM>True</WriteBOM>\\n </FormatSpecificOptions>\\n <MultiFile value=\"False\" />\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>SimpleWorkflowOut.csv</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxDbFileOutput\" />\\n </Node>\\n ')\n",
|
||||
"('15', '<Node ToolID=\"15\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.TextInput.TextInput\">\\n <Position x=\"54\" y=\"330\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <NumRows value=\"3\" />\\n <Fields>\\n <Field name=\"Ham\" />\\n <Field name=\"Cheese\" />\\n <Field name=\"Count\" />\\n </Fields>\\n <Data>\\n <r>\\n <c>a</c>\\n <c>a</c>\\n <c>4</c>\\n </r>\\n <r>\\n <c>b</c>\\n <c>d</c>\\n <c>6</c>\\n </r>\\n <r>\\n <c>c</c>\\n <c>z</c>\\n <c>7</c>\\n </r>\\n </Data>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxTextInput\" />\\n </Node>\\n ')\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"# Parse out nodes (tool data) into a dict\n",
|
||||
"def extract_tool_id_and_contents(xml_string):\n",
|
||||
" root = ET.fromstring(xml_string)\n",
|
||||
" results = []\n",
|
||||
" for node in root.iter('Node'):\n",
|
||||
" tool_type = node.attrib.get('.//GuiSettings')\n",
|
||||
" print(tool_type)\n",
|
||||
" tool_id = node.attrib.get('ToolID')\n",
|
||||
" content = ET.tostring(node, encoding='unicode')\n",
|
||||
" results.append((tool_id, content))\n",
|
||||
" return results\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"results = extract_tool_id_and_contents(xml_string)"
|
||||
"results = extract_tool_id_and_contents(xml_string)\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"for tool in results:\n",
|
||||
" print(tool)"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -53,7 +92,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 329,
|
||||
"execution_count": 129,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
|
|
@ -92,15 +131,15 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 334,
|
||||
"execution_count": 130,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"{'joinParams': ('Col_3_renamed', 'Column 3'), 'SelectFields': {'Right_Column 3': ('True', 'Right_Column 3', 'Right_', None), 'Right_Column 4': ('True', 'Right_Column 4', 'Right_', None), '*Unknown': ('True', None, None, None)}}\n",
|
||||
"None\n"
|
||||
"ename": "IndentationError",
|
||||
"evalue": "expected an indented block after function definition on line 1 (2015830356.py, line 5)",
|
||||
"output_type": "error",
|
||||
"traceback": [
|
||||
"\u001b[1;36m Cell \u001b[1;32mIn[130], line 5\u001b[1;36m\u001b[0m\n\u001b[1;33m xml_join_tool = results[6][1]\u001b[0m\n\u001b[1;37m ^\u001b[0m\n\u001b[1;31mIndentationError\u001b[0m\u001b[1;31m:\u001b[0m expected an indented block after function definition on line 1\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
|
|
@ -119,7 +158,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 349,
|
||||
"execution_count": 76,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
|
|
@ -193,7 +232,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 295,
|
||||
"execution_count": 131,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
|
|
@ -203,7 +242,7 @@
|
|||
" # Extract the field names\n",
|
||||
" fields = [field.attrib['name'] for field in root.findall(\".//Fields/Field\")]\n",
|
||||
" # Extract the data rows\n",
|
||||
" data_rows = [[int(c.text) for c in row.findall(\"c\")] for row in root.findall(\".//Data/r\")]\n",
|
||||
" data_rows = [[c.text for c in row.findall(\"c\")] for row in root.findall(\".//Data/r\")]\n",
|
||||
" # Create the polars dataframe\n",
|
||||
" df = pl.DataFrame(data_rows, fields, orient=\"row\")\n",
|
||||
" # Display the dataframe\n",
|
||||
|
|
@ -212,7 +251,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 296,
|
||||
"execution_count": 132,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
|
|
@ -240,9 +279,70 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 330,
|
||||
"execution_count": 133,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"outputs": [
|
||||
{
|
||||
"ename": "SyntaxError",
|
||||
"evalue": "invalid syntax (213487073.py, line 22)",
|
||||
"output_type": "error",
|
||||
"traceback": [
|
||||
"\u001b[1;36m Cell \u001b[1;32mIn[133], line 22\u001b[1;36m\u001b[0m\n\u001b[1;33m if fields.attrib['selected'] == 'True' and fields.attrib['field'] != :\u001b[0m\n\u001b[1;37m ^\u001b[0m\n\u001b[1;31mSyntaxError\u001b[0m\u001b[1;31m:\u001b[0m invalid syntax\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"def getConf_Join(xml_string):\n",
|
||||
" root = ET.fromstring(xml_string)\n",
|
||||
" dict_JoinTool = {}\n",
|
||||
"\n",
|
||||
" # Join parameters\n",
|
||||
" for joinField in root.findall(\".//Configuration/JoinInfo\"):\n",
|
||||
" if joinField.attrib['connection'] == \"Left\":\n",
|
||||
" left_on = [field.attrib['field'] for field in joinField]\n",
|
||||
" if joinField.attrib['connection'] == \"Right\":\n",
|
||||
" right_on = [field.attrib['field'] for field in joinField]\n",
|
||||
"\n",
|
||||
" if left_on == right_on:\n",
|
||||
" dict_JoinTool['joinParams'] = ('on', left_on)\n",
|
||||
" else:\n",
|
||||
" dict_JoinTool['joinParams'] = (left_on, right_on)\n",
|
||||
"\n",
|
||||
" \n",
|
||||
" # Field Parameters\n",
|
||||
" fieldConfig = {}\n",
|
||||
" for fields in root.findall(\".//SelectField\"):\n",
|
||||
" result = []\n",
|
||||
" if fields.attrib['selected'] == 'True' and fields.attrib['field'] != :\n",
|
||||
" for field in ['rename', 'input', 'type', 'size']:\n",
|
||||
" try:\n",
|
||||
" result.append(fields.attrib[field])\n",
|
||||
" except KeyError:\n",
|
||||
" result.append(None)\n",
|
||||
"\n",
|
||||
" fieldConfig[fields.attrib['field']] = result\n",
|
||||
"\n",
|
||||
"\n",
|
||||
" dict_JoinTool['fields'] = fieldConfig\n",
|
||||
"\n",
|
||||
" return dict_JoinTool\n",
|
||||
"\n",
|
||||
"print(getConf_Join(xml_join_tool))"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 134,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"{'joinParams': ([<Element 'Field' at 0x0000027D2CB4F470>, <Element 'Field' at 0x0000027D2CB4F510>], [<Element 'Field' at 0x0000027D2CB4F6F0>, <Element 'Field' at 0x0000027D2CB4DA30>]), 'SelectFields': {'Right_Ham': ('True', 'Right_Ham', 'Right_', None), 'Right_Cheese': ('True', 'Right_Cheese', 'Right_', None), 'Right_Column 3': ('True', 'Right_Column 3', 'Right_', 'V_String'), 'Right_Column 4': ('True', 'Right_Column 4', 'Right_', 'Int64'), '*Unknown': ('True', None, None, None)}}\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"def getConf_Join(xml_string):\n",
|
||||
" # print(xml_string)\n",
|
||||
|
|
@ -253,10 +353,22 @@
|
|||
"\n",
|
||||
" # Join parameters\n",
|
||||
" for joinField in root.findall(\".//Configuration/JoinInfo\"):\n",
|
||||
" \n",
|
||||
"\n",
|
||||
" # left_on = [joinField.findall('Field') for c in joinField.attrib['connection'] == \"Left\"] \n",
|
||||
"\n",
|
||||
" if joinField.attrib['connection'] == \"Left\":\n",
|
||||
" left_on = joinField.find('Field').attrib['field']\n",
|
||||
" pass\n",
|
||||
" left_on = joinField.findall('Field') #.attrib['field']\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"\n",
|
||||
" \n",
|
||||
" # for field in left_on:\n",
|
||||
" # print(field.attrib['field'])\n",
|
||||
"\n",
|
||||
" elif joinField.attrib['connection'] == \"Right\":\n",
|
||||
" right_on = joinField.find('Field').attrib['field']\n",
|
||||
" right_on = joinField.findall('Field') #.attrib['field']\n",
|
||||
"\n",
|
||||
" if left_on == right_on:\n",
|
||||
" dict_JoinTool['joinParams'] = ('on', left_on)\n",
|
||||
|
|
@ -264,6 +376,7 @@
|
|||
" dict_JoinTool['joinParams'] = (left_on, right_on)\n",
|
||||
"\n",
|
||||
" fieldConfig = {}\n",
|
||||
"\n",
|
||||
" # Select parameters\n",
|
||||
" for joinField in root.findall(\".//SelectField\"):\n",
|
||||
" field = joinField.attrib['field']\n",
|
||||
|
|
@ -290,8 +403,8 @@
|
|||
" dict_JoinTool[\"SelectFields\"] = fieldConfig\n",
|
||||
" return dict_JoinTool\n",
|
||||
"\n",
|
||||
"# xml_join_tool = results[6][1]\n",
|
||||
"# print(getConf_Join(xml_join_tool))\n"
|
||||
"xml_join_tool = results[6][1]\n",
|
||||
"print(getConf_Join(xml_join_tool))\n"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -303,7 +416,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 40,
|
||||
"execution_count": 89,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
|
|
@ -312,28 +425,28 @@
|
|||
"text": [
|
||||
"1 TextInput\n",
|
||||
"shape: (3, 2)\n",
|
||||
"┌──────────┬──────────┐\n",
|
||||
"│ Column 3 ┆ Column 4 │\n",
|
||||
"│ --- ┆ --- │\n",
|
||||
"│ i64 ┆ i64 │\n",
|
||||
"╞══════════╪══════════╡\n",
|
||||
"│ 5 ┆ 8 │\n",
|
||||
"│ 6 ┆ 9 │\n",
|
||||
"│ 7 ┆ 10 │\n",
|
||||
"└──────────┴──────────┘\n",
|
||||
"┌─────────┬──────────┐\n",
|
||||
"│ Column1 ┆ Column 2 │\n",
|
||||
"│ --- ┆ --- │\n",
|
||||
"│ str ┆ str │\n",
|
||||
"╞═════════╪══════════╡\n",
|
||||
"│ 1 ┆ 4 │\n",
|
||||
"│ 2 ┆ 5 │\n",
|
||||
"│ 3 ┆ 6 │\n",
|
||||
"└─────────┴──────────┘\n",
|
||||
"2 AlteryxSelect\n",
|
||||
"3 BrowseV2\n",
|
||||
"4 TextInput\n",
|
||||
"shape: (3, 2)\n",
|
||||
"┌──────────┬──────────┐\n",
|
||||
"│ Column 3 ┆ Column 4 │\n",
|
||||
"│ --- ┆ --- │\n",
|
||||
"│ i64 ┆ i64 │\n",
|
||||
"╞══════════╪══════════╡\n",
|
||||
"│ 5 ┆ 8 │\n",
|
||||
"│ 6 ┆ 9 │\n",
|
||||
"│ 7 ┆ 10 │\n",
|
||||
"└──────────┴──────────┘\n",
|
||||
"shape: (3, 4)\n",
|
||||
"┌──────────┬──────────┬─────┬────────┐\n",
|
||||
"│ Column 3 ┆ Column 4 ┆ Ham ┆ Cheese │\n",
|
||||
"│ --- ┆ --- ┆ --- ┆ --- │\n",
|
||||
"│ str ┆ str ┆ str ┆ str │\n",
|
||||
"╞══════════╪══════════╪═════╪════════╡\n",
|
||||
"│ 5 ┆ 8 ┆ z ┆ a │\n",
|
||||
"│ 6 ┆ 9 ┆ b ┆ d │\n",
|
||||
"│ 7 ┆ 10 ┆ c ┆ c │\n",
|
||||
"└──────────┴──────────┴─────┴────────┘\n",
|
||||
"5 AlteryxSelect\n",
|
||||
"6 Formula\n",
|
||||
"7 Join\n",
|
||||
|
|
@ -341,15 +454,18 @@
|
|||
"11 Formula\n",
|
||||
"12 Sample\n",
|
||||
"13 BrowseV2\n",
|
||||
"14 DbFileOutput\n"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "stderr",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"/tmp/ipykernel_579015/219306832.py:9: DataOrientationWarning: Row orientation inferred during DataFrame construction. Explicitly specify the orientation by passing `orient=\"row\"` to silence this warning.\n",
|
||||
" df = pl.DataFrame(data_rows, fields)\n"
|
||||
"14 DbFileOutput\n",
|
||||
"15 TextInput\n",
|
||||
"shape: (3, 3)\n",
|
||||
"┌─────┬────────┬───────┐\n",
|
||||
"│ Ham ┆ Cheese ┆ Count │\n",
|
||||
"│ --- ┆ --- ┆ --- │\n",
|
||||
"│ str ┆ str ┆ str │\n",
|
||||
"╞═════╪════════╪═══════╡\n",
|
||||
"│ a ┆ a ┆ 4 │\n",
|
||||
"│ b ┆ d ┆ 6 │\n",
|
||||
"│ c ┆ z ┆ 7 │\n",
|
||||
"└─────┴────────┴───────┘\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
|
|
@ -369,7 +485,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 292,
|
||||
"execution_count": 135,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
|
|
@ -378,79 +494,85 @@
|
|||
"text": [
|
||||
"\n",
|
||||
"############### Input dataframe (TextInput):\n",
|
||||
"\n",
|
||||
" shape: (3, 2)\n",
|
||||
"┌──────────┬──────────┐\n",
|
||||
"│ Column 3 ┆ Column 4 │\n",
|
||||
"│ --- ┆ --- │\n",
|
||||
"│ i64 ┆ i64 │\n",
|
||||
"╞══════════╪══════════╡\n",
|
||||
"│ 5 ┆ 8 │\n",
|
||||
"│ 6 ┆ 9 │\n",
|
||||
"│ 7 ┆ 10 │\n",
|
||||
"└──────────┴──────────┘\n",
|
||||
" shape: (3, 4)\n",
|
||||
"┌──────────┬──────────┬─────┬────────┐\n",
|
||||
"│ Column 3 ┆ Column 4 ┆ Ham ┆ Cheese │\n",
|
||||
"│ --- ┆ --- ┆ --- ┆ --- │\n",
|
||||
"│ str ┆ str ┆ str ┆ str │\n",
|
||||
"╞══════════╪══════════╪═════╪════════╡\n",
|
||||
"│ 5 ┆ 8 ┆ z ┆ a │\n",
|
||||
"│ 6 ┆ 9 ┆ b ┆ d │\n",
|
||||
"│ 7 ┆ 10 ┆ c ┆ c │\n",
|
||||
"└──────────┴──────────┴─────┴────────┘\n",
|
||||
"\n",
|
||||
"############### Generated code from Select tool: \n",
|
||||
"\n",
|
||||
" df_output = df.with_columns(\n",
|
||||
"df.select(pl.col(f'Column 3').alias('Col_3_renamed')),\n",
|
||||
")\n",
|
||||
"df_output = df_output.drop(f'Column 3')\n",
|
||||
"df_output = df_output.drop(f'Column 4')\n",
|
||||
"\n",
|
||||
"shape: (3, 1)\n",
|
||||
"┌───────────────┐\n",
|
||||
"│ Col_3_renamed │\n",
|
||||
"│ --- │\n",
|
||||
"│ i64 │\n",
|
||||
"╞═══════════════╡\n",
|
||||
"│ 5 │\n",
|
||||
"│ 6 │\n",
|
||||
"│ 7 │\n",
|
||||
"└───────────────┘\n"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "stderr",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"/tmp/ipykernel_579015/3571569777.py:9: DataOrientationWarning: Row orientation inferred during DataFrame construction. Explicitly specify the orientation by passing `orient=\"row\"` to silence this warning.\n",
|
||||
" df = pl.DataFrame(data_rows, fields)\n"
|
||||
"\n",
|
||||
"############### Output DF: \n",
|
||||
"\n",
|
||||
" shape: (3, 3)\n",
|
||||
"┌─────┬────────┬───────────────┐\n",
|
||||
"│ Ham ┆ Cheese ┆ Col_3_renamed │\n",
|
||||
"│ --- ┆ --- ┆ --- │\n",
|
||||
"│ str ┆ str ┆ str │\n",
|
||||
"╞═════╪════════╪═══════════════╡\n",
|
||||
"│ z ┆ a ┆ 5 │\n",
|
||||
"│ b ┆ d ┆ 6 │\n",
|
||||
"│ c ┆ c ┆ 7 │\n",
|
||||
"└─────┴────────┴───────────────┘\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"# Tool 1: TextInput\n",
|
||||
"xml_tool1 = results[3][1]\n",
|
||||
"df_in = TextInputToDf(ToolXML)\n",
|
||||
"\n",
|
||||
"print(\"\\n############### Input dataframe (TextInput):\\n\\n\", df_in)\n",
|
||||
"\n",
|
||||
"df_in = input_textInput(xml_tool1)\n",
|
||||
"print(\"\\n############### Input dataframe (TextInput):\\n\", df_in)\n",
|
||||
"# Tool 2: Select\n",
|
||||
"col_spec = getConf_Select(results[4][1])\n",
|
||||
"\n",
|
||||
"# print(\"\\n############### Select tool spec taken from XML:\\n\\n\", col_spec)\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"# Generate code from \n",
|
||||
"code = tool_select(col_spec)\n",
|
||||
"\n",
|
||||
"print(\"\\n############### Generated code from Select tool: \\n\\n\", code)\n",
|
||||
"\n",
|
||||
"print(\"\\n############### Generated code from Select tool: \\n\", code)\n",
|
||||
"# Execute and display output\n",
|
||||
"df = df_in\n",
|
||||
"\n",
|
||||
"exec(code)\n",
|
||||
"\n",
|
||||
"print(df_output)\n",
|
||||
"\n"
|
||||
"print(\"\\n############### Output DF: \\n\\n\", df_output)"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 174,
|
||||
"execution_count": 92,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": []
|
||||
"outputs": [
|
||||
{
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"('1', '<Node ToolID=\"1\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.TextInput.TextInput\">\\n <Position x=\"54\" y=\"54\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <NumRows value=\"3\" />\\n <Fields>\\n <Field name=\"Column1\" />\\n <Field name=\"Column 2\" />\\n </Fields>\\n <Data>\\n <r>\\n <c>1</c>\\n <c>4</c>\\n </r>\\n <r>\\n <c>2</c>\\n <c>5</c>\\n </r>\\n <r>\\n <c>3</c>\\n <c>6</c>\\n </r>\\n </Data>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxTextInput\" />\\n </Node>\\n ')\n",
|
||||
"('2', '<Node ToolID=\"2\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.AlteryxSelect.AlteryxSelect\">\\n <Position x=\"186\" y=\"54\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <OrderChanged value=\"False\" />\\n <CommaDecimal value=\"False\" />\\n <SelectFields>\\n <SelectField field=\"Column1\" selected=\"True\" type=\"Int64\" size=\"8\" />\\n <SelectField field=\"Column 2\" selected=\"False\" type=\"WString\" size=\"3\" />\\n <SelectField field=\"*Unknown\" selected=\"False\" />\\n </SelectFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxSelect\" />\\n </Node>\\n ')\n",
|
||||
"('3', '<Node ToolID=\"3\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.BrowseV2.BrowseV2\">\\n <Position x=\"318\" y=\"54\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <TempFile>C:\\\\Users\\\\Casey\\\\AppData\\\\Local\\\\Temp\\\\Engine_4072_8b6c0740e308d445ab856d90eb0e4ee9_\\\\Engine_4072_93f5c2999bcb8c478c002b15166e2b45~.yxdb</TempFile>\\n <TempFileDataProfiling />\\n <Layout>\\n <View1>\\n <Hints>\\n <Table />\\n </Hints>\\n </View1>\\n </Layout>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxBrowseV2\" />\\n </Node>\\n ')\n",
|
||||
"('4', '<Node ToolID=\"4\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.TextInput.TextInput\">\\n <Position x=\"54\" y=\"246\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <NumRows value=\"3\" />\\n <Fields>\\n <Field name=\"Column 3\" />\\n <Field name=\"Column 4\" />\\n <Field name=\"Ham\" />\\n <Field name=\"Cheese\" />\\n </Fields>\\n <Data>\\n <r>\\n <c>5</c>\\n <c>8</c>\\n <c>z</c>\\n <c>a</c>\\n </r>\\n <r>\\n <c>6</c>\\n <c>9</c>\\n <c>b</c>\\n <c>d</c>\\n </r>\\n <r>\\n <c>7</c>\\n <c>10</c>\\n <c>c</c>\\n <c>c</c>\\n </r>\\n </Data>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxTextInput\" />\\n </Node>\\n ')\n",
|
||||
"('5', '<Node ToolID=\"5\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.AlteryxSelect.AlteryxSelect\">\\n <Position x=\"174\" y=\"246\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <OrderChanged value=\"False\" />\\n <CommaDecimal value=\"False\" />\\n <SelectFields>\\n <SelectField field=\"Column 3\" selected=\"True\" rename=\"Col_3_renamed\" />\\n <SelectField field=\"Column 4\" selected=\"False\" />\\n <SelectField field=\"*Unknown\" selected=\"True\" />\\n </SelectFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxSelect\" />\\n </Node>\\n ')\n",
|
||||
"('6', '<Node ToolID=\"6\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Formula.Formula\">\\n <Position x=\"174\" y=\"330\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <FormulaFields>\\n <FormulaField expression=\"[Count] + 10\" field=\"MoreCount\" size=\"4\" type=\"Int32\" />\\n </FormulaFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>MoreCount = [Count] + 10\\n</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxFormula\" />\\n </Node>\\n ')\n",
|
||||
"('7', '<Node ToolID=\"7\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Join.Join\">\\n <Position x=\"318\" y=\"258\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration joinByRecordPos=\"False\">\\n <JoinInfo connection=\"Left\">\\n <Field field=\"Ham\" />\\n <Field field=\"Cheese\" />\\n </JoinInfo>\\n <JoinInfo connection=\"Right\">\\n <Field field=\"Ham\" />\\n <Field field=\"Cheese\" />\\n </JoinInfo>\\n <SelectConfiguration>\\n <Configuration outputConnection=\"Join\">\\n <OrderChanged value=\"False\" />\\n <CommaDecimal value=\"False\" />\\n <SelectFields>\\n <SelectField field=\"Right_Ham\" selected=\"True\" rename=\"Right_Ham\" input=\"Right_\" />\\n <SelectField field=\"Right_Cheese\" selected=\"True\" rename=\"Right_Cheese\" input=\"Right_\" />\\n <SelectField field=\"Right_Column 3\" selected=\"True\" rename=\"Right_Column 3\" input=\"Right_\" type=\"V_String\" size=\"11\" />\\n <SelectField field=\"Right_Column 4\" selected=\"True\" rename=\"Right_Column 4\" input=\"Right_\" type=\"Int64\" size=\"8\" />\\n <SelectField field=\"*Unknown\" selected=\"True\" />\\n </SelectFields>\\n </Configuration>\\n </SelectConfiguration>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxJoin\" />\\n </Node>\\n ')\n",
|
||||
"('10', '<Node ToolID=\"10\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.BrowseV2.BrowseV2\">\\n <Position x=\"414\" y=\"342\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <TempFile>C:\\\\Users\\\\Casey\\\\AppData\\\\Local\\\\Temp\\\\Engine_4072_8b6c0740e308d445ab856d90eb0e4ee9_\\\\Engine_4072_ab9b90f8fc991440905d667f1d5c7325~.yxdb</TempFile>\\n <TempFileDataProfiling />\\n <Layout>\\n <View1>\\n <Hints>\\n <Table />\\n </Hints>\\n </View1>\\n </Layout>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxBrowseV2\" />\\n </Node>\\n ')\n",
|
||||
"('11', '<Node ToolID=\"11\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Formula.Formula\">\\n <Position x=\"270\" y=\"474\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <FormulaFields>\\n <FormulaField expression=\"[Engine.TempFilePath]\" field=\"Path\" size=\"1073741823\" type=\"V_WString\" />\\n </FormulaFields>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>Path = [Engine.TempFilePath]\\n</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxFormula\" />\\n </Node>\\n ')\n",
|
||||
"('12', '<Node ToolID=\"12\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.Sample.Sample\">\\n <Position x=\"150\" y=\"474\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <Mode>First</Mode>\\n <N>1</N>\\n <GroupFields orderChanged=\"False\" />\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>First 1</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxSample\" />\\n </Node>\\n ')\n",
|
||||
"('13', '<Node ToolID=\"13\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.BrowseV2.BrowseV2\">\\n <Position x=\"366\" y=\"474\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <TempFile>C:\\\\Users\\\\Casey\\\\AppData\\\\Local\\\\Temp\\\\Engine_4072_8b6c0740e308d445ab856d90eb0e4ee9_\\\\Engine_4072_dd72ded80941104b9b9be56761379cb2~.yxdb</TempFile>\\n <TempFileDataProfiling />\\n <Layout>\\n <View1>\\n <Hints>\\n <Table />\\n </Hints>\\n </View1>\\n </Layout>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxBrowseV2\" />\\n </Node>\\n ')\n",
|
||||
"('14', '<Node ToolID=\"14\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.DbFileOutput.DbFileOutput\">\\n <Position x=\"522\" y=\"258\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <File MaxRecords=\"\" FileFormat=\"0\">.\\\\SimpleWorkflowOut.csv</File>\\n <Passwords />\\n <Disable>False</Disable>\\n <FormatSpecificOptions>\\n <LineEndStyle>CRLF</LineEndStyle>\\n <Delimeter>,</Delimeter>\\n <ForceQuotes>False</ForceQuotes>\\n <HeaderRow>True</HeaderRow>\\n <CodePage>28591</CodePage>\\n <WriteBOM>True</WriteBOM>\\n </FormatSpecificOptions>\\n <MultiFile value=\"False\" />\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText>SimpleWorkflowOut.csv</DefaultAnnotationText>\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxDbFileOutput\" />\\n </Node>\\n ')\n",
|
||||
"('15', '<Node ToolID=\"15\">\\n <GuiSettings Plugin=\"AlteryxBasePluginsGui.TextInput.TextInput\">\\n <Position x=\"54\" y=\"330\" />\\n </GuiSettings>\\n <Properties>\\n <Configuration>\\n <NumRows value=\"3\" />\\n <Fields>\\n <Field name=\"Ham\" />\\n <Field name=\"Cheese\" />\\n <Field name=\"Count\" />\\n </Fields>\\n <Data>\\n <r>\\n <c>a</c>\\n <c>a</c>\\n <c>4</c>\\n </r>\\n <r>\\n <c>b</c>\\n <c>d</c>\\n <c>6</c>\\n </r>\\n <r>\\n <c>c</c>\\n <c>z</c>\\n <c>7</c>\\n </r>\\n </Data>\\n </Configuration>\\n <Annotation DisplayMode=\"0\">\\n <Name />\\n <DefaultAnnotationText />\\n <Left value=\"False\" />\\n </Annotation>\\n </Properties>\\n <EngineSettings EngineDll=\"AlteryxBasePluginsEngine.dll\" EngineDllEntryPoint=\"AlteryxTextInput\" />\\n </Node>\\n ')\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"for tool in results:\n",
|
||||
" print(tool)"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
|
|
|
|||
Reference in New Issue