Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enable update counts for SELECT INTO statements #175

Merged
merged 6 commits into from
Mar 8, 2017
Merged

enable update counts for SELECT INTO statements #175

merged 6 commits into from
Mar 8, 2017

Conversation

gordthompson
Copy link
Contributor

fix for issue discussed on Stack Overflow here, where SELECT ... INTO statements always return an update count of -1

@codecov-io
Copy link

codecov-io commented Mar 7, 2017

Codecov Report

Merging #175 into dev will increase coverage by 0.45%.
The diff coverage is 50%.

@@             Coverage Diff             @@
##               dev     #175      +/-   ##
===========================================
+ Coverage     29.7%   30.15%   +0.45%     
- Complexity    1248     1273      +25     
===========================================
  Files           97       97              
  Lines        23305    23307       +2     
  Branches      3871     3872       +1     
===========================================
+ Hits          6923     7029     +106     
+ Misses       15028    14881     -147     
- Partials      1354     1397      +43
Flag Coverage Δ Complexity Δ
#JDBC41 30.07% <50%> (+0.47%) 1269 <0> (+24)
#JDBC42 30.11% <50%> (+0.53%) 1272 <0> (+28)
Impacted Files Coverage Δ Complexity Δ
.../java/com/microsoft/sqlserver/jdbc/StreamDone.java 63.63% <ø> (+13.63%) 16 <0> (+2)
...m/microsoft/sqlserver/jdbc/SQLServerStatement.java 53.69% <50%> (+0.8%) 109 <0> (+2)
src/main/java/microsoft/sql/DateTimeOffset.java 37.14% <0%> (-2.86%) 8% <0%> (-2%)
...om/microsoft/sqlserver/jdbc/SQLServerBulkCopy.java 45.01% <0%> (-0.8%) 183% <0%> (+1%)
.../microsoft/sqlserver/jdbc/SQLServerConnection.java 38.86% <0%> (+0.08%) 193% <0%> (+3%)
...in/java/com/microsoft/sqlserver/jdbc/IOBuffer.java 33.46% <0%> (+1.35%) 0% <0%> (ø)
...oft/sqlserver/jdbc/SQLServerPreparedStatement.java 20.62% <0%> (+1.61%) 53% <0%> (+2%)
...m/microsoft/sqlserver/jdbc/SQLServerResultSet.java 19.89% <0%> (+1.95%) 144% <0%> (+17%)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 369e5e0...39f1fba. Read the comment docs.

@AfsanehR-zz AfsanehR-zz added the Under Review Used for pull requests under review label Mar 7, 2017
@AfsanehR-zz AfsanehR-zz requested review from AfsanehR-zz and removed request for AfsanehR-zz March 7, 2017 00:38
@AfsanehR-zz AfsanehR-zz self-assigned this Mar 7, 2017
@AfsanehR-zz
Copy link
Contributor

@gordthompson Thank you for the fix you provided! Your pr is fixing the issue you mentioned.
However, it caused a failure in our test lab which I had added the repro code as a test in this pr. Please have a look and test it. I will then go ahead and accept this pull request. Thanks again!

@gordthompson
Copy link
Contributor Author

@v-afrafi Thanks for the follow-up. Your RegressionTest worked fine for me once I tweaked the DROP TABLE to run under SQL_2014. Using your test as an example I then added SelectIntoUpdateCountTest to verify the results of my original modification. Hope this helps.

@AfsanehR-zz
Copy link
Contributor

@gordthompson awesome! good catch.
Can you just move the new test under the same Regression class? Thank you.

@gordthompson
Copy link
Contributor Author

@v-afrafi

Can you just move the new test under the same Regression class?

Done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Under Review Used for pull requests under review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants