-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Sync Repos: Bringing commits for release 161.9135.0 (#89)
* [Security] Update .NET SDK to latest patch version This change updates to the latest patch version for the .NET SDK which contains the latest security fixes. Note that your global.json does configure `rollForward`, however roll forward will allow for the build to pass when using a different SDK. So, if locally you have a newer patch version installed it will pass, without the `rollforward` it will fail. CI in many cases installs exactly what is in the global.json, so making sure that your build requires the latest patch version ensures that CI is compliant with those vulnerabilities. --- For feedback or questions about this PR, please contact the [Gardener team](mailto:gardener@microsoft.com). --- This change was automatically generated by [1ES Gardener](https://eng.ms/docs/cloud-ai-platform/devdiv/one-engineering-system-1es/1es-docs/gardener/1es-gardener) (a [MerlinBot](https://aka.ms/MerlinBot) extension) which is an initiative by the 1ES team to help repos stay up-to-date with latest tools, features, and best practices. * [Security] Update .NET SDK to latest patch version This change updates to the latest patch version for the .NET SDK which contains the latest security fixes. Note that your global.json does configure `rollForward`, however roll forward will allow for the build to pass when using a different SDK. So, if locally you have a newer patch version installed it will pass, without the `rollforward` it will fail. CI in many cases installs exactly what is in the global.json, so making sure that your build requires the latest patch version ensures that CI is compliant with those vulnerabilities. Release notes: * [6.0.32](https://github.com/dotnet/core/blob/main/release-notes/6.0/6.0.32/6.0.32.md) The following CVEs will be addressed by this update: * [CVE-2024-38081](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-38081) * [CVE-2024-38095](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-38095) --- For feedback or questions about this PR, please contact the [Gardener team](mailto:gardener@microsoft.com). --- This change was automatically generated by [1ES Gardener](https://eng.ms/docs/cloud-ai-platform/devdiv/one-engineering-system-1es/1es-docs/gardener/1es-gardener) (a [MerlinBot](https://aka.ms/MerlinBot) extension) which is an initiative by the 1ES team to help repos stay up-to-date with latest tools, features, and best practices. * Merged PR 1417651: Add tests for Json data type in scriptdom This PR adds tests for Json data type in ScriptDom. ##Test added - ALTER TABLE T ADD jsonCol JSON; - ALTER TABLE T ALTER COLUMN col JSON; - Create function with Json data type as parameter; - Create stored procedure with Json data type as parameter; - Convert Char to Json; - Convert NChar to Json; - Convert Varchar to Json; - Convert NVarchar to Json; - Convert Json to Char; - Convert Json to NChar; - Convert Json to Varchar; - Convert Json to NVarchar; - Cast Char to Json; - Cast NChar to Json; - Cast Varchar to Json; - Cast NVarchar to Json; - Cast Json to Char; - Cast Json to NChar; - Cast Json to Varchar; - Cast Json to NVarchar; ---- #### AI description (iteration 1) #### PR Classification New feature: Adding tests for JSON data type in ScriptDOM. #### PR Summary This pull request introduces tests for the JSON data type in ScriptDOM, ensuring proper handling and conversion of JSON data. - Added JSON conversion and casting tests in `Test/SqlDom/TestScripts/ExpressionTests160.sql`. - Created baseline for JSON conversion and casting tests in `Test/SqlDom/Baselines160/ExpressionTests160.sql`. - Added tests for JSON data type in function and procedure creation in `Test/SqlDom/TestScripts/CreateFunctionStatementTests160.sql` and `Test/SqlDom/TestScripts/CreateProcedureStatementTests160.sql`. - Included tests for altering tables to add or modify JSON columns in `Test/SqlDom/TestScripts/AlterTableStatementTests160.sql`. - Updated `Only160SyntaxTests.cs` to include new test scripts for JSON data type. Related work items: #2949474 * Merged PR 1415210: Adding forceseek to changetable Adding forceseek to changetable. fixing bug microsoft/DacFx#434 ---- #### AI description (iteration 1) #### PR Classification New feature #### PR Summary This pull request adds support for the `FORCESEEK` hint in `CHANGETABLE` queries. - `/SqlScriptDom/Parser/TSql/TSql140.g`, `/SqlScriptDom/Parser/TSql/TSql130.g`, `/SqlScriptDom/Parser/TSql/TSql150.g`, `/SqlScriptDom/Parser/TSql/TSql160.g`: Updated grammar to support `FORCESEEK` in `CHANGETABLE` queries. - `/SqlScriptDom/Parser/TSql/Ast.xml`: Added `ForceSeek` property to `ChangeTableChangesTableReference` and `ChangeTableVersionTableReference` classes. - `/SqlScriptDom/ScriptDom/SqlServer/ScriptGenerator/SqlScriptGeneratorVisitor.ChangeTableTableSource.cs`: Implemented code generation for `FORCESEEK` hint. - `/Test/SqlDom/Baselines150/FromClauseTests150.sql`, `/Test/SqlDom/TestScripts/FromClauseTests150.sql`: Added test cases for `FORCESEEK` in `CHANGETABLE` queries. - `/Test/SqlDom/Only150SyntaxTests.cs`: Updated test expectations to include new `FORCESEEK` test cases. * Merged PR 1420062: Added test script for vector native data type Added test script for expression, ereate table, stored procedure, functions tests with vector native type ---- #### AI description (iteration 1) #### PR Classification New feature: Added test script for vector native data type. #### PR Summary This pull request introduces test scripts and updates to support the vector native data type in SQL. - Added test cases for casting and converting between `vector` and other data types in `/Test/SqlDom/TestScripts/ExpressionTests160.sql` and `/Test/SqlDom/Baselines160/ExpressionTests160.sql`. - Created stored procedures and functions utilizing the `vector` data type in `/Test/SqlDom/TestScripts/CreateProcedureStatementTests160.sql`, `/Test/SqlDom/Baselines160/CreateProcedureStatementTests160.sql`, `/Test/SqlDom/TestScripts/CreateFunctionStatementTests160.sql`, and `/Test/SqlDom/Baselines160/CreateFunctionStatementTests160.sql`. - Updated `SqlDataTypeOption` and related parser files to include the `vector` data type in `/SqlScriptDom/Parser/TSql/SqlDataTypeOption.cs`, `/SqlScriptDom/Parser/TSql/TSql80ParserBaseInternal.cs`, `/SqlScriptDom/Parser/TSql/TSql160ParserBaseInternal.cs`, `/SqlScriptDom/Parser/TSql/CodeGenerationSupporter.cs`, and `/SqlScriptDom/ScriptDom/SqlServer/ScriptGenerator/SqlScriptGeneratorVisitor.SqlDataType.cs`. - Added a new table with a `vector` column in `/Test/SqlDom/TestScripts/CreateTableTests160.sql` and `/Test/SqlDom/Baselines160/CreateTableTests160.sql`. * Merged PR 1433433: Adding release notes for 161.9135 Adding release notes for 161.9135 ---- #### AI description (iteration 1) #### PR Classification Documentation update for release notes. #### PR Summary This pull request adds release notes for version 161.9135.0 of `Microsoft.SqlServer.TransactSql.ScriptDom`, detailing new features, fixed issues, and target platform support. - `release-notes/161.91/161.9135.0.md`: Added release notes including new support for native Vector type and FORCESEEK hint in CHANGETABLE function. --------- Co-authored-by: MerlinBot <MerlinBot> Co-authored-by: Lijun Ji <lijji@microsoft.com> Co-authored-by: Abhishek Kumar (MDD) <Kumar.Abhishek@microsoft.com>
- Loading branch information
1 parent
aa13f7e
commit d84cc30
Showing
27 changed files
with
371 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
ALTER TABLE T | ||
ADD jsonCol JSON; | ||
|
||
ALTER TABLE T ALTER COLUMN col JSON; |
19 changes: 19 additions & 0 deletions
19
Test/SqlDom/Baselines160/CreateFunctionStatementTests160.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
CREATE FUNCTION [ParameterizedFunction] | ||
(@parameter_name1 JSON) | ||
RETURNS JSON | ||
AS | ||
BEGIN | ||
RETURN '[30]'; | ||
END | ||
|
||
|
||
GO | ||
CREATE FUNCTION [ParameterizedVectorFunction] | ||
(@parameter_name1 VECTOR (2)) | ||
RETURNS VECTOR (2) | ||
AS | ||
BEGIN | ||
DECLARE @v1 AS VECTOR (2); | ||
SET @v1 = CAST (N'[1,1]' AS VECTOR (2)); | ||
RETURN @v1; | ||
END |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
SELECT CONVERT (JSON, CONVERT (CHAR (300), '{}')); | ||
|
||
SELECT CONVERT (JSON, CONVERT (NCHAR (300), '{}')); | ||
|
||
SELECT CONVERT (JSON, CONVERT (VARCHAR (MAX), '{}')); | ||
|
||
SELECT CONVERT (JSON, CONVERT (NVARCHAR (300), '{}')); | ||
|
||
SELECT CONVERT (CHAR (300), CONVERT (JSON, '{}')); | ||
|
||
SELECT CONVERT (NCHAR (300), CONVERT (JSON, '{}')); | ||
|
||
SELECT CONVERT (VARCHAR (300), CONVERT (JSON, '{}')); | ||
|
||
SELECT CONVERT (NVARCHAR (MAX), CONVERT (JSON, '{}')); | ||
|
||
SELECT CAST (CAST ('{}' AS CHAR (300)) AS JSON); | ||
|
||
SELECT CAST (CAST ('{}' AS NCHAR (300)) AS JSON); | ||
|
||
SELECT CAST (CAST ('{}' AS VARCHAR (MAX)) AS JSON); | ||
|
||
SELECT CAST (CAST ('{}' AS NVARCHAR (300)) AS JSON); | ||
|
||
SELECT CAST (CAST ('{}' AS JSON) AS CHAR (300)); | ||
|
||
SELECT CAST (CAST ('{}' AS JSON) AS NCHAR (300)); | ||
|
||
SELECT CAST (CAST ('{}' AS JSON) AS VARCHAR (300)); | ||
|
||
SELECT CAST (CAST ('{}' AS JSON) AS NVARCHAR (MAX)); | ||
|
||
SELECT CONVERT (VECTOR (2), CONVERT (VARCHAR (MAX), '[1,1]')); | ||
|
||
SELECT CONVERT (VECTOR (2), CONVERT (NVARCHAR (MAX), N'[1,1]')); | ||
|
||
SELECT CONVERT (VECTOR (2), CONVERT (JSON, '[1,1]')); | ||
|
||
SELECT CAST (CAST ('[1,1]' AS VARCHAR (MAX)) AS VECTOR (2)); | ||
|
||
SELECT CAST (CAST (N'[1,1]' AS NVARCHAR (MAX)) AS VECTOR (2)); | ||
|
||
SELECT CAST (CAST ('[1,1]' AS JSON) AS VECTOR (2)); | ||
|
||
SELECT CONVERT (VARCHAR (MAX), CONVERT (VECTOR (3), '[0.1, 0.2, 0.1]')); | ||
|
||
SELECT CONVERT (NVARCHAR (MAX), CONVERT (VECTOR (3), '[0.1, 0.2, 0.1]')); | ||
|
||
SELECT CONVERT (JSON, CONVERT (VECTOR (3), '[0.1, 0.2, 0.1]')); | ||
|
||
SELECT CAST (CAST ('[0.1, 0.1, 0.1]' AS VECTOR (3)) AS VARCHAR (MAX)); | ||
|
||
SELECT CAST (CAST ('[0.1, 0.1, 0.1]' AS VECTOR (3)) AS NVARCHAR (MAX)); | ||
|
||
SELECT CAST (CAST ('[0.1, 0.1, 0.1]' AS VECTOR (3)) AS JSON); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.