Alteryx Designer Desktop Discussions

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

Virtual environments in Python and MDX-Queries

MathiasL
7 - Meteor

Hi everyone,

we have implemented a project in our organization where data is queried using MDX query and processed via Python and then written into a .csv-file. Generally I would like to do this in Alteryx, because we would now have the possibility for scheduling through the server, but there are still the following ambiguities/problems and maybe someone of you has already made experiences with this:

 

  1. Is there a way to query data from an OLAP database using MDX in Python at all? I haven't found anything for the time being and only heard about a third-party solution, but that would be a no acceptable solution for us.
  2. Assuming there is no official Alteryx solution: How can a Python code on a Virtual Environment be executed using the Alteryx Python tool? (Reason: We are using the pyadomd - library in Python and it is not compatible with the latest Python version, hence the detour via the Virtual Environment).

Thanks in advance & best regards

Mathias

5 REPLIES 5
TimN
13 - Pulsar

Hi,

You can install Python Libraries to Alteryx Server in their one environment.  My understanding (we're on 2021.3) is you can't create virtual environments.  I think this means you need to maintain a single prod environment with one set of python libraries.  We asked for a feature where Alteryx supports virtual environments but no luck yet.

 

The current state makes it more challenging for maintenance.

 

Regards.

TimN
13 - Pulsar

Here's a link to the Idea that was requesting Virtual Environments.

 

https://community.alteryx.com/t5/Alteryx-Designer-Ideas/Python-Tool-Managing-Virtual-Environments-ve...

MathiasL
7 - Meteor

Ok, although thanks @TimN  for your quick answer. Then I won't switch to the alteryx solution because pyadomd is only supported up to python version 3.8 and older and the version in alteryx is anywhere at >=3.9.

Thableaus
17 - Castor
17 - Castor

@MathiasL 

 

You can still run python via the Run Command tool. Obviously it's harder to configure and most likely you will need to generate a file to read the results that come out of your python script, but still can be used as a workaround if you're working with different versions of Python.

 

Cheers,

MathiasL
7 - Meteor

Good point. I completely forgot about the run command tool. Thanks for reminding me - I will probably look for a solution in this direction.

 

Regards

Labels