Repository navigation
chore: version packages - #152
Merged
Merged
Conversation
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.
Releases
@maple-dev/[email protected]
Minor Changes
05fbd7a: MySQL and MariaDB generated columns:
MySQL.column(type, { generated: { as, stored? } })declares aGENERATED ALWAYS AS (<as>) STORED | VIRTUALcolumn.asis SQL, or a DSL callback that may read the row's columns. The column is computed, as a ClickHouseMATERIALIZEDone is: an insert row, an update SET oronDuplicateKeyUpdatethat writes it is a type error and refused at runtime,excludedAllskips it, andtableSchemas(table).insert/.updateleave it out; selects read it. It works onexternal: truetables, where it only marks the column computed, so an insert into a table another tool owns no longer sends a column MySQL refuses.On an owned table the DDL writes
`col` <type> GENERATED ALWAYS AS (<expr>) STORED|VIRTUALwith noNOT NULL(MariaDB refuses it there) and no default, so declareMySQL.nullable(...)unless the expression cannot be NULL. Definition problems: adefault,defaultExpr,defaultFnoronUpdatebeside it (also a type error), an emptyas, a generated primary key or tenant column, and, for a callback only, one that reads itself, a generated column declared after it, or a nullable column into a non-nullable type. A stringasis not checked.effect-orm generatecreates and adds such columns (a new generated oneAFTERthe column before it), andMODIFYs a changed expression or type, and a base column made STORED (which needsconfirm_data_loss) or a STORED one made base (which keeps its values). A column made VIRTUAL, or a VIRTUAL one made STORED or base, is dropped and added back in oneALTER TABLE, in its place and with its indexes around it; to or from base needsconfirm_data_loss, and a VIRTUAL column made base under a UNIQUE key is refused as unsupported. The ops are ordered around what generated columns read: base columns are added first and generated ones dropped first, and the generated columns reading a column that is renamed or dropped and added back (including ones renamed or replaced themselves) are dropped before it, last declared first, and added back after in declaration order.MySQL.ComputedColumnsOfandMySQL.GeneratedColumnare new types, andMysqlSchemaTabletakes the computed columns as a new last type parameter.MysqlColumnEntityhas an optionalgenerated: { expr, stored, reads? }(reads: the columns a callback read), absent on other columns, so existing snapshots keep their ids.MysqlMigrationOphas areplace_columnop, andadd_columnan optionalafter.Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.