question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Regression 1.12 -> 2.x with CREATE TABLE AS (...) requests

See original GitHub issue

I use sql-metadata (great module btw) to extract tables used by CREATE TABLE requests. I recently upgraded sql-metadata to 2.X, and broke my entire code 😢

Behavior with sql-metadata 1.12 (Good, at least for my use case)

>>> from sql_metadata import get_query_tables
>>> sql = CREATE TABLE records AS (SELECT t.id, t.name, e.name as energy FROM t JOIN e ON t.e_id = e.id)
>>> get_query_tables(sql)
['records', 't', 'e']

Behavior with sql-metadata 2.X (Less good…)

>>> from sql_metadata.compat import get_query_tables
>>> from sql_metadata import Parser
>>> sql = CREATE TABLE records AS (SELECT t.id, t.name, e.name as energy FROM t JOIN e ON t.e_id = e.id)
>>> get_query_tables(sql)
['records']
>>> Parser(sql).tables
['records']

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

3reactions
macbrecommented, Jun 9, 2021

I can’t disagree with the Agile buzzword 😆 Will prepare the v2.2 release shortly.

1reaction
collerekcommented, Jun 9, 2021

@macbre this one also should be fixed by #157 (sample query provided was tested).

I would expect that gentlemen would be thankful for a release as you cannot pin the version from GitHub (although I think you can install given commit?).

What is your view on shortening change to release period and release more but smaller versions?

You know, it’s more <buzzword>agile</buzzword>🤣

Read more comments on GitHub >

github_iconTop Results From Across the Web

Stata Customizable Tables and Collected Results Reference ...
1. You want to create a table showing the results from more than one command. 2. You want to customize how a table...
Read more >
Regression with Stata Chapter 3 - OARC Stats
Based on the regression results, non year- round schools have scores that are 160.5 points higher than year- round schools. 3.3 Regression with...
Read more >
12.1 - Logistic Regression | STAT 462
Logistic regression models a relationship between predictor variables and a categorical response variable. For example, we could use logistic regression to ...
Read more >
Practical Regression and Anova using R
There are many books on regression and analysis of variance. ... 1.1.2 Data Collection . ... Table 3.1: Analysis of Variance table.
Read more >
Low performance of setkey function for version 1.12.0 and later
To make sure where this came from, I ran the same code with several versions of data.table, from 1.10.4 to 1.13.2 in the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found