Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #1124 +/- ##
===========================================
- Coverage 79.08% 79.07% -0.01%
===========================================
Files 159 159
Lines 14935 14935
===========================================
- Hits 11811 11810 -1
- Misses 2712 2713 +1
Partials 412 412 see 2 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
cade-conklin
left a comment
There was a problem hiding this comment.
Make sure to rebase to develop
| } | ||
| } | ||
| } | ||
| func TestParseSQLWith(t *testing.T) { |
There was a problem hiding this comment.
Add a test case using WHERE as not the first word to be parsed and check if proper operation is picked up. Could be as a subquery added to TestParseSQLSubQuery or add a test checking WITH and operations where Input contains multiple queries i.e.
{Input: "Select * FROM cte; WITH cte AS (SELECT * FROM users) SELECT * FROM cte;", Operation: "select", Table: "cte"}
| } | ||
| func TestParseSQLWith(t *testing.T) { | ||
| for _, tc := range []sqlTestcase{ | ||
| {Input: "WITH cte AS (SELECT * FROM users) SELECT * FROM cte", Operation: "with", Table: ""}, |
There was a problem hiding this comment.
Does Table (newrelic.DatastoreSegment.Collection) not get populated in this case?
Add support for "WITH" clause in SQL parsing
Addresses #1121