-
Notifications
You must be signed in to change notification settings - Fork 6k
Bulk fix for quoted @ that break LOC builds #5962
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
Conversation
|
#Sign-off |
|
We don't have PR merger on .NET docs @v-alje 😄 I'll take a look at your changes now |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes look good but left some comments to be addressed or answered @v-alje. Thanks!
| |IdentifierCase|<xref:System.Data.Common.IdentifierCase>|Indicates whether non-quoted identifiers are treated as case sensitive or not.| | ||
| |OrderByColumnsInSelect|bool|Specifies whether columns in an ORDER BY clause must be in the select list. A value of true indicates that they are required to be in the select list, a value of false indicates that they are not required to be in the select list.| | ||
| |ParameterMarkerFormat|string|A format string that represents how to format a parameter.<br /><br /> If named parameters are supported by the data source, the first placeholder in this string should be where the parameter name should be formatted.<br /><br /> For example, if the data source expects parameters to be named and prefixed with an ‘:’ this would be ":{0}". When formatting this with a parameter name of "p1" the resulting string is ":p1".<br /><br /> If the data source expects parameters to be prefixed with the ‘@’, but the names already include them, this would be ‘{0}’, and the result of formatting a parameter named "@p1" would simply be "@p1".<br /><br /> For data sources that do not expect named parameters and expect the use of the ‘?’ character, the format string can be specified as simply ‘?’, which would ignore the parameter name. For OLE DB we return ‘?’.| | ||
| |ParameterMarkerFormat|string|A format string that represents how to format a parameter.<br /><br /> If named parameters are supported by the data source, the first placeholder in this string should be where the parameter name should be formatted.<br /><br /> For example, if the data source expects parameters to be named and prefixed with an ‘:’ this would be ":{0}". When formatting this with a parameter name of "p1" the resulting string is ":p1".<br /><br /> If the data source expects parameters to be prefixed with the ‘@’, but the names already include them, this would be ‘{0}’, and the result of formatting a parameter named "\@p1" would simply be "\@p1".<br /><br /> For data sources that do not expect named parameters and expect the use of the ‘?’ character, the format string can be specified as simply ‘?’, which would ignore the parameter name. For OLE DB we return ‘?’.| |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see one ‘@’ that was not escaped. By design?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue found is believed to be just the combination of the quote next to the at "@.
| For a given DbInsertCommandTree in the sample provider, the generated insert command follows one of the two insert templates below. | ||
|
|
||
| The first template has a command to perform the insert given the values in the list of SetClauses, and a SELECT statement to return the properties specified in the Returning property for the inserted row if the Returning property was not null. The predicate element "@@ROWCOUNT > 0" is true if a row was inserted. The predicate element "keyMemberI = keyValueI | scope_identity()" takes the shape "keyMemberI = scope_identity()" only if keyMemeberI is a store-generated key, because scope_identity() returns the last identity value inserted into an identity (store-generated) column. | ||
| The first template has a command to perform the insert given the values in the list of SetClauses, and a SELECT statement to return the properties specified in the Returning property for the inserted row if the Returning property was not null. The predicate element "\@@ROWCOUNT > 0" is true if a row was inserted. The predicate element "keyMemberI = keyValueI | scope_identity()" takes the shape "keyMemberI = scope_identity()" only if keyMemeberI is a store-generated key, because scope_identity() returns the last identity value inserted into an identity (store-generated) column. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you need to scape each @ on @@rowcount, no?
Also, I think the best for loc on this sentence would be codefence with backticks where code is used instead of quotes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue found is believed to be just the combination of the quote next to the at "@.
Backticks would likely be best. But this is a bulk update fix. The writer should look into using Backticks.
| |ColumnName|DataType|Description| | ||
| |----------------|--------------|-----------------| | ||
| |CompositeIdentifierSeparatorPattern|string|The regular expression to match the composite separators in a composite identifier. For example, "\\." (for SQL Server) or "@|\\." (for Oracle).<br /><br /> A composite identifier is typically what is used for a database object name, for example: pubs.dbo.authors or pubs@dbo.authors.<br /><br /> For SQL Server, use the regular expression "\\.". For OracleClient, use "@|\\.".<br /><br /> For ODBC use the Catalog_name_seperator.<br /><br /> For OLE DB use DBLITERAL_CATALOG_SEPARATOR or DBLITERAL_SCHEMA_SEPARATOR.| | ||
| |CompositeIdentifierSeparatorPattern|string|The regular expression to match the composite separators in a composite identifier. For example, "\\." (for SQL Server) or "\@|\\." (for Oracle).<br /><br /> A composite identifier is typically what is used for a database object name, for example: pubs.dbo.authors or pubs@dbo.authors.<br /><br /> For SQL Server, use the regular expression "\\.". For OracleClient, use "\@|\\.".<br /><br /> For ODBC use the Catalog_name_seperator.<br /><br /> For OLE DB use DBLITERAL_CATALOG_SEPARATOR or DBLITERAL_SCHEMA_SEPARATOR.| |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
doesn't the @ at the email address need to be encoded too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue found is believed to be just the combination of the quote next to the at "@ at the moment..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good. Thanks @v-alje!
Bulk fix replacing "@ with "\@ to fix cases for LOC where extra spans are getting created. User Story 1244910