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

Address issues with revert in Edit Data and also add trim to string data from cells. #24906

Merged
merged 3 commits into from
Nov 9, 2023

Conversation

smartguest
Copy link
Contributor

This is to fix an issue with edit data upon revert for an invalid edit causing the current Cell to become reset when it should only be done for manual revert. (This results in additional edits after the revert on the cell not working until you move to a different row or refresh the edit session entirely).

Additionally, this PR addresses a bug where empty spaces at the end are a part of the value retrieved from the cell and that failure to delete those or overwrite them causes a "exceeded length" error, this PR adds trimming to values from the cell (and it still registers as being unchanged by the editor).

@coveralls
Copy link

Pull Request Test Coverage Report for Build 6788992394

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 3 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.002%) to 41.571%

Files with Coverage Reduction New Missed Lines %
extensions/sql-database-projects/src/common/httpClient.ts 1 66.18%
extensions/sql-database-projects/src/dialogs/publishDatabaseDialog.ts 2 52.03%
Totals Coverage Status
Change from base Build 6780078081: -0.002%
Covered Lines: 30785
Relevant Lines: 69355

💛 - Coveralls

@smartguest
Copy link
Contributor Author

Issue has been linked

@cheenamalhotra cheenamalhotra linked an issue Nov 8, 2023 that may be closed by this pull request
@smartguest smartguest merged commit 0bfcbeb into main Nov 9, 2023
12 checks passed
@smartguest smartguest deleted the alex/smallfixtoeditdataissues11-2-2023 branch November 9, 2023 00:22
@@ -232,10 +232,12 @@ export class EditDataGridPanel extends GridParentComponent {
// If a cell is not edited and retrieved direct from the SQL server, it would be in the form of a DBCellValue.
// We use the DBCellValue's cleaned displayValue as the text value.
returnVal = this.replaceLinebreaks(value.displayValue);
returnVal = returnVal.trim();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if the user actually wants to add spaces to the beginning/end of the string? Isn't this going to prevent that from happening?

siyao-Siyang pushed a commit that referenced this pull request Nov 13, 2023
…ata from cells. (#24906)

* small fix to edit data minor issues

* Added trim for values retrieved from cell.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Edit Data Bugs when revert and after clicking cell.
4 participants