I have heard a lot about ChatGPT recently, both for entertainment and problem solving. As a knowledge worker, I try to keep ChatGPT in mind throughout my day, looking for ways to work smarter, not harder, or automate parts of tasks that cannot be entirely automated.

Here are some problems I have found ChatGPT can solve and some I found it cannot (yet).

Update April 2023: In the time since I have written this, the outputs have gotten somewhat better, especially using Bing Chat/ChatGPT 4, which did not exist at the time.

Explain code

Explain this Qlik load script:
LEFT JOIN (QVDField)
LOAD
_KeyQVDField, //key
[QVD Field Distinct Values] / ApplyMap('MapQVDRows', _KeyQVD, 0) as [QVD Field Distinct Pct],
If([QVD Field Distinct Values] = ApplyMap('MapQVDRows', _KeyQVD, 0), 'Y', 'N') as [QVD Field 100% Distinct Ind],
If(ApplyMap('MapQVDRows', _KeyQVD, 0) > 0 AND [QVD Field Distinct Values] = 0, 'Y', 'N') as [QVD Field 100% Null Ind]
RESIDENT
QVDField;

Explaining code is good if you are taking over someone else’s work, although it is obviously limited to the quality and accuracy of the existing solution, without any knowledge of what the original developer intended to do. It also has no context of the underlying data characteristics or upstream code, as you would expect.

On a related note, “simplify” and “reduce” did not work. (You can do that with WolframAlpha, however.) I would love to do this when you get an insane-looking expression and are wondering if it can be mathematically simplified without affecting the result.

Generate code to meet a specific need

If you’re new to a platform, think of this as natural language code generation or solutioning.

Let’s be real: this has not always been very accurate when I have tested it. It might be a good start for you to tweak or it may not make any sense.

I tried to come up with representative questions for this section, and both answers are not correct. For Power BI, it’s describing settings that don’t exist.

How do you calculate Sales for the Prior Year to Date in Tableau?

How do you conditionally hide objects in Power BI?

Translate between platforms or translate to something I understand better

For people who are new to a platform but also experienced in something else or converting between platforms, it can be helpful to have ChatGPT try to write the new code for you.

How would you write this DAX expression in Qlik?
CALCULATE (
[Sales]
, DATESYTD(DATEADD('Calendar'[Date], -1, YEAR))
)

The same caveat applies as the previous point about accuracy.

Challenges

Other than accuracy and no “confidence rating” alongside the answer (everything is answered with total confidence, even when wrong), the biggest limitation I have found is that your problem must be easy to define. As far as I know, you can’t input a data model with relationships and cardinality. You can’t draw a picture for ChatGPT (yet). It’s a chatbot, after all. The struggle to adequately contextualize leads me to make only very small asks.

I also assume ChatGPT will not solve novel problems or create novel solutions, just as Googling is limited to using other people’s answers to questions. It can help if you can give it something bite-sized to chew on, but it isn’t going to churn out an entire project’s output… at least the projects I work on. The value will come in your ability to learn how to ask questions effectively and develop the awareness and creativity to realize when ChatGPT can help solve problems or parts of problems.

Just for fun

This might be the best answer it gave me.