@sap/cds-compiler 2.15.8 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +102 -1590
- package/bin/.eslintrc.json +2 -1
- package/bin/cdsc.js +61 -46
- package/doc/API.md +11 -0
- package/doc/CHANGELOG_ARCHIVE.md +1592 -0
- package/doc/CHANGELOG_BETA.md +26 -5
- package/doc/CHANGELOG_DEPRECATED.md +55 -1
- package/doc/{DeprecatedOptions.md → DeprecatedOptions_v2.md} +3 -1
- package/doc/Versioning.md +20 -1
- package/lib/api/.eslintrc.json +2 -2
- package/lib/api/main.js +282 -156
- package/lib/api/options.js +17 -88
- package/lib/api/validate.js +6 -10
- package/lib/base/keywords.js +280 -110
- package/lib/base/message-registry.js +85 -25
- package/lib/base/messages.js +119 -89
- package/lib/base/model.js +46 -2
- package/lib/base/optionProcessorHelper.js +53 -21
- package/lib/checks/actionsFunctions.js +15 -12
- package/lib/checks/annotationsOData.js +1 -1
- package/lib/checks/cdsPersistence.js +1 -0
- package/lib/checks/elements.js +6 -6
- package/lib/checks/invalidTarget.js +1 -1
- package/lib/checks/nonexpandableStructured.js +1 -1
- package/lib/checks/queryNoDbArtifacts.js +2 -1
- package/lib/checks/selectItems.js +101 -15
- package/lib/checks/types.js +7 -8
- package/lib/checks/utils.js +2 -2
- package/lib/checks/validator.js +3 -3
- package/lib/compiler/assert-consistency.js +78 -21
- package/lib/compiler/base.js +6 -4
- package/lib/compiler/builtins.js +177 -10
- package/lib/compiler/checks.js +1 -1
- package/lib/compiler/define.js +28 -23
- package/lib/compiler/extend.js +75 -18
- package/lib/compiler/finalize-parse-cdl.js +25 -18
- package/lib/compiler/index.js +27 -11
- package/lib/compiler/moduleLayers.js +7 -0
- package/lib/compiler/populate.js +26 -39
- package/lib/compiler/propagator.js +12 -7
- package/lib/compiler/resolve.js +207 -236
- package/lib/compiler/shared.js +100 -93
- package/lib/compiler/tweak-assocs.js +13 -20
- package/lib/compiler/utils.js +20 -6
- package/lib/edm/annotations/preprocessAnnotations.js +12 -13
- package/lib/edm/csn2edm.js +35 -37
- package/lib/edm/edm.js +22 -13
- package/lib/edm/edmAnnoPreprocessor.js +349 -0
- package/lib/edm/edmInboundChecks.js +85 -0
- package/lib/edm/edmPreprocessor.js +338 -689
- package/lib/edm/edmUtils.js +97 -67
- package/lib/gen/Dictionary.json +29 -9
- package/lib/gen/language.checksum +1 -1
- package/lib/gen/language.interp +8 -31
- package/lib/gen/language.tokens +105 -114
- package/lib/gen/languageLexer.interp +1 -34
- package/lib/gen/languageLexer.js +892 -1007
- package/lib/gen/languageLexer.tokens +95 -106
- package/lib/gen/languageParser.js +20629 -22474
- package/lib/inspect/.eslintrc.json +4 -0
- package/lib/inspect/index.js +14 -0
- package/lib/inspect/inspectModelStatistics.js +81 -0
- package/lib/inspect/inspectPropagation.js +189 -0
- package/lib/inspect/inspectUtils.js +44 -0
- package/lib/json/from-csn.js +74 -69
- package/lib/json/to-csn.js +17 -14
- package/lib/language/antlrParser.js +2 -2
- package/lib/language/docCommentParser.js +61 -38
- package/lib/language/errorStrategy.js +52 -40
- package/lib/language/genericAntlrParser.js +424 -292
- package/lib/language/language.g4 +604 -687
- package/lib/language/multiLineStringParser.js +14 -42
- package/lib/language/textUtils.js +44 -0
- package/lib/main.d.ts +28 -42
- package/lib/main.js +104 -81
- package/lib/model/api.js +1 -1
- package/lib/model/csnRefs.js +57 -30
- package/lib/model/csnUtils.js +189 -287
- package/lib/model/revealInternalProperties.js +32 -10
- package/lib/model/sortViews.js +32 -31
- package/lib/modelCompare/compare.js +3 -0
- package/lib/optionProcessor.js +91 -57
- package/lib/render/.eslintrc.json +1 -1
- package/lib/render/DuplicateChecker.js +4 -7
- package/lib/render/manageConstraints.js +70 -2
- package/lib/render/toCdl.js +387 -367
- package/lib/render/toHdbcds.js +20 -16
- package/lib/render/toRename.js +44 -22
- package/lib/render/toSql.js +81 -59
- package/lib/render/utils/common.js +16 -3
- package/lib/render/utils/sql.js +20 -19
- package/lib/sql-identifier.js +6 -0
- package/lib/transform/db/.eslintrc.json +3 -2
- package/lib/transform/db/associations.js +43 -35
- package/lib/transform/db/cdsPersistence.js +5 -16
- package/lib/transform/db/constraints.js +1 -1
- package/lib/transform/db/expansion.js +7 -6
- package/lib/transform/db/flattening.js +16 -18
- package/lib/transform/db/transformExists.js +7 -5
- package/lib/transform/db/views.js +3 -3
- package/lib/transform/draft/.eslintrc.json +2 -2
- package/lib/transform/draft/db.js +6 -6
- package/lib/transform/draft/odata.js +6 -7
- package/lib/transform/forHanaNew.js +30 -24
- package/lib/transform/forOdataNew.js +14 -16
- package/lib/transform/localized.js +35 -25
- package/lib/transform/odata/toFinalBaseType.js +10 -10
- package/lib/transform/odata/typesExposure.js +17 -8
- package/lib/transform/odata/utils.js +1 -38
- package/lib/transform/transformUtilsNew.js +63 -77
- package/lib/transform/translateAssocsToJoins.js +2 -2
- package/lib/transform/universalCsn/.eslintrc.json +2 -2
- package/lib/transform/universalCsn/coreComputed.js +11 -6
- package/lib/transform/universalCsn/universalCsnEnricher.js +33 -5
- package/lib/utils/file.js +31 -21
- package/lib/utils/moduleResolve.js +0 -1
- package/lib/utils/timetrace.js +20 -21
- package/package.json +34 -4
- package/share/messages/syntax-expected-integer.md +9 -8
- package/doc/ApiMigration.md +0 -237
- package/doc/CommandLineMigration.md +0 -58
- package/doc/ErrorMessages.md +0 -175
- package/doc/FioriAnnotations.md +0 -94
- package/doc/ODataTransformation.md +0 -273
- package/lib/backends.js +0 -529
- package/lib/checks/unknownMagic.js +0 -41
- package/lib/fix_antlr4-8_warning.js +0 -56
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,107 @@
|
|
|
7
7
|
Note: `beta` fixes, changes and features are usually not listed in this ChangeLog but [here](doc/CHANGELOG_BETA.md).
|
|
8
8
|
The compiler behavior concerning `beta` features can change at any time without notice.
|
|
9
9
|
|
|
10
|
+
## Version 3.1.0 - 2022-08-04
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- Extending an artifact with multiple includes in one extend statement is now possible:
|
|
15
|
+
`extend SomeEntity with FirstInclude, SecondInclude;`
|
|
16
|
+
- Aspects can now have actions and functions, similar to entities. Aspects can be extended by actions as well.
|
|
17
|
+
- `cdsc`:
|
|
18
|
+
- `toCsn` now supports `--with-locations` which adds a `$location` property to artifacts
|
|
19
|
+
- `toHana`/`toSql` now supports `--disable-hana-comments`, which disables rendering of doc-comments for HANA.
|
|
20
|
+
- to.hdi/sql/hdbcds: Support FK-access in `ORDER BY` and `GROUP BY`
|
|
21
|
+
- to.hdi.migration: Detect an implicit change from `not null` to `null` and render corresponding `ALTER`
|
|
22
|
+
|
|
23
|
+
### Changed
|
|
24
|
+
|
|
25
|
+
- compiler: If an unknown file extension is used but the file starts with
|
|
26
|
+
an opening curly brace (`{`), it will be parsed as CSN.
|
|
27
|
+
- to.edm(x): In V4 containment mode, pull up `@Capabilities` annotations from the containees to the root container (set)
|
|
28
|
+
and translate them into corresponding `@Capabilities.NavigationRestrictions`. If a `NavigationRestriction` is already available
|
|
29
|
+
for that containment path, capabilities are merged into this path. Capability annotation value paths are prefixed with
|
|
30
|
+
the navigation restriction path.
|
|
31
|
+
The capability 'pull up' has an effect on entity annotations only. `@Capabilities` assignments on compositions are not pulled
|
|
32
|
+
up but rendered to the association type which is important to enable dynamic capabilities on 'to-many' relations and to avoid
|
|
33
|
+
ambiguities in entity set capabilities.
|
|
34
|
+
- Update OData vocabularies 'Analytics', 'Capabilities', 'Common', 'Core', 'DataIntegration', 'Graph', 'PersonalData', 'UI', 'Validation'.
|
|
35
|
+
|
|
36
|
+
### Fixed
|
|
37
|
+
|
|
38
|
+
- Syntax of date/time literals are now checked against ISO 8601. If the format is invalid, a warning is emitted.
|
|
39
|
+
- The code completion directly after the `(` for functions with special syntax
|
|
40
|
+
now suggests all valid keywords, like for `extract` or `locate_regexpr`.
|
|
41
|
+
- compiler:
|
|
42
|
+
+ `cast(elem as EnumType)` crashed the compiler.
|
|
43
|
+
+ Annotations on sub-elements in query entities were lost during re-compilation.
|
|
44
|
+
+ An association's cardinality was lost for associations published in projections.
|
|
45
|
+
+ Annotations on indirect action parameters were lost in CSN flavor `gensrc`.
|
|
46
|
+
+ If a file's content starts with `{` and if neither file extension is known nor
|
|
47
|
+
`fallbackParser` is set, assume the source is CSN.
|
|
48
|
+
- all backends: references in `order by` _expressions_ are correctly resolved.
|
|
49
|
+
- to.edm(x):
|
|
50
|
+
+ Allow cross service references for unmanaged associations and improve warning message for muted associations.
|
|
51
|
+
+ Nested `@UI.TextArrangement` has precedence over `@TextArrangement` shortcut annotation for `@Common.Text`.
|
|
52
|
+
- to.hdi.migration:
|
|
53
|
+
+ Doc comments rendered the _full doc comment_ instead of only the first paragraph, as `to.hdi` does.
|
|
54
|
+
+ Respect option `disableHanaComments` when rendering the `ALTER` statements
|
|
55
|
+
- to.hdi/sql/hdbcds:
|
|
56
|
+
+ Check for invalid usages of `$self` and give helpful errors
|
|
57
|
+
+ Correctly resolve association-steps in the from-clause in conjunction with `exists`
|
|
58
|
+
|
|
59
|
+
## Version 3.0.2 - 2022-07-05
|
|
60
|
+
|
|
61
|
+
### Fixed
|
|
62
|
+
|
|
63
|
+
- to.sql: For `sqlDialect` `plain`, `$now` is replaced by `CURRENT_TIMESTAMP` again.
|
|
64
|
+
- compiler:
|
|
65
|
+
+ Don't crash if a USING filename is invalid on the operating system, e.g. if `\0` is used.
|
|
66
|
+
+ Info messages for annotations on localized convenience views are only emitted for unknown ones.
|
|
67
|
+
+ Improve error message for an `extend` statement which had added a new element
|
|
68
|
+
and tried to extend that element further. Similarly for a new action.
|
|
69
|
+
(If you consider this really of any use, use two `extend` statements.)
|
|
70
|
+
- for.odata: expand `@readonly`/`@insertonly` on aspects as for entities into `@Capabilities`.
|
|
71
|
+
- to.edm(x):
|
|
72
|
+
+ Exclude managed association as primary key on value list annotation preprocessing.
|
|
73
|
+
+ Don't render annotations for aspects defined in a service.
|
|
74
|
+
|
|
75
|
+
## Version 3.0.0 - 2022-06-23
|
|
76
|
+
|
|
77
|
+
### Added
|
|
78
|
+
|
|
79
|
+
- Instead of requiring all files on startup, they are required on an as-needed basis to reduce startup times.
|
|
80
|
+
- CDL parser: support SQL functions `locate_regexpr`, `occurrences_regexpr`,
|
|
81
|
+
`replace_regexpr` and `substring_regexpr` with their special argument syntax.
|
|
82
|
+
- CDL parser: the names `trim` and `extract` are not reserved anymore.
|
|
83
|
+
|
|
84
|
+
### Changed
|
|
85
|
+
|
|
86
|
+
- cds-compiler now requires Node 14.
|
|
87
|
+
- `compile()` and its derivates now use `fs.realpath.native()` instead of `fs.realpath()`.
|
|
88
|
+
- CDL parser:
|
|
89
|
+
+ Multi-line doc comments without leading `*` were inconsistently trimmed.
|
|
90
|
+
+ As before, a structure value for an annotation assignment in a CDL source is flattened,
|
|
91
|
+
i.e. `@Anno: { foo: 1, @bar: 2 }` becomes `@Anno.foo: 1 @Anno.@bar: 2`.
|
|
92
|
+
Now, the structure property name `$value` is basically ignored:
|
|
93
|
+
`@Anno: { $value: 1, @bar: 2 }` becomes `@Anno: 1 @Anno.@bar: 2`.
|
|
94
|
+
The advantage is that overwriting or appending the annotation value works as expected.
|
|
95
|
+
+ Keywords `not null` is only valid after `many String enum {...}` and no longer after `String`.
|
|
96
|
+
- `@cds.persistence.skip` and `@cds.persistence.exists` are both copied to generated child artifacts
|
|
97
|
+
such as localized convenience views, texts entities and managed compositions.
|
|
98
|
+
- Update OData vocabularies 'Common', 'UI'.
|
|
99
|
+
- (Sub-)Elements of localized convenience views can now be annotated, e.g. `annotate localized.E:elem`.
|
|
100
|
+
- `getArtifactCdsPersistenceName` now enforces the `csn` argument and can optionally have the `sqlDialect` passed in.
|
|
101
|
+
- `getElementCdsPersistenceName` can optionally have the `sqlDialect` passed in.
|
|
102
|
+
|
|
103
|
+
### Removed
|
|
104
|
+
|
|
105
|
+
- All v2 deprecated flags.
|
|
106
|
+
- Keyword `masked`.
|
|
107
|
+
- CDL parser: `*` is not parsed anymore as argument to all SQL functions;
|
|
108
|
+
it is now only allowed for `count`, `min`, `max`, `sum`, `avg`, `stddev`, `var`.
|
|
109
|
+
- All non-SNAPI options.
|
|
110
|
+
|
|
10
111
|
## Version 2.15.8 - 2022-08-02
|
|
11
112
|
|
|
12
113
|
### Fixed
|
|
@@ -36,6 +137,7 @@ The compiler behavior concerning `beta` features can change at any time without
|
|
|
36
137
|
+ Fix a bug in target path calculation for `NavigationPropertyBinding`s to external references.
|
|
37
138
|
+ Render inner annotations even if `$value` is missing.
|
|
38
139
|
- Update OData vocabularies 'Common', 'UI'.
|
|
140
|
+
- to.sql/to.hdbcds/to.hdi: "type of"s in `cast()`s could lead to type properties being lost.
|
|
39
141
|
|
|
40
142
|
## Version 2.15.2 - 2022-05-12
|
|
41
143
|
|
|
@@ -299,1596 +401,6 @@ No changes compared to Version 2.13.0; fixes latest NPM tag
|
|
|
299
401
|
- to.cdl: Annotation paths containing special characters such as spaces or `@` are now quoted, e.g. `@![some@annotation]`.
|
|
300
402
|
- compiler: A warning is emitted for elements of views with localized keys as the localized property is ignored for them.
|
|
301
403
|
|
|
302
|
-
## Version 2.11.4 - 2021-12-21
|
|
303
|
-
|
|
304
|
-
### Fixed
|
|
305
|
-
|
|
306
|
-
- CDL parser: in many situations, improve message when people use reserved keywords as identifier
|
|
307
|
-
- Improve error text and error location for ambiguous auto-redirection target
|
|
308
|
-
- to.sql/hdi/hdbcds:
|
|
309
|
-
+ Correctly detect `exists` in projections
|
|
310
|
-
+ Correctly handle elements starting with `$` in the on-condition of associations
|
|
311
|
-
+ Correctly handle sub queries in an entity defined with `projection on`
|
|
312
|
-
+ Correctly handle associations in sub queries in a `from` of a sub query
|
|
313
|
-
+ foreign key constraints: respect @assert.integrity: false for compositions
|
|
314
|
-
- to.hdbcds: Correctly quote elements named `$self` and `$projection`
|
|
315
|
-
- to.cdl: `when` was added to the keyword list for smart quoting
|
|
316
|
-
- Compiler support for code completion for `$user` and `$session` now respect user
|
|
317
|
-
provided variables in `options.variableReplacements`.
|
|
318
|
-
- API: `deduplicateMessages()` no longer removes messages for `duplicate` artifact/annotation errors.
|
|
319
|
-
Prior to this version, only one of the duplicated artifacts had a message, leaving the user to
|
|
320
|
-
guess where the other duplicates were.
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
## Version 2.11.2 - 2021-12-06
|
|
324
|
-
|
|
325
|
-
### Fixed
|
|
326
|
-
|
|
327
|
-
- to.sql/hdi/hdbcds:
|
|
328
|
-
+ No foreign key constraint will be rendered for managed `composition of one` if annotated with `@assert.integrity: false`
|
|
329
|
-
+ Correctly handle managed associations with other managed associations as foreign keys in conjunction with `exists`
|
|
330
|
-
|
|
331
|
-
## Version 2.11.0 - 2021-12-02
|
|
332
|
-
|
|
333
|
-
### Added
|
|
334
|
-
|
|
335
|
-
- Option `defaultBinaryLength` to set a `length` type facet for all definitions with type `cds.Binary`. This option
|
|
336
|
-
overrides the default binary length in the database backends and is also used as `MaxLength` attribute in Odata.
|
|
337
|
-
- If doc-comments are ignored by the compiler, an info message is now emitted. A doc-comment is ignored,
|
|
338
|
-
if it can't be assigned to an artifact. For example for two subsequent doc-comments, the first doc-comment
|
|
339
|
-
is ignored. To suppress these info messages, explicitly set option `docComment` to `false`.
|
|
340
|
-
- `cdsc`:
|
|
341
|
-
+ `cdsc explain list` can now be used to get a list of message IDs with explanation texts.
|
|
342
|
-
+ `cdsc` now respects the environment variable `NO_COLOR`. If set, no ANSI escape codes will be used.
|
|
343
|
-
Can be overwritten by `cdsc --color always`.
|
|
344
|
-
- to.sql/hdi: Support SQL Window Functions
|
|
345
|
-
- to.sql/hdi/hdbcds:
|
|
346
|
-
+ Support configuration of `$session` and `$user` via option `variableReplacements`.
|
|
347
|
-
+ Restricted support for SQL foreign key constraints if option `assertIntegrityType` is set to `"DB"`.
|
|
348
|
-
The behavior of this feature might change in the future.
|
|
349
|
-
|
|
350
|
-
### Changed
|
|
351
|
-
|
|
352
|
-
- Updated OData vocabularies 'Common' and 'UI'.
|
|
353
|
-
- to.sql/hdi/hdbcds: The default length of `cds.Binary` is set to `5000` similar to `cds.String`.
|
|
354
|
-
|
|
355
|
-
### Removed
|
|
356
|
-
|
|
357
|
-
- to.hdbcds: Doc comments on view columns are not rendered anymore. Doc comments on string literals will make the deployment fail
|
|
358
|
-
as the SAP HANA CDS compiler concatenates the doc comment with the string literal. Besides that, doc comments on view columns
|
|
359
|
-
are not transported to the database by SAP HANA CDS.
|
|
360
|
-
- to.hdbcds/sql/hdi: Forbid associations in filters after `exists` (except for nested `exists`), as the final behavior is not yet specified.
|
|
361
|
-
|
|
362
|
-
### Fixed
|
|
363
|
-
|
|
364
|
-
- CSN parser: doc-comment extensions are no longer ignored.
|
|
365
|
-
- Properly check for duplicate annotation definitions.
|
|
366
|
-
- Correctly apply annotations on inherited enum symbols.
|
|
367
|
-
- Correctly apply annotations on elements in an inherited structure array.
|
|
368
|
-
- Fix a bug in API `defaultStringLength` value evaluation.
|
|
369
|
-
- Fix crash if named arguments are used in a function that's inside a `CASE` statement.
|
|
370
|
-
- to.sql/hdi/hdbcds:
|
|
371
|
-
+ Properly flatten ad-hoc defined elements in `returns` / `params` of `actions` and `functions`.
|
|
372
|
-
+ Correctly handle `*` in non-first position.
|
|
373
|
-
+ Correctly handle action return types
|
|
374
|
-
+ Correctly handle mixin association named `$self`
|
|
375
|
-
- to.cdl: doc-comments are no longer rendered twice.
|
|
376
|
-
- to.edm(x):
|
|
377
|
-
+ Fix a bug in V2/V4 partner ship calculation.
|
|
378
|
-
+ Remove warning of unknown types for Open Types in `@Core.Dictionary`.
|
|
379
|
-
+ An empty CSN no longer results in a JavaScript type error
|
|
380
|
-
|
|
381
|
-
## Version 2.10.4 - 2021-11-05
|
|
382
|
-
|
|
383
|
-
### Fixed
|
|
384
|
-
|
|
385
|
-
- to.sql/hdi/hdbcds:
|
|
386
|
-
+ Correctly complain about `exists` in conjunction with non-associations/compositions
|
|
387
|
-
+ Don't resolve types in action returns, as this causes issues with $self-resolution
|
|
388
|
-
|
|
389
|
-
- to.edm(x): Be robust against transitively untyped keys in stacked view hierarchies
|
|
390
|
-
|
|
391
|
-
## Version 2.10.2 - 2021-10-29
|
|
392
|
-
|
|
393
|
-
### Fixed
|
|
394
|
-
|
|
395
|
-
- to.sql/hdi/hdbcds: Correctly handle `exists` in conjunction with mixin-associations
|
|
396
|
-
|
|
397
|
-
## Version 2.10.0 - 2021-10-28
|
|
398
|
-
|
|
399
|
-
### Added
|
|
400
|
-
|
|
401
|
-
- Support arbitrary paths after `$user` - similar to `$session`.
|
|
402
|
-
- Support scale `floating` and `variable` for `cds.Decimal` in CDL and CSN. Backend specific handling is descibed in their sections.
|
|
403
|
-
- Allow select item wildcard (`*`) in a `select`/`projection` at any position, not just the first.
|
|
404
|
-
|
|
405
|
-
- to.edm(x):
|
|
406
|
-
+ In Odata V4 generate transitive navigation property binding paths along containment hierarchies and terminate on the
|
|
407
|
-
first non-containment association. The association target is either an explicit Edm.EntitySet in the same EntityContainer
|
|
408
|
-
or in a referred EntityContainer (cross service references) or an implicit EntitySet identified by the containment path
|
|
409
|
-
originating from an explicit EntitySet. This enhancement has an observable effect only in structured format with containment
|
|
410
|
-
turned on.
|
|
411
|
-
+ Support for scales `variable` and `floating`:
|
|
412
|
-
+ V4: `variable` and `floating` are rendered as `Scale="variable"`. Since V4 does not support `floating`, it is aproximated as `variable`.
|
|
413
|
-
+ V2: `variable` and `floating` are announced via property annotation `sap:variable-scale="true"`
|
|
414
|
-
|
|
415
|
-
- to.sql/hdi/hdbcds:
|
|
416
|
-
+ Reject scale `floating` and `variable`.
|
|
417
|
-
+ Reject arbitrary `$user` or `$session` paths that cannot be translated to valid SQL.
|
|
418
|
-
+ Following a valid `exists`, further `exists` can be used inside of the filter-expression: `exists assoc[exists another[1=1]]`
|
|
419
|
-
+ `exists` can now be followed by more than one association step.
|
|
420
|
-
`exists assoc.anotherassoc.moreassoc` is semantically equivalent to `exists assoc[exists anotherassoc[exists moreassoc]]`
|
|
421
|
-
|
|
422
|
-
### Changed
|
|
423
|
-
|
|
424
|
-
- to.odata: Inform when overwriting draft action annotations like `@Common.DraftRoot.ActivationAction`.
|
|
425
|
-
|
|
426
|
-
## Version 2.9.0 - 2021-10-15
|
|
427
|
-
|
|
428
|
-
### Changed
|
|
429
|
-
|
|
430
|
-
- to.edm(x): Raise `odata-spec-violation-type` to a downgradable error.
|
|
431
|
-
|
|
432
|
-
### Fixed
|
|
433
|
-
|
|
434
|
-
- to.edm(x):
|
|
435
|
-
+ Fix a bug in annotation propagation to foreign keys.
|
|
436
|
-
+ Don't render annotations for not rendered stream element in V2.
|
|
437
|
-
- to.hdi:
|
|
438
|
-
+ for naming mode "hdbcds" and "quoted" parameter definitions are not quoted anymore.
|
|
439
|
-
- to.hdi/sql/hdbcds:
|
|
440
|
-
+ Correctly handle explicit and implicit alias during flattening.
|
|
441
|
-
+ Raise an error for `@odata.draft.enabled` artifacts with elements without types - instead of crashing with internal assertions.
|
|
442
|
-
|
|
443
|
-
## Version 2.8.0 - 2021-10-07
|
|
444
|
-
|
|
445
|
-
### Added
|
|
446
|
-
|
|
447
|
-
- Allow defining unmanaged associations in anonymous aspects of compositions.
|
|
448
|
-
- Enable extensions of anonymous aspects for managed compositions of aspects.
|
|
449
|
-
- When the option `addTextsLanguageAssoc` is set to true and
|
|
450
|
-
the model contains an entity `sap.common.Languages` with an element `code`,
|
|
451
|
-
all generated texts entities additionally contain an element `language`
|
|
452
|
-
which is an association to `sap.common.Languages` using element `local`.
|
|
453
|
-
- for.odata:
|
|
454
|
-
+ In `--odata-format=flat`, structured view parameters are flattened like elements.
|
|
455
|
-
- to.hdbcds
|
|
456
|
-
+ Use "smart quotes" for naming mode "plain" - automatically quote identifier which are reserved keywords or non-regular.
|
|
457
|
-
|
|
458
|
-
### Changed
|
|
459
|
-
|
|
460
|
-
- for.odata:
|
|
461
|
-
+ In `--data-format=structured`, anonymous sub elements of primary keys and parameters are set to `notNull:true`,
|
|
462
|
-
an existing `notNull` attribute is _not_ overwritten. Referred named types are _not_ modified.
|
|
463
|
-
- to.edm(x):
|
|
464
|
-
+ Improve specification violation checks of (nested) keys:
|
|
465
|
-
+ All (sub-)elements must be `Nullable: false` (error).
|
|
466
|
-
+ Must represent a single value (error).
|
|
467
|
-
+ In V4 must be a specification compliant Edm.PrimitiveType (warning).
|
|
468
|
-
- to.hdi/hdbcds/sql: $user.\<xy\> now has \<xy\> added as alias - "$user.\<xy\> as \<xy\>"
|
|
469
|
-
|
|
470
|
-
### Fixed
|
|
471
|
-
|
|
472
|
-
- Properly generate auto-exposed entities for associations in parameters.
|
|
473
|
-
- Correctly apply extensions to anonymous array item types.
|
|
474
|
-
- Correctly apply/render annotations to anonymous action return types.
|
|
475
|
-
- With CSN flavor `plain` (`gensrc`), correctly render annotations on elements
|
|
476
|
-
of referred structure types as `annotate` statements in the CSN's `extensions` property.
|
|
477
|
-
- to.cdl:
|
|
478
|
-
+ Correctly render extensions on array item types
|
|
479
|
-
+ Correctly render annotations on action return types
|
|
480
|
-
- to/for: Correctly handle CSN input where the prototype of objects is not the "default"
|
|
481
|
-
- to.hdi:
|
|
482
|
-
+ for naming mode "hdbcds" and "quoted" parameter definitions are now quoted.
|
|
483
|
-
+ for naming mode "plain", smart quotation is applied to parameter definitions if they are reserved words.
|
|
484
|
-
- to.hdi/hdbcds/sql:
|
|
485
|
-
+ Ensure that cdl-style casts to localized types do not lose their localized property
|
|
486
|
-
+ Fix a small memory leak during rendering of SQL/HDBCDS.
|
|
487
|
-
- to.edm(x): Remove ambiguous `Partner` attribute from `NavigationProperty`. A forward association referred
|
|
488
|
-
to by multiple backlinks (`$self` comparisons) is no longer partner to an arbitrary backlink.
|
|
489
|
-
|
|
490
|
-
## Version 2.7.0 - 2021-09-22
|
|
491
|
-
|
|
492
|
-
### Added
|
|
493
|
-
|
|
494
|
-
- to.hdi.migration:
|
|
495
|
-
+ Support changes to HANA comments.
|
|
496
|
-
|
|
497
|
-
### Changed
|
|
498
|
-
|
|
499
|
-
- Updated OData vocabularies 'Common', 'Core'
|
|
500
|
-
|
|
501
|
-
### Fixed
|
|
502
|
-
|
|
503
|
-
- Fix memory issue: do not keep reference to last-compiled model.
|
|
504
|
-
- Fix dump which occured when trying to report that the user has defined an element to be both `key` and `localized` if
|
|
505
|
-
`localized` was inherited via the provided type, or in the generated entity for a managed composition of aspect.
|
|
506
|
-
- Properly auto-expose targets of associations in parameters and `many`.
|
|
507
|
-
- for.Odata:
|
|
508
|
-
+ Fix handling of annotation `@cds.odata.valuelist` in conjunction with associations in structures using flat-mode and sqlMapping set to plain.
|
|
509
|
-
+ Set correctly the $localized property in the OData backend resulting CSN for artifacts that have localized convenience views.
|
|
510
|
-
- to.edm(x):
|
|
511
|
-
+ Fix rendering of structured referential constraints and nested partnerships in combination with `$self` comparisons.
|
|
512
|
-
+ Fix merging of `@Capabilities` annotations while transforming them into `NavigationCapabilities` from the containee into the container.
|
|
513
|
-
- to.sql/hdi/hdbcds:
|
|
514
|
-
+ Fix a bug in Association to Join translation in multi-level association redirection in combination with `$self`.
|
|
515
|
-
+ Correctly flatten paths with filters or parameters.
|
|
516
|
-
+ Improve error message in case of invalid `exists`.
|
|
517
|
-
|
|
518
|
-
## Version 2.6.2 - 2021-08-26
|
|
519
|
-
|
|
520
|
-
### Fixed
|
|
521
|
-
|
|
522
|
-
- to.sql/hdi/hdbcds/edm(x)/for.odata: Correctly handle tuple expansion in subqueries of Unions.
|
|
523
|
-
|
|
524
|
-
## Version 2.6.0 - 2021-08-23
|
|
525
|
-
|
|
526
|
-
### Added
|
|
527
|
-
|
|
528
|
-
- Support managed associations without foreign keys. Associations targeting a definition without primary keys or with an
|
|
529
|
-
explicit empty foreign key tuple or with empty structured elements as foreign keys and their corresponding `$self`
|
|
530
|
-
comparisons do not describe the relationship between the source and the target entity.
|
|
531
|
-
These associations can be used to establish API navigations but cannot be used to access elements in the target
|
|
532
|
-
entity as they cannot be transformed into a valid JOIN expression.
|
|
533
|
-
Consequently, these associations are not added to the `WITH ASSOCIATIONS` clause or forwarded to HANA CDS.
|
|
534
|
-
- to.sql/hdi/hdbcds/edm(x)/for.odata: Structure/managed association comparisons (tuple comparisons) are now
|
|
535
|
-
also expanded in infix filters, all expressions and all on-conditions.
|
|
536
|
-
- to.hdbcds: Better locations for messages - mostly concerning keywords and duplicates
|
|
537
|
-
|
|
538
|
-
### Changed
|
|
539
|
-
|
|
540
|
-
- to.sql/hdi/hdbcds: Invalid (i.e. not expandable) usage of structures is now checked - an error is raised
|
|
541
|
-
|
|
542
|
-
### Removed
|
|
543
|
-
|
|
544
|
-
- The internal non-enumerable CSN property `$env` has been removed from the compiled CSN.
|
|
545
|
-
|
|
546
|
-
### Fixed
|
|
547
|
-
|
|
548
|
-
- Make `;` optional before `}` in all circumstances (was not the case with `many`).
|
|
549
|
-
- to.sql/hdi/hdbcds/edm(x): More graceful handling of CSN input where associations do not have `keys` or an `on`-condition
|
|
550
|
-
|
|
551
|
-
## Version 2.5.2 - 2021-08-10
|
|
552
|
-
|
|
553
|
-
### Fixed
|
|
554
|
-
|
|
555
|
-
- to.hdbcds: Fixed a bug introduced with 2.5.0 that caused virtual elements to be rendered in views.
|
|
556
|
-
|
|
557
|
-
## Version 2.5.0 - 2021-07-28
|
|
558
|
-
|
|
559
|
-
### Added
|
|
560
|
-
|
|
561
|
-
- Allow to extend existing array annotation values via the ellipsis operator `...`.
|
|
562
|
-
An ellipsis may appear exactly once at an arbitrary position in the top level array
|
|
563
|
-
of an `annotate` directive. Only array values can be merged into arrays and unapplied
|
|
564
|
-
ellipses are removed from the final array value. Annotation layering rules remain unaffected.
|
|
565
|
-
- to.sql/hdi/hdbcds:
|
|
566
|
-
+ Doc comments are translated into HANA comments (or into `@Comment` annotation for `to.hdbcds`).
|
|
567
|
-
Such comments are possible on entities, views, elements of entities and `to.hdbcds` also supports comments on view columns.
|
|
568
|
-
Generation can be disabled via option `disableHanaComments`. Entites/views (and their elements/columns)
|
|
569
|
-
annotated with `@cds.persistence.journal` for `to.hdi`/`to.sql` will not have comments rendered.
|
|
570
|
-
+ Generation of temporal `WHERE` clause can be suppressed by annotating the `validFrom`/`validTo` elements of the projection with `false` or `null`.
|
|
571
|
-
- to.sql/hdi/hdbcds/edm(x)/for.odata: Structure/managed association comparisons (tuple comparisons) are now
|
|
572
|
-
also expanded in `WHERE` and `HAVING` - this was previously only supported in on-conditions.
|
|
573
|
-
- `cdsc` now internally uses SNAPI.
|
|
574
|
-
- to.hdi.migration:
|
|
575
|
-
+ Validate that the two supplied CSNs are compatible.
|
|
576
|
-
+ Improve delta-mechanism to not render superflous [ALTER|DROP|ADD] statements for unchanged SQL.
|
|
577
|
-
|
|
578
|
-
### Changed
|
|
579
|
-
|
|
580
|
-
- If the first source provided to the compile command has a `$sources` property
|
|
581
|
-
(whether enumerable or not) which is an array of strings,
|
|
582
|
-
use that instead of calculating one.
|
|
583
|
-
- Updated OData vocabularies 'Aggregation', 'Analytics', 'Authorization', 'Capabilities',
|
|
584
|
-
'CodeList', 'Common', 'Communication', 'Core', 'Graph', 'HTML5', 'Measures', 'ODM', 'PersonalData',
|
|
585
|
-
'Repeatability', 'Session', 'UI', 'Validation'
|
|
586
|
-
|
|
587
|
-
### Removed
|
|
588
|
-
|
|
589
|
-
- Removed internal property `$viaTransform` from CSN produced by OData/HANA transformation
|
|
590
|
-
|
|
591
|
-
### Fixed
|
|
592
|
-
|
|
593
|
-
- Remove warnings 'Ignoring annotation “@odata.draft.enabled” as the artifact is not part of a service'
|
|
594
|
-
and 'Ignoring draft node for composition target ... because it is not part of a service'
|
|
595
|
-
- Doc comments are no longer ignored after enum values and on view columns in parseCdl mode.
|
|
596
|
-
- to.cdl:
|
|
597
|
-
+ Doc comments for enum values are correctly rendered.
|
|
598
|
-
+ Enum value and doc comments are now correctly rendered if the enum is called `doc`.
|
|
599
|
-
+ Doc comments at type references are correctly rendered.
|
|
600
|
-
+ Empty doc comments are correctly rendered and not left out.
|
|
601
|
-
+ Doc comments on view columns are correctly rendered.
|
|
602
|
-
- to.edm(x):
|
|
603
|
-
+ OData V2: Ignore `@odata.singleton`.
|
|
604
|
-
+ OData V4: Do not render an `edm:NavigationPropertyBinding` to a singleton if the association has
|
|
605
|
-
cardinality 'to-many'.
|
|
606
|
-
- forOData:
|
|
607
|
-
+ Fix automatic renaming of shortcut annotation (eg. `@label`) with value `null`.
|
|
608
|
-
- CSN parser:
|
|
609
|
-
+ Empty doc comments are correctly parsed and not complained about.
|
|
610
|
-
|
|
611
|
-
## Version 2.4.4 - 2021-07-02
|
|
612
|
-
|
|
613
|
-
### Fixed
|
|
614
|
-
|
|
615
|
-
- Do not remove parentheses around single literals and references on the right-hand side of an `in` and `not in` operator.
|
|
616
|
-
|
|
617
|
-
## Version 2.4.2 - 2021-07-01
|
|
618
|
-
|
|
619
|
-
- Only changes to beta features. Refer to the [beta ChangeLog](doc/CHANGELOG_BETA.md#version-242) for more.
|
|
620
|
-
|
|
621
|
-
## Version 2.4.0 - 2021-06-28
|
|
622
|
-
|
|
623
|
-
### Added
|
|
624
|
-
|
|
625
|
-
- to.edm(x):
|
|
626
|
-
+ Warn if an `edm:Property` has no `Type` attribute.
|
|
627
|
-
+ Warn about using the protected names 'Edm', 'odata', 'System', 'Transient' as `edm:Schema` `Namespace` values.
|
|
628
|
-
+ Allow `$edmJson` inline annotations in `edm:Collection` and nested annotations.
|
|
629
|
-
- to.hdi/sql/hdbcds: Transform a `exists <association>` into a `exists <subselect>`, where the subselect
|
|
630
|
-
selects from the target of `<association>` and establishes the same relation as `<association>` would via the WHERE clause.
|
|
631
|
-
Infix-filters of `<association>` are added to the WHERE clause.
|
|
632
|
-
|
|
633
|
-
### Changed
|
|
634
|
-
|
|
635
|
-
- Do not inherit `@cds.persistence.skip` when `@cds.persistence.table` is set on entity.
|
|
636
|
-
- to.cdl: Opening and closing braces of empty services and contexts are now on the same line.
|
|
637
|
-
|
|
638
|
-
### Fixed
|
|
639
|
-
|
|
640
|
-
- `cdsc`: Option `--direct-backend` can now be combined with `toCsn`'s option `--with-localized`
|
|
641
|
-
- The option `testSortCsn` was erroneously ignored in some compiler backends.
|
|
642
|
-
|
|
643
|
-
## Version 2.3.2 - 2021-06-14
|
|
644
|
-
|
|
645
|
-
### Fixed
|
|
646
|
-
|
|
647
|
-
- for.odata: Propagate the `virtual` attribute correctly while flattening structures.
|
|
648
|
-
- If internal relational types are used directly in CDL (e.g. `cds.Association`), an error is emitted.
|
|
649
|
-
In CSN, all artifacts of relational types need a `target` (/`targetAspect`) as well.
|
|
650
|
-
- In Association to Join translation don't produce a JOIN node for exposed (transitive) associations in
|
|
651
|
-
combination with their exposed foreign keys. Also resolve foreign keys correctly against the target
|
|
652
|
-
entity allowing to expose renamed foreign keys when aliased.
|
|
653
|
-
- The option `testSortCsn` (`--test-sort-csn` in `cdsc`) can be used to sort CSN definitions alphabetically.
|
|
654
|
-
This option is only intended for tests. This will restore the pre-v2.3.0 ordering in EDMX.
|
|
655
|
-
- to.sql:
|
|
656
|
-
+ for SQL-dialect `sqlite`, render the string-format-time function (`strftime()`)
|
|
657
|
-
+ `$at.from` with date-format: `'%Y-%m-%dT%H:%M:%S.000Z'`
|
|
658
|
-
+ `$at.to` with date-format: `'%Y-%m-%dT%H:%M:%S.001Z'` (**+1ms** compared to `$at.from`)
|
|
659
|
-
+ for SQL-dialect `hana` wrap `SESSION_CONTEXT('VALID-TO')` and `SESSION_CONTEXT('VALID-FROM')` in `TO_TIMESTAMP(..)` function
|
|
660
|
-
- to.hdbcds:
|
|
661
|
-
+ Wrap `SESSION_CONTEXT('VALID-TO')` and `SESSION_CONTEXT('VALID-FROM')` in `TO_TIMESTAMP(..)` function
|
|
662
|
-
|
|
663
|
-
## Version 2.3.0 - 2021-06-02
|
|
664
|
-
|
|
665
|
-
### Added
|
|
666
|
-
|
|
667
|
-
- `cdsc` got a new option `--fallback-parser <cdl|csn>` that is used
|
|
668
|
-
if an unknown or no file extension is used.
|
|
669
|
-
- to.hdi/sql: Allow association publishing in UNIONs - this was previously forbidden, but this limitation only applies to HANA CDS.
|
|
670
|
-
- to.edm(x): Support dynamic expressions as $edmJson inline code
|
|
671
|
-
|
|
672
|
-
### Changed
|
|
673
|
-
|
|
674
|
-
- Type `DecimalFloat` is no longer proposed for code-completion.
|
|
675
|
-
- Non-string enums without values for their enum elements are warned about.
|
|
676
|
-
- OData CSN is no longer sorted by definition names
|
|
677
|
-
- to.edm(x): Update OData vocabularies 'Aggregation', 'Analytics', 'CodeList', 'Common', 'Measures', 'Session', 'UI'
|
|
678
|
-
|
|
679
|
-
### Removed
|
|
680
|
-
|
|
681
|
-
- to.hdbcds: Association publishing in subqueries is not supported by HANA CDS - an error is raised during compile time, instead of waiting for a deployment error.
|
|
682
|
-
|
|
683
|
-
### Fixed
|
|
684
|
-
|
|
685
|
-
- Correct auto-exposure in model with unscoped projection on deep scoped entity
|
|
686
|
-
(from managed aspect compositions: component in component, like they are common in ODM).
|
|
687
|
-
- Internal types `cds.Association` and `cds.Composition` are no longer proposed for code-completion.
|
|
688
|
-
- Fix various issues with Association to Join translation:
|
|
689
|
-
+ Substitute `$self.alias` expressions and respect prefix paths in foreign key accesses.
|
|
690
|
-
- to.hdbcds: In naming mode "hdbcds", correctly resolve $self backlinks with aliased foreign keys.
|
|
691
|
-
- to.cdl:
|
|
692
|
-
+ Correctly traverse subelements when rendering annotations for them.
|
|
693
|
-
+ Quote element names (if required) in `annotate with` statements.
|
|
694
|
-
- for.odata: Fix regression with detecting collision when generating foreign keys.
|
|
695
|
-
- to.edmx: Correctly render final base types in EDMX V2 when called with transformed OData CSN for V4.
|
|
696
|
-
|
|
697
|
-
## Version 2.2.8 - 2021-05-20
|
|
698
|
-
|
|
699
|
-
### Fixed
|
|
700
|
-
|
|
701
|
-
- Fix regression: also for associations _defined_ in a service, try to
|
|
702
|
-
implicitly redirect the provided model target.
|
|
703
|
-
|
|
704
|
-
## Version 2.2.6 - 2021-05-12
|
|
705
|
-
|
|
706
|
-
### Fixed
|
|
707
|
-
|
|
708
|
-
- to.edmx(x):
|
|
709
|
-
+ The reverted change "`array of` elements are now allowed for OData V2, too." introduced with v2.2.0 has caused
|
|
710
|
-
regressions in various scenarios that used OData V4 processed CSN for OData V2 EDMX rendering. Therefore
|
|
711
|
-
the error has been lowered to a 'odata-spec-violation-array-of' warning.
|
|
712
|
-
+ The fix 'Render constraints only if all principal keys are used in association' introduced with v2.2.2 has
|
|
713
|
-
caused regressions in mocking scenarios. With option `--odata-v2-partial-constr` partial constraint generation
|
|
714
|
-
can be reactivated. A 'odata-spec-violation-constraints' warning is raised.
|
|
715
|
-
|
|
716
|
-
### 2.5.0 Addendum to Changed
|
|
717
|
-
|
|
718
|
-
- Replace outdated option `length` with `defaultStringLength` which is usable in `for.*` and `to.*` APIs.
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
## Version 2.2.4 - 2021-05-06
|
|
722
|
-
|
|
723
|
-
No changes compared to Version 2.2.2; fixes latest NPM tag
|
|
724
|
-
|
|
725
|
-
## Version 2.2.2 - 2021-05-04
|
|
726
|
-
|
|
727
|
-
### Fixed
|
|
728
|
-
|
|
729
|
-
- Usually reserved names like `in` in references used as annotation values can now really
|
|
730
|
-
be provided without delimited identifiers (if the name is not `true`, `false` or `null`).
|
|
731
|
-
- Fixed the implicit redirection of associations to scoped targets (like texts entities).
|
|
732
|
-
- Fix regression: Allow virtual structured elements.
|
|
733
|
-
- to.edm(x):
|
|
734
|
-
+ OData V2:
|
|
735
|
-
+ Remove warning about scalar return types.
|
|
736
|
-
+ Render constraints only if all principal keys are used in association.
|
|
737
|
-
+ OData V4: Don't remove `@Capabilities` annotations from containee.
|
|
738
|
-
+ Allow `@Core.MediaType` on all types and raise a warning for those (scalar) types that can't be mapped to `Edm.String` or `Edm.Binary`.
|
|
739
|
-
- to.cdl: Also handle subelement-annotations by rendering a `annotate X with Y`.
|
|
740
|
-
- to.hdi/sql/hdbcds: Fixed the DB name (with naming mode `quoted`/`hdbcds`) and the `to.hdi` file name of scoped definitions (like `texts` entities) in services.
|
|
741
|
-
- Empty enums no longer result in a syntax error.
|
|
742
|
-
|
|
743
|
-
## Version 2.2.0 - 2021-04-28
|
|
744
|
-
|
|
745
|
-
### Added
|
|
746
|
-
|
|
747
|
-
- The compiler now takes the “definition scope” of associations and compositions into account
|
|
748
|
-
when implicitly redirecting the target and auto-exposing entities.
|
|
749
|
-
- odata: The warning `enum-value-ref` is no longer reclassified to an error.
|
|
750
|
-
However, references to other enum values are still not supported.
|
|
751
|
-
|
|
752
|
-
### Changed
|
|
753
|
-
|
|
754
|
-
- Remove special handling for implicit redirection to auto-exposed entity; consistently
|
|
755
|
-
do not overwrite user-specified target in a service anymore, also in this special case.
|
|
756
|
-
- Structured/Arrayed types for enums are now an error and not just a warning.
|
|
757
|
-
- to.cdl: Keywords in annotation paths are no longer escaped
|
|
758
|
-
|
|
759
|
-
### Removed
|
|
760
|
-
|
|
761
|
-
- Consistently reject references to auto-exposed entities except for `annotate`
|
|
762
|
-
(it might have worked before, depending on the sequence of definitions);
|
|
763
|
-
expose an entity manually if you want to refer to it.
|
|
764
|
-
|
|
765
|
-
### Fixed
|
|
766
|
-
|
|
767
|
-
- Do not omit indirectly annotated or redirected sub elements
|
|
768
|
-
during propagation of expanded sub elements.
|
|
769
|
-
- Also auto-expose composition targets of projected compositions,
|
|
770
|
-
not just those target which were used at the original definition of the composition.
|
|
771
|
-
- Improve checks for keys which are `array of` or of SAP HANA spatial type (`ST_POINT` & `ST_GEOMETRY`)
|
|
772
|
-
with checking also inside of used user-defined structured type.
|
|
773
|
-
- to.edm(x):
|
|
774
|
-
+ V2: `OnDelete=Cascade` was set on dependent instead on principal role.
|
|
775
|
-
+ V4: ReferentialConstraints Property and ReferencedProperty for managed composition to one were swapped.
|
|
776
|
-
|
|
777
|
-
### 2.2.6 Addendum to Changed
|
|
778
|
-
|
|
779
|
-
- to.edm(x): Revert 2.1.0 change: "`array of` elements are now allowed for OData V2, too."
|
|
780
|
-
OData V2 does not allow elements to be typed with `Collection()`. Any `many`
|
|
781
|
-
predicate in element definitions is rejected. The only two positions where the `many` predicate
|
|
782
|
-
is allowed are `association to many` and `returns many`.
|
|
783
|
-
|
|
784
|
-
## Version 2.1.6 - 2021-04-14
|
|
785
|
-
|
|
786
|
-
### Fixed
|
|
787
|
-
|
|
788
|
-
- Do not unjustified complain about `$self` comparisons.
|
|
789
|
-
- Auto-exposed entities are represented as projections in the CSN.
|
|
790
|
-
- to.sql/to.hdi:
|
|
791
|
-
+ Revert change "Default values are no longer propagated from the principal to the generated foreign key element." from version 2.1.0
|
|
792
|
-
+ Fix regression where localized convenience views for temporal entities used keys in the from clause that did not exist on the texts-entity
|
|
793
|
-
+ Mixin associations are properly removed and are not rendered into views anymore
|
|
794
|
-
- to.hdi(.migration): Ensure filenames for `.hdbindex` files stay compatible to V1
|
|
795
|
-
- for.odata: An association as a type of action's parameter or return type now signals an error
|
|
796
|
-
- to.edm(x):
|
|
797
|
-
+ `@Capabilities` annotations remain on the containees entity type
|
|
798
|
-
+ In containment mode don't render foreign keys of the containment constituting 'up' association in the containee
|
|
799
|
-
as primary key refs.
|
|
800
|
-
+ Revert change "Default values are no longer propagated from the principal to the generated foreign key element." from version 2.1.0
|
|
801
|
-
+ Allow `--odata-proxies` and/or `--odata-x-service-refs` in combination with `--odata-format=flat` and `--version=v4`
|
|
802
|
-
|
|
803
|
-
## Version 2.1.4 - 2021-03-31
|
|
804
|
-
|
|
805
|
-
### Fixed
|
|
806
|
-
|
|
807
|
-
- The postinstall step now never fails with an exit code != 0. As the postinstall step is optional, it should not break any `npm install` steps.
|
|
808
|
-
|
|
809
|
-
## Version 2.1.2 - 2021-03-29
|
|
810
|
-
|
|
811
|
-
### Fixed
|
|
812
|
-
|
|
813
|
-
- ensure `postinstall` script is part of the shipped `package.json`
|
|
814
|
-
|
|
815
|
-
## Version 2.1.0 - 2021-03-26
|
|
816
|
-
|
|
817
|
-
### Added
|
|
818
|
-
|
|
819
|
-
- Inferred sub elements of a referred structure type can be individually annotated.
|
|
820
|
-
- All primitive types except for binary are now allowed as enum value types.
|
|
821
|
-
- Allow users to define `A.B` even if there is a definition `A` which is not a context or service.
|
|
822
|
-
- You can now provide almost all annotation assignments without delimited identifiers:
|
|
823
|
-
the use of `.`, `@` and `#` is fine for annotation names,
|
|
824
|
-
property names of structures, and in references used as annotation values.
|
|
825
|
-
- for.odata:
|
|
826
|
-
+ All the artifacts that have localized fields get a `$localized: true` property.
|
|
827
|
-
+ Allow the user to define draft actions for annotation purposes
|
|
828
|
-
+ `draftPrepare(SideEffectsQualifier: String) returns <ET>`,
|
|
829
|
-
+ `draftActivate() returns <ET>`,
|
|
830
|
-
+ `draftEdit(PreserveChanges: Boolean) returns <ET>`
|
|
831
|
-
- to.edm(x):
|
|
832
|
-
+ Warn about non-applicable annotations.
|
|
833
|
-
+ Render property default values (only OData V4).
|
|
834
|
-
+ Option `odataProxies` exposes association targets outside of the current service.
|
|
835
|
-
These `EntityType`s do only expose their primary keys have no accompanying `EntitySet`.
|
|
836
|
-
The added navigation targets are exposed under their namespace or if not available under namespace `root`.
|
|
837
|
-
`odataProxies` is only available with `--format=structured`.
|
|
838
|
-
+ Option `odataXServiceRefs` renders an `edm:Reference` to the service for those navigation targets
|
|
839
|
-
that are defined in another service. `odataXServiceRefs` is only available with `--format=structured`.
|
|
840
|
-
+ Duplicate EntityContainer entries with same name will raise an error.
|
|
841
|
-
+ `array of` elements are now allowed for OData V2, too.
|
|
842
|
-
- to.sql/hdi/hdbcds: Explicitly render the implicit alias for functions without arguments, e.g. `current_date`.
|
|
843
|
-
- to.sql:
|
|
844
|
-
+ Sort the SQL statements according to the deployment order.
|
|
845
|
-
+ New sql dialect `plain`, which now is the default.
|
|
846
|
-
synchronously.
|
|
847
|
-
- API:
|
|
848
|
-
+ `compileSync()` is now compatible to `compile()`:
|
|
849
|
-
the function can also receive a file cache and will resolve all `using`s
|
|
850
|
-
+ New API functions `parse.cql` (prefer it to deprecated `parseToCqn`) and
|
|
851
|
-
`parse.expr` (prefer it to deprecated `parseToExpr`)
|
|
852
|
-
+ function `getArtifactCdsPersistenceName` now accepts a CSN as a third parameter (used to be a namespace). With a CSN provided,
|
|
853
|
-
the name can be correctly constructed for naming modes `quoted` and `hdbcds`. Without a CSN, the name is possibly wrong
|
|
854
|
-
if it contains dots. If the CSN is not provided or the third parameter is not a CSN, the old, deprecated, implementation is used.
|
|
855
|
-
- `cdsc` and other client tools:
|
|
856
|
-
+ Added `--with-localized` to the command `toCsn` which adds convenience views for localized entities to the output.
|
|
857
|
-
+ A script `bin/cds_update_identifiers.js` was added. You can use it to update the delimited identifier style in your CDS sources.
|
|
858
|
-
+ A script `bin/cdscv2m.js` was added.
|
|
859
|
-
It's command `ria` adds `@cds.redirection.target: false` annotate statements
|
|
860
|
-
for all ambiguous redirection errors.
|
|
861
|
-
- Added `deprecated` options; setting any of them disables all `beta` options.
|
|
862
|
-
|
|
863
|
-
### Changed
|
|
864
|
-
|
|
865
|
-
- CSN representation:
|
|
866
|
-
+ CSN Version is set to `2.0`
|
|
867
|
-
+ CSN `definitions` are not sorted anymore
|
|
868
|
-
+ `$syntax` is non-enumerable
|
|
869
|
-
+ increase the use of JS numbers in the CSN for numbers in CDL, especially noticable in annotation values
|
|
870
|
-
+ Annotation definitions are to be found in the top-level property `vocabularies`.
|
|
871
|
-
+ Introduce `kind: 'aspect'` to replace `kind: 'type', $syntax: 'aspect'` and
|
|
872
|
-
`kind: 'entity', abstract: true` (the deprecated variants are still accepted as input).
|
|
873
|
-
+ Projections are rendered via `projection` instead of `query.SELECT`.
|
|
874
|
-
+ Parentheses are represented structurally and unnecessary parentheses are omitted.
|
|
875
|
-
+ Use `.` instead of `_` for the name suffix of generated texts entities and the calculated entity for managed compositions.
|
|
876
|
-
+ The CSN returned by `compile()` does not include localized convenience views anymore.
|
|
877
|
-
- Core engine (function `compile`):
|
|
878
|
-
+ An assignment `@Foo.Bar` is always `@Foo.Bar`, we do not try to search anymore
|
|
879
|
-
for a local definition of `Foo` probably having a different full name.
|
|
880
|
-
+ Localized convenience views are no longer generated by the core compiler but added by the `for.odata`
|
|
881
|
-
and `to.sql/hdi/hdbcds` processing on demand.
|
|
882
|
-
+ Minimize name clashes when calculating names for autoexposed entities,
|
|
883
|
-
extends the v1 option `dependentAutoexposed` to sub artifacts of entites (see “Added”).
|
|
884
|
-
+ Ambiguities when redirecting associations now always lead to compile errors;
|
|
885
|
-
you might want to use the new annotation `@cds.redirection.target` to solve them.
|
|
886
|
-
+ The association `up_` in the calculated entity for managed compositions is now managed.
|
|
887
|
-
_Limitation_: Nested managed compositions are not activatable via `to.hdbcds --names=hdbcds`.
|
|
888
|
-
+ Bound actions and functions are no longer propagated from the main query source to the resulting view or projection.
|
|
889
|
-
+ Remove annotation `@cds.autoexpose` from generated `.texts` entity
|
|
890
|
-
+ Require `order by` references to start with a table alias when referring to source elements.
|
|
891
|
-
+ Infer the type of a `select` item from the type of a top-level `cast`.
|
|
892
|
-
- Localized convenience views now also contain `masked` elements of the original artifact.
|
|
893
|
-
- for.odata:
|
|
894
|
-
+ Even with `--format: structured`, (flat) foreign keys for managed associations are generated.
|
|
895
|
-
+ An `entity` or an `aspect` defined outside the current service cannot be used as action parameter or return types.
|
|
896
|
-
+ Structured elements are expanded in-place.
|
|
897
|
-
+ Foreign keys for managed associations are created in-place.
|
|
898
|
-
- to.edm(x):
|
|
899
|
-
+ An `Edm.TypeDefinition` is rendered for a derived scalar type and used as type reference instead of
|
|
900
|
-
rendering the final scalar type, including the `array of`/`many` predicates.
|
|
901
|
-
+ `enum` type definition as service member is rendered as `edm:TypeDefinition` instead of `edm:EnumType`.
|
|
902
|
-
+ Set default source cardinality of compositions to exact one. This is observable in V2 EDM only.
|
|
903
|
-
+ Key must not be `nullable=true`, this includes all sub elements of used structured types.
|
|
904
|
-
+ Default values are no longer propagated from the principal to the generated foreign key element.
|
|
905
|
-
+ `array of array` is rejected, nested Collections `Collection(Collection(...))` are illegal.
|
|
906
|
-
+ Temporal rendering:
|
|
907
|
-
+ `@cds.valid.from` is not `Edm.KeyRef` anymore.
|
|
908
|
-
+ `@cds.valid.key` is rendered as `@Core.AlternateKeys`.
|
|
909
|
-
+ Downgrade message "`<Term>` is not applied" from warning to info.
|
|
910
|
-
+ Update Vocabularies 'Aggregation', 'Capabilities', 'Core', 'Validation'.
|
|
911
|
-
- to.sql/to.hdi/to.hdbcds:
|
|
912
|
-
+ Reject using associations or compositions in query elements starting with `$self` or `$projection`.
|
|
913
|
-
+ Virtual elements are not rendered.
|
|
914
|
-
+ Structured elements are expanded in-place.
|
|
915
|
-
+ Foreign keys for managed associations are created in-place.
|
|
916
|
-
+ Implicit/CDL-style casts are not rendered as SQL CASTs.
|
|
917
|
-
+ All association usages in queries are always translated into JOIN expressions
|
|
918
|
-
(except for to.hdbcds `--names=hdbcds`).
|
|
919
|
-
- to.sql/to.hdi:
|
|
920
|
-
+ Downgrade message `to-many-no-on` from error to warning.
|
|
921
|
-
+ Default values are no longer propagated from the principal to the generated foreign key element.
|
|
922
|
-
- to.sql:
|
|
923
|
-
+ Changed type mappings for `--dialect=sqlite`:
|
|
924
|
-
+ `cds.Date` -> `DATE_TEXT`
|
|
925
|
-
+ `cds.Time` -> `TIME_TEXT`
|
|
926
|
-
+ `cds.Timestamp` -> `TIMESTAMP_TEXT`
|
|
927
|
-
+ `cds.DateTime` -> `TIMESTAMP_TEXT`
|
|
928
|
-
+ `cds.Binary` -> `BINARY_BLOB`
|
|
929
|
-
+ `cds.hana.Binary` -> `BINARY_BLOB`
|
|
930
|
-
+ Don't check missing type facets.
|
|
931
|
-
- to.hdbcds:
|
|
932
|
-
+ References to derived, primitive types are replaced by their final type.
|
|
933
|
-
The derived type definitions are not rendered anymore for hdbcds naming mode.
|
|
934
|
-
+ Don't check missing type facets in views.
|
|
935
|
-
- to.cdl:
|
|
936
|
-
+ Render maximum cardinality as 'to one' or 'to many'.
|
|
937
|
-
+ Return at most two files. The first one (named `model.cds`) contains all definitions, simply rendered in order,
|
|
938
|
-
without namespaces or usings. Contexts and services are NOT nested. The second file (named `<namespace>.cds`)
|
|
939
|
-
represents the CSN `namespace` property, simply defining such a namespace and requiring the first file.
|
|
940
|
-
- API changes:
|
|
941
|
-
+ The API functions `compile()` and `compileSync()` return a CSN and not an XSN,
|
|
942
|
-
`compactModel()` returns the first argument.
|
|
943
|
-
+ If `options` does not provide a `messages` property, all messages are printed to standard error.
|
|
944
|
-
+ The `options.messages` is kept throughout the compiler and contains all messages from the compiler and all backends.
|
|
945
|
-
+ Messages are not sorted anymore; use the API function `sortMessages` to have it sorted.
|
|
946
|
-
|
|
947
|
-
### Removed
|
|
948
|
-
|
|
949
|
-
- Core engine (function `compile`):
|
|
950
|
-
+ Referential integrity issues now always lead to compile errors.
|
|
951
|
-
+ The `type of` operator (without `:` in the reference) cannot be used
|
|
952
|
-
for parameters and inside queries anymore.
|
|
953
|
-
+ Using `"…"` for delimited identifiers leads to a compile error.
|
|
954
|
-
+ Issue an error for “smart artifact references”, i.e.
|
|
955
|
-
when using `Definition.elem` instead of `Definition:elem`
|
|
956
|
-
+ The definition of annotations is no longer allowed in `context`s and `service`s.
|
|
957
|
-
+ Providing an alias name without `as` leads to a compile error or warning.
|
|
958
|
-
+ Providing unexpected kind of definitions for `type` or other references leads to a compile error.
|
|
959
|
-
+ The ancient CSN 0.1.0 format generation has been removed.
|
|
960
|
-
+ The compiler does no longer look for modules whose file extension is `.csn.json`,
|
|
961
|
-
both `.csn` and `.json` is still checked.
|
|
962
|
-
- for.odata:
|
|
963
|
-
+ With `--format: structured`, the property `$generatedFieldName` in keys of
|
|
964
|
-
managed associations has been removed.
|
|
965
|
-
+ Artificially exposed types that are required to make a service self contained are
|
|
966
|
-
removed from the OData processed CSN.
|
|
967
|
-
+ Localized convenience views are no longer part of the OData CSN.
|
|
968
|
-
- API changes:
|
|
969
|
-
+ The deprecated XSN based transformers `forHana`, `forOdata`, `toSwagger`, `toSql`, `toCsn`, `toCdl`
|
|
970
|
-
have now been removed from the code base.
|
|
971
|
-
+ Remove `collectSources()` as well as `options.collectSources`.
|
|
972
|
-
+ A `CompilationError` usually does not have the property `model` anymore,
|
|
973
|
-
to avoid potential memory issues.
|
|
974
|
-
+ CSN compiler messages no longer have a `location` property. Use `$location` instead.
|
|
975
|
-
- The following `cdsc` options have been removed:
|
|
976
|
-
+ `--old-transformers`.
|
|
977
|
-
+ `--hana-flavor` with all corresponding rudimentarily implemented language constructs.
|
|
978
|
-
+ `--new-resolve` (the new resolver is now the default).
|
|
979
|
-
|
|
980
|
-
### Fixed
|
|
981
|
-
|
|
982
|
-
- Core engine (function `compile`):
|
|
983
|
-
+ Managed composition in sub elements are now properly redirected,
|
|
984
|
-
even if the sub structure comes from a referred type.
|
|
985
|
-
+ Do not dump with sub queries in the `on` condition of `join`s.
|
|
986
|
-
+ Properly report that managed aspect composition inside types and as sub elements
|
|
987
|
-
are not supported yet.
|
|
988
|
-
+ Make sure that including elements with managed aspect compositions only
|
|
989
|
-
use the provided target aspect, but not the generated target entity.
|
|
990
|
-
+ Properly handle the extra keywords in the third argument of the HANA SQL function `round`.
|
|
991
|
-
- to.edm(x):
|
|
992
|
-
+ Return all warnings to the user.
|
|
993
|
-
+ Don't render references and annotations for unexposed associations.
|
|
994
|
-
+ Rendering of `@Validation.AllowedValue` for elements of type enum annotated with `@assert.range`:
|
|
995
|
-
+ Add `@Core.Description`, if the enum symbol has a `@Core.Description`, `@description` or document comments.
|
|
996
|
-
+ Primary key aliases are now the path basenames, colliding aliases are numbered.
|
|
997
|
-
+ Fix a bug in constraint calculation if principal has no primary keys.
|
|
998
|
-
+ Illegal OData identifiers which are not exposed in the generated edmx schema are not causing errors anymore.
|
|
999
|
-
+ Improve non-enum value handling on term definitions based on an enum type by raising a warning and rendering
|
|
1000
|
-
the value with appropriate scalar EDM type.
|
|
1001
|
-
+ Render annotion qualifier in JSON format.
|
|
1002
|
-
- to.sql/hdi/hdbcds:
|
|
1003
|
-
+ Reject structured view parameters for HANA.
|
|
1004
|
-
+ Types are not rendered anymore for HANA in quoted mode.
|
|
1005
|
-
+ Structured elements in subqueries are now properly expanded.
|
|
1006
|
-
+ Actions, functions, annotations and events do not have DB specific checks run on them, as
|
|
1007
|
-
they will not be part of the resulting artifacts anyways
|
|
1008
|
-
+ With `--names=quoted` or `hdbcds`, some `.` in artifact names are turned into `_`.
|
|
1009
|
-
In general, this happens when part of the name prefix is "shadowed" by a non-context/service;
|
|
1010
|
-
any `.` after that point is turned into `_`. This change also affects the filenames and the
|
|
1011
|
-
`@cds.persistence.name` annotation in the CSN returned by `to.hdi.migration` and `for.odata`.
|
|
1012
|
-
- to.sql/hdi:
|
|
1013
|
-
+ Fixed a bug which led to an exception if elements were referenced as types.
|
|
1014
|
-
+ For the SQLite dialect, date, time and timestamp are rendered as simple string literals instead of function calls.
|
|
1015
|
-
+ For naming mode "plain", date, time and timestamps are rendered as SQL-compliant literals.
|
|
1016
|
-
- to.sql/hdbcds: Fix issue which led to wrong ON conditions for naming mode `hdbcds`.
|
|
1017
|
-
- to.sql:
|
|
1018
|
-
+ SRID of SAP HANA spatial type (`ST_POINT` & `ST_GEOMETRY`) is not rendered as the length of `CHAR`
|
|
1019
|
-
for SQL-dialects other than `hana`. The resulting `CHAR` has a default length of 2000.
|
|
1020
|
-
- to.hdbcds:
|
|
1021
|
-
+ Nullability constraints on view parameters are not rendered anymore.
|
|
1022
|
-
+ CDS and HANA CDS types inside cast expressions are mapped to their SQL-counterparts, as the CDS types can't be used in a cast.
|
|
1023
|
-
- to.cdl: Correctly render `event` typed as `projection`.
|
|
1024
|
-
- to.hdi.migration: Don't generate `ALTER` for type change from association to composition or vice versa (if the rest stays the same),
|
|
1025
|
-
as the resulting SQL is identical.
|
|
1026
|
-
|
|
1027
|
-
## Version 1.50.10 - 2021-07-30
|
|
1028
|
-
|
|
1029
|
-
### Fixed
|
|
1030
|
-
|
|
1031
|
-
- to.hdi.migration: Check for incompatible CSN versions to avoid wrongly generated ALTER|DROP|ADD statements.
|
|
1032
|
-
|
|
1033
|
-
## Version 1.50.8 - 2021-07-01
|
|
1034
|
-
|
|
1035
|
-
### Fixed
|
|
1036
|
-
|
|
1037
|
-
- to.hdi.migration: Don't generate `ALTER` for type change from association to composition or vice versa (if the rest stays the same), as the resulting SQL is identical.
|
|
1038
|
-
|
|
1039
|
-
## Version 1.50.6 - 2021-05-05
|
|
1040
|
-
|
|
1041
|
-
### Fixed
|
|
1042
|
-
|
|
1043
|
-
- to.edm(x):
|
|
1044
|
-
+ OData V2: Render constraints only if all principal keys are used in association.
|
|
1045
|
-
+ OData V4: Don't remove `@Capabilities` annotations from containee.
|
|
1046
|
-
+ Allow `@Core.MediaType` on all types and raise a warning for those (scalar) types that can't be mapped to `Edm.String` or `Edm.Binary`.
|
|
1047
|
-
|
|
1048
|
-
## Version 1.50.4 - 2021-04-06
|
|
1049
|
-
|
|
1050
|
-
### Fixed
|
|
1051
|
-
|
|
1052
|
-
- to.hdbcds: CDS and HANA CDS types inside cast expressions are mapped to their SQL-counterparts, as the CDS types can't be used in a cast.
|
|
1053
|
-
|
|
1054
|
-
## Version 1.50.2 - 2021-03-19
|
|
1055
|
-
|
|
1056
|
-
### Fixed
|
|
1057
|
-
|
|
1058
|
-
- Correct calculation of dependent autoexposed entity name
|
|
1059
|
-
(fixing a potential regression with v1.50.0)
|
|
1060
|
-
- to.hdi.migration: Correctly handle "temporal" and other cases when rendering expressions
|
|
1061
|
-
- to.edm(x):
|
|
1062
|
-
+ Improve non-enum value handling on Oasis enum term definitions by raising a warning and rendering
|
|
1063
|
-
the value with appropriate scalar EDM type.
|
|
1064
|
-
+ Render annotion qualifier in JSON format.
|
|
1065
|
-
- Update OData vocabularies
|
|
1066
|
-
'Aggregation', 'Analytics', 'Capabilities', 'CodeList', 'Common', 'Communication',
|
|
1067
|
-
'Core', 'Graph', 'HTML5', 'ODM', 'PersonalData', 'Session', 'UI'
|
|
1068
|
-
|
|
1069
|
-
## Version 1.50.0 - 2021-02-25
|
|
1070
|
-
|
|
1071
|
-
### Added
|
|
1072
|
-
|
|
1073
|
-
- Introduce annotation `@cds.redirection.target`.
|
|
1074
|
-
With value `false`, the projection is not considered an implicit redirection target;
|
|
1075
|
-
with value `true`, is is considered a “preferred” redirection target.
|
|
1076
|
-
|
|
1077
|
-
## Version 1.49.2 - 2021-02-16
|
|
1078
|
-
|
|
1079
|
-
### Fixed
|
|
1080
|
-
|
|
1081
|
-
- to.edm(x): Illegal OData identifiers which are not exposed in the generated edmx schema are not causing errors anymore.
|
|
1082
|
-
- to.cdl: Annotations are now rendered with the new delimited Identifier syntax
|
|
1083
|
-
- to.sql/hdi:
|
|
1084
|
-
+ Fixed a bug which led to an exception if elements were referenced as types.
|
|
1085
|
-
+ For the SQLite dialect, date, time and timestamp are rendered as simple string literals instead of function calls.
|
|
1086
|
-
+ For naming mode "plain", date, time and timestamps are rendered as SQL-compliant literals.
|
|
1087
|
-
|
|
1088
|
-
## Version 1.49.0 - 2021-01-29
|
|
1089
|
-
|
|
1090
|
-
### Added
|
|
1091
|
-
|
|
1092
|
-
- to.hdi/sql:
|
|
1093
|
-
+ Updated the list of reserved keywords for HANA and SQLite
|
|
1094
|
-
+ Use "smart quoting" for naming mode "plain" - automatically quote reserved keywords
|
|
1095
|
-
- to.hdi.migration:
|
|
1096
|
-
+ Supports various kinds of entity changes: entity addition/deletion/change (the latter including element additions/deletions/type changes).
|
|
1097
|
-
+ Provides option to render any element type change as `ALTER TABLE DROP` to prevent deployment issues due to incompatible data
|
|
1098
|
-
(default for length reductions or association/composition changes).
|
|
1099
|
-
- to.cdl: Smart artifact references are now rendered explicitly via `:` notation
|
|
1100
|
-
|
|
1101
|
-
### Changed
|
|
1102
|
-
|
|
1103
|
-
- OData/EDMX:
|
|
1104
|
-
Change the `EntityType` precedence of the OData term definition `AppliesTo=` attribute. If `AppliesTo` contains
|
|
1105
|
-
both `EntityType` and `EntitySet`, the annotation was assigned to the entity type. Extending an
|
|
1106
|
-
`AppliesTo=[EntitySet]` with `EntityType` would be OData compliant but incompatible for clients
|
|
1107
|
-
which still expect the annotation at the set and do not perform the full lookup.
|
|
1108
|
-
With this change, `EntitySet` and `EntityType` are treated individually, effectively annotating the type and
|
|
1109
|
-
(if available) the set. This fixes both extendability and client behavior.
|
|
1110
|
-
|
|
1111
|
-
### Fixed
|
|
1112
|
-
|
|
1113
|
-
- Structured foreign key and forward association reference paths used in ON condition definitions
|
|
1114
|
-
are now translatable into the correct short form ON condition paths in Association to Join translation.
|
|
1115
|
-
- to.hdbcds: Aliased mixin-associations are now handled correctly
|
|
1116
|
-
|
|
1117
|
-
## Version 1.48.0 - 2021-01-15
|
|
1118
|
-
|
|
1119
|
-
### Changed
|
|
1120
|
-
|
|
1121
|
-
- to.hdbcds/hdi/sql: Reject using associations or compositions in query elements starting with `$self` or `$projection`.
|
|
1122
|
-
- OData: Update vocabularies 'Common', 'PersonalData', 'UI'.
|
|
1123
|
-
|
|
1124
|
-
### Fixed
|
|
1125
|
-
|
|
1126
|
-
- Using a hex literal like `x'D028'` (in a CSN input) could lead to an error.
|
|
1127
|
-
- for.odata:
|
|
1128
|
-
+ Fix a bug in constraint calculation if principal has no primary keys.
|
|
1129
|
-
+ Don't overwrite user defined `@Core.Computed` annotation.
|
|
1130
|
-
- to.hdi/sql/hdbcds: Fixed a bug during processing of skipped/otherwise not db-relevant artifacts.
|
|
1131
|
-
|
|
1132
|
-
## Version 1.47.0 - 2020-12-11
|
|
1133
|
-
|
|
1134
|
-
### Changed
|
|
1135
|
-
|
|
1136
|
-
- Update vocabularies 'Aggregation', 'Common'
|
|
1137
|
-
|
|
1138
|
-
### Fixed
|
|
1139
|
-
|
|
1140
|
-
- to.hdbcds/hdi/sql:
|
|
1141
|
-
+ Types are not rendered anymore for SAP HANA in quoted mode.
|
|
1142
|
-
+ Aliases are now respected when resolving $self
|
|
1143
|
-
+ Association clones are now pre-pended with three underscores (`_`) instead of two
|
|
1144
|
-
to prevent shadowing of context names or usings
|
|
1145
|
-
|
|
1146
|
-
## Version 1.46.6 - 2020-12-01
|
|
1147
|
-
|
|
1148
|
-
### Fixed
|
|
1149
|
-
|
|
1150
|
-
- OData identifiers can now include all unicode characters which are described in the OData specification.
|
|
1151
|
-
|
|
1152
|
-
## Version 1.46.4 - 2020-11-28
|
|
1153
|
-
|
|
1154
|
-
### Fixed
|
|
1155
|
-
|
|
1156
|
-
- Association to Join translation: Fix using forward association target as table alias in ON condition.
|
|
1157
|
-
|
|
1158
|
-
## Version 1.46.2 - 2020-11-20
|
|
1159
|
-
|
|
1160
|
-
### Fixed
|
|
1161
|
-
|
|
1162
|
-
- to.edm(x) Fix a bug in the alias calculation for key references in structured OData.
|
|
1163
|
-
|
|
1164
|
-
## Version 1.46.0 - 2020-11-20
|
|
1165
|
-
|
|
1166
|
-
### Changed
|
|
1167
|
-
|
|
1168
|
-
- to.edm(x):
|
|
1169
|
-
+ V4 structured key ref path aliases are now the basenames, colliding aliases are numbered.
|
|
1170
|
-
+ Lower level to `info` for "‹Term› is not applied" message if an annotation cannot be applied.
|
|
1171
|
-
- OData:
|
|
1172
|
-
+ Update vocabulary 'UI'
|
|
1173
|
-
+ Correctly handle `not null` during flattening. Only if the parent and all subelements in the chain
|
|
1174
|
-
are `not null`, make the corresponding flat leaf element `not null`.
|
|
1175
|
-
|
|
1176
|
-
### Fixed
|
|
1177
|
-
|
|
1178
|
-
- Do not consider events to be potential targets for implicit redirections:
|
|
1179
|
-
strange warnings for multiple projections or other strange errors disappear.
|
|
1180
|
-
- to.hdbcds/hdi/sql:
|
|
1181
|
-
+ Reject structured view parameters for HANA.
|
|
1182
|
-
+ Correctly handle `not null` during flattening.
|
|
1183
|
-
Only if the parent and all subelements in the chain are `not null`, make the corresponding flat leaf element `not null`.
|
|
1184
|
-
- to.edm(x): Render @assert.range enum annotations correctly (enum symbol as value and don't omit zero value).
|
|
1185
|
-
- Fixed CDS module resolution with option `newResolve` on Windows where a superfluous `\` was prepended to absolute paths.
|
|
1186
|
-
|
|
1187
|
-
## Version 1.45.0 - 2020-10-30
|
|
1188
|
-
|
|
1189
|
-
### Added
|
|
1190
|
-
|
|
1191
|
-
- OData: Warn about non-applicable annotations.
|
|
1192
|
-
|
|
1193
|
-
### Changed
|
|
1194
|
-
|
|
1195
|
-
- A warning is emitted for annotation definitions inside services/contexts as this won't be
|
|
1196
|
-
allowed in the next major cds-compiler release.
|
|
1197
|
-
- OData: Update vocabularies 'Analytics' and 'Common'.
|
|
1198
|
-
|
|
1199
|
-
### Fixed
|
|
1200
|
-
|
|
1201
|
-
- Association to Join translation: Fill empty select blocks with aliased columns.
|
|
1202
|
-
- to.edm(x):
|
|
1203
|
-
+ Some EDM(x) warnings were not properly passed to the user.
|
|
1204
|
-
+ Don't render references and annotations for unexposed associations.
|
|
1205
|
-
- to.hdbcds: Warnings during rendering of the hdbcds were not raised to the user.
|
|
1206
|
-
- Issue which led to wrong on-conditions for `hdbcds` naming mode.
|
|
1207
|
-
|
|
1208
|
-
## Version 1.44.4 - 2020-10-16
|
|
1209
|
-
|
|
1210
|
-
### Fixed
|
|
1211
|
-
|
|
1212
|
-
- to.hdbcds/hdi/sql: The processing of managed associations as foreign keys now works regardless of the order in which the possible chains are resolved.
|
|
1213
|
-
- OData: Namespaces are brought back into the exposed types. Dots are replaced with underscores in the name.
|
|
1214
|
-
|
|
1215
|
-
## Version 1.44.2 - 2020-10-09
|
|
1216
|
-
|
|
1217
|
-
### Added
|
|
1218
|
-
|
|
1219
|
-
- OData: The annotations `@assert.format` and `@assert.range` now result in adding the
|
|
1220
|
-
`@Validation.Pattern` and `@Validation.AllowedValues` in the resulting EDMX.
|
|
1221
|
-
- A new compiler option `newResolve` is added (`--new-resolve` for `cdsc`). When set to `true` a new
|
|
1222
|
-
module resolver is used which needs fewer file lookups. It will become the default in the future.
|
|
1223
|
-
- Event definitions can be typed with a reference to an event.
|
|
1224
|
-
- When the new option `withLocation` is set,
|
|
1225
|
-
the property `$location` in the CSN is enumerable instead of non-enumerable;
|
|
1226
|
-
the value of `$location` is an object with sub properties `file`, `line` and `col`
|
|
1227
|
-
which describes the source position of all definitions, elements and other members.
|
|
1228
|
-
|
|
1229
|
-
### Changed
|
|
1230
|
-
|
|
1231
|
-
- OData:
|
|
1232
|
-
+ The `namespace` is now not part of the exposed type's name.
|
|
1233
|
-
+ Update vocabularies 'Aggregation', 'UI' and 'Validation'.
|
|
1234
|
-
|
|
1235
|
-
## Version 1.43.0 - 2020-10-02
|
|
1236
|
-
|
|
1237
|
-
### Added
|
|
1238
|
-
|
|
1239
|
-
- The magic variable `$session` is now supported. All element accesses are unchecked.
|
|
1240
|
-
- Reference paths as annotation values can now contain identifiers starting with `@`.
|
|
1241
|
-
|
|
1242
|
-
### Changed
|
|
1243
|
-
|
|
1244
|
-
- OData:
|
|
1245
|
-
+ Raise message level for illegal OData identifiers from warning to error.
|
|
1246
|
-
+ Update vocabularies 'Aggregation' and 'Common'.
|
|
1247
|
-
|
|
1248
|
-
### Fixed
|
|
1249
|
-
|
|
1250
|
-
- to.hdi/hdbcds/sql: Correctly process the elements of subqueries in localized view variants
|
|
1251
|
-
|
|
1252
|
-
### Removed
|
|
1253
|
-
|
|
1254
|
-
### Fixed
|
|
1255
|
-
|
|
1256
|
-
- OData: put default value validation under `beta:odataDefaultValues`
|
|
1257
|
-
|
|
1258
|
-
## Version 1.42.2 - 2020-09-29
|
|
1259
|
-
|
|
1260
|
-
### Fixed
|
|
1261
|
-
|
|
1262
|
-
- CDL: Action blocks can now be empty, e.g. `entity E {…} actions { }`.
|
|
1263
|
-
- An info message is emitted if builtin types are annotated. Use a custom type instead.
|
|
1264
|
-
Annotating builtins in CDL is possible but when transformed into CSN the annotation was silently lost.
|
|
1265
|
-
It is now put into the "extensions" property of the CSN.
|
|
1266
|
-
- Fixed `cast()` for simple values like numbers and strings.
|
|
1267
|
-
|
|
1268
|
-
- to.sql:
|
|
1269
|
-
+ Remove simple default value checks and allow the database to reject default values upon activation.
|
|
1270
|
-
+ Render empty actual parameter list when selecting from a view with parameters which are fully covered with
|
|
1271
|
-
default values and no actual parameters are provided in the query itself.
|
|
1272
|
-
|
|
1273
|
-
- OData:
|
|
1274
|
-
+ Correctly render unary operator of default values in EDM.
|
|
1275
|
-
|
|
1276
|
-
## Version 1.42.0 - 2020-09-25
|
|
1277
|
-
|
|
1278
|
-
### Added
|
|
1279
|
-
|
|
1280
|
-
- The compiler now supports the `cast(element as Type)` function in queries.
|
|
1281
|
-
Using this function will also result in a `CAST` SQL function call.
|
|
1282
|
-
- A top-level property `i18n` is now supported. The property can contain translated texts.
|
|
1283
|
-
The compiler expects its entries to be objects where each text value is a string.
|
|
1284
|
-
- CDL: Empty selection lists in views/projections are now allowed and make it possible to extend
|
|
1285
|
-
empty projections. Note that views/projections without any elements are not deployable.
|
|
1286
|
-
- For CSNs as input, the compiler returns properties as they are (without checks)
|
|
1287
|
-
if their name does not match the regexp `/[_$]?[a-zA-Z]+[0-9]*/` and does not start with `@`.
|
|
1288
|
-
With more than one CSN input,
|
|
1289
|
-
the compiler only returns the top-level CSN properties of the first source.
|
|
1290
|
-
|
|
1291
|
-
### Changed
|
|
1292
|
-
|
|
1293
|
-
- to.cdl: Smart type references are now explicitly rendered via ":"-syntax
|
|
1294
|
-
|
|
1295
|
-
### Removed
|
|
1296
|
-
|
|
1297
|
-
### Fixed
|
|
1298
|
-
|
|
1299
|
-
- Annotating an _unknown_ element _twice_ now results in a duplicate annotation error instead
|
|
1300
|
-
of silently loosing the annotation.
|
|
1301
|
-
- Service/context extensions that reference a non-service/non-context now result in a compiler error
|
|
1302
|
-
instead of silently loosing the context/service extension.
|
|
1303
|
-
- to.hdbcds/sql/hdi:
|
|
1304
|
-
+ fix a bug, which resulted in a malformed on-condition, if an association key
|
|
1305
|
-
was another association pointing to an entitiy with a structured key.
|
|
1306
|
-
+ in conjunction with assoc-to-joins, the internal CSN reference broke
|
|
1307
|
-
causing missing locations and even internal errors when logging messages
|
|
1308
|
-
+ managed associations in UNION are now correctly processed
|
|
1309
|
-
- The parseCdl mode now correctly resolves type arguments of "many" types.
|
|
1310
|
-
- OData: The annotation `@Capabilities.Readable` is now correctly
|
|
1311
|
-
translated to `@Capabilities.ReadRestrictions.Readable`.
|
|
1312
|
-
|
|
1313
|
-
## Version 1.41.4 - 2020-09-18
|
|
1314
|
-
|
|
1315
|
-
### Removed
|
|
1316
|
-
|
|
1317
|
-
- The length of HANA identifiers are not checked anymore: no more warnings are issued for long identifiers.
|
|
1318
|
-
|
|
1319
|
-
### Fixed
|
|
1320
|
-
|
|
1321
|
-
- The check for ignored "localized" keywords in sub-elements has been extended to also
|
|
1322
|
-
include references to structured types.
|
|
1323
|
-
- A warning was added if views/projections are used as element types.
|
|
1324
|
-
- An info message is emitted if a namespace is annotated.
|
|
1325
|
-
Annotating namespaces is not possible. Previously the annotation was silently lost.
|
|
1326
|
-
It is now put into the "extensions" property of the CSN.
|
|
1327
|
-
|
|
1328
|
-
## Version 1.41.2 - 2020-09-15
|
|
1329
|
-
|
|
1330
|
-
### Fixed
|
|
1331
|
-
|
|
1332
|
-
- OData: correctly render primary key associations targeting a composition parent but are not
|
|
1333
|
-
the composition enabling association.
|
|
1334
|
-
- to.hdbcds/sql/hdi: Do not dump if artifact doesn't exist anymore after association to join translation
|
|
1335
|
-
- Only check for unmanaged associations inside of "many"/"array of" in the elements of views and entities,
|
|
1336
|
-
not inside of actions and other members.
|
|
1337
|
-
|
|
1338
|
-
## Version 1.41.0 - 2020-09-11
|
|
1339
|
-
|
|
1340
|
-
### Added
|
|
1341
|
-
|
|
1342
|
-
- OData: Allow the relational comparison of structures or managed associations in an ON condition as described in
|
|
1343
|
-
version 1.32.0 - 2020-07-10 (forHana).
|
|
1344
|
-
- Allow `Struct:elem` with and without preceeding `type of` as type reference.
|
|
1345
|
-
|
|
1346
|
-
### Fixed
|
|
1347
|
-
|
|
1348
|
-
- to.cdl: Only render enums if they were directly defined there
|
|
1349
|
-
- The parseCdl mode now checks for redefinitions to avoid generating invalid CSN.
|
|
1350
|
-
- OData: An error is thrown if a redirected target has fewer keys than the original one.
|
|
1351
|
-
- OData: Empty structured elements are now handled correctly in `flat` format.
|
|
1352
|
-
|
|
1353
|
-
## Version 1.40.0 - 2020-09-04
|
|
1354
|
-
|
|
1355
|
-
### Added
|
|
1356
|
-
|
|
1357
|
-
- to.hdi/sql: Support default values for view parameters.
|
|
1358
|
-
- OData: lower message severity from Error to Warning for
|
|
1359
|
-
`<entity type> has no primary key` and `<type> has no properties`.
|
|
1360
|
-
|
|
1361
|
-
### Changed
|
|
1362
|
-
|
|
1363
|
-
- OData: The foreign key references in associations are not flattened any more with format `structured`.
|
|
1364
|
-
|
|
1365
|
-
### Fixed
|
|
1366
|
-
|
|
1367
|
-
- parse.cdl: Properly handle type arguments, most likely relevant for HANA types.
|
|
1368
|
-
- OData: Multilevel anonymously defined `composition of <aspect>` is now processed successfully with the OData backend.
|
|
1369
|
-
- OData: Fix a bug in EDM generation that caused a dump.
|
|
1370
|
-
- Update ANTLR dependency to version 4.8.
|
|
1371
|
-
|
|
1372
|
-
## Version 1.39.0 - 2020-08-26
|
|
1373
|
-
|
|
1374
|
-
### Added
|
|
1375
|
-
|
|
1376
|
-
- If the first CDS source (CDL or CSN) provided to the compiler
|
|
1377
|
-
has a `namespace` declaration/property, then
|
|
1378
|
-
that namespace name is put into the property `namespace` of the returned CSN.
|
|
1379
|
-
- An event payload type can now be defined with a type/entity reference or
|
|
1380
|
-
or projection (instead of providing the elements directly).
|
|
1381
|
-
- Aspects can now be included when specifying the elements of an event payload type,
|
|
1382
|
-
as it is known for type, entity and aspect definitions.
|
|
1383
|
-
|
|
1384
|
-
### Fixed
|
|
1385
|
-
|
|
1386
|
-
- Fix a bug in explicit JOIN cardinality CDL parsing
|
|
1387
|
-
- to.hdbcds/hdi/sql: Identifiers are checked and warnings are raised if the identifier exceeds a length limitation which would result in a deployment error.
|
|
1388
|
-
- OData: Service, entity and element identifiers are checked and warnings are raised if an identifier is not compliant with the OData specification.
|
|
1389
|
-
|
|
1390
|
-
## Version 1.38.0 - 2020-08-25
|
|
1391
|
-
|
|
1392
|
-
### Changed
|
|
1393
|
-
|
|
1394
|
-
- CSN: The property `payload` of an `event` has been renamed to `elements`.
|
|
1395
|
-
|
|
1396
|
-
### Fixed
|
|
1397
|
-
|
|
1398
|
-
- to.hdbcds/hdi/sql: Correctly handle local-scope refs in on-conditions when flattening structures.
|
|
1399
|
-
- Run checks for associations inside of `many` or `array of` only on entities and views.
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
## Version 1.37.0 - 2020-08-21
|
|
1403
|
-
|
|
1404
|
-
### Added
|
|
1405
|
-
|
|
1406
|
-
- Projections columns can now use expressions like select items,
|
|
1407
|
-
both for `entity … as projection on` and `extend projection … with`.
|
|
1408
|
-
- OData: `array of <structure>` or `many <structure>` is now allowed in OData V4, flat format.
|
|
1409
|
-
|
|
1410
|
-
### Changed
|
|
1411
|
-
|
|
1412
|
-
- to.hdbcds/hdi/sql:
|
|
1413
|
-
+ Messages of id "query-no-undefined" are now raised as errors.
|
|
1414
|
-
+ Aspects/types/abstract entities containing anonymous aspect compositions
|
|
1415
|
-
must not be used as types and are removed during transformation.
|
|
1416
|
-
|
|
1417
|
-
### Fixed
|
|
1418
|
-
|
|
1419
|
-
- to.cdl: Events are rendered.
|
|
1420
|
-
- to.cds: Anonymous aspect composition are now rendered correctly.
|
|
1421
|
-
- to.hdbcds/hdi/sql:
|
|
1422
|
-
+ Events are ignored.
|
|
1423
|
-
+ local-scope references in on-conditions are now handled correctly during flattening.
|
|
1424
|
-
+ Removed duplicate messages.
|
|
1425
|
-
- A model with multilevel `composition of <aspect>` (spread across several aspect declarations,
|
|
1426
|
-
composing one another) is now processed successfully with the OData backend.
|
|
1427
|
-
- The CSN parser supports explicit join cardinalities.
|
|
1428
|
-
- Prefix a `@assert.unique` table constraint with the table name to avoid name clashes.
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
## Version 1.36.0 - 2020-08-07
|
|
1432
|
-
|
|
1433
|
-
### Added
|
|
1434
|
-
|
|
1435
|
-
- Query select items can now be declared to be virtual.
|
|
1436
|
-
|
|
1437
|
-
- CQL now allows to specify a join cardinality. Allowed are any combinations of
|
|
1438
|
-
`{ [ EXACT ] ONE | MANY } TO { [ EXACT ] ONE | MANY }` for
|
|
1439
|
-
`{ INNER | { LEFT | RIGHT | FULL } [ OUTER ] }` joins.
|
|
1440
|
-
The cardinality is added in the for HANA generated `CREATE VIEW` statements.
|
|
1441
|
-
|
|
1442
|
-
- Support the creation of unique constraints by assigning `@assert.unique.<constraintName>` to
|
|
1443
|
-
non-query entities or query entities annotated with `@cds.persistence.table`. The value of the
|
|
1444
|
-
annotation is an array of paths referring to elements in the entity. The path leaf may
|
|
1445
|
-
be an element of a scalar, structured or managed association type. Individual foreign keys or
|
|
1446
|
-
unmanaged associations can not be accessed. In case the path points to a structured element,
|
|
1447
|
-
the unique constraint will contain all columns stemming from the structured type. In case
|
|
1448
|
-
the path points to a managed association, the unique constraint will contain all foreign key
|
|
1449
|
-
columns stemming from this managed association.
|
|
1450
|
-
For HANA a `UNIQUE INVERTED INDEX` and for SQLite a `named unique table constraint` is generated.
|
|
1451
|
-
|
|
1452
|
-
### Changed
|
|
1453
|
-
|
|
1454
|
-
- OData: Update vocabularies 'Common', 'UI'
|
|
1455
|
-
- The association to join transformation treats foreign key accesses with priority. If a foreign key
|
|
1456
|
-
of a managed association can be accessed without joins, no joins are generated.
|
|
1457
|
-
The priority handling can be turned of with option `joinfk`.
|
|
1458
|
-
|
|
1459
|
-
### Fixed
|
|
1460
|
-
|
|
1461
|
-
- Semantic location in messages is now more precise.
|
|
1462
|
-
|
|
1463
|
-
## Version 1.35.0 - 2020-07-31
|
|
1464
|
-
|
|
1465
|
-
### Added
|
|
1466
|
-
|
|
1467
|
-
- Introduce option `localizedLanguageFallback`; if set to value `"none"`, the localized
|
|
1468
|
-
convenience views do not use function `coalesce` to select from a default text as fallback.
|
|
1469
|
-
|
|
1470
|
-
### Fixed
|
|
1471
|
-
|
|
1472
|
-
- Properly consider targets of compositions in `mixin`s to be autoexposed.
|
|
1473
|
-
- Uniformly limit propagation of `@cds.autoexposed`, i.e.
|
|
1474
|
-
there is not inheritance from a query source navigating along an association.
|
|
1475
|
-
Previously, compiling a compiled model could lead to new autoexposed entities.
|
|
1476
|
-
- OData:
|
|
1477
|
-
+ V2: Distribute various `@sap` specific annotations to the entity container.
|
|
1478
|
-
+ Always set attribute `Nullable` on properties of type `Collection()`.
|
|
1479
|
-
|
|
1480
|
-
## Version 1.34.0 - 2020-07-27
|
|
1481
|
-
|
|
1482
|
-
### Fixed
|
|
1483
|
-
|
|
1484
|
-
- Do not dump with illegal references in explicit `on` conditions of redirections;
|
|
1485
|
-
properly report them via error messages.
|
|
1486
|
-
|
|
1487
|
-
## Version 1.33.0 - 2020-07-24
|
|
1488
|
-
|
|
1489
|
-
### Added
|
|
1490
|
-
|
|
1491
|
-
- Allow to declare `many/array of` elements, parameters and return types to be `(not) null`.
|
|
1492
|
-
The nullability applies to the array items of the element, not the element itself.
|
|
1493
|
-
- New boolean option `dependentAutoexposed` to avoid name clashes in dependent
|
|
1494
|
-
autoexposed entities (text entities, components of managed compositions).
|
|
1495
|
-
- cdsc: Add toOdata version 'v4x' to combine `{ version: 'v4', odataFormat: 'structured', odataContainment: true }`.
|
|
1496
|
-
|
|
1497
|
-
### Changed
|
|
1498
|
-
|
|
1499
|
-
- OData:
|
|
1500
|
-
+ Update vocabularies 'Common', 'Core', 'ODM'.
|
|
1501
|
-
+ The default nullability for collection value properties is `false`, indicating that the returned collection must
|
|
1502
|
-
not contain null value entries.
|
|
1503
|
-
- toCdl: Identifiers are now quoted with `![` and `]`. Inner `]` characters are escaped with `]]`.
|
|
1504
|
-
- toCdl/toSql: Function names containing non standard HANA identifier characters are rendered case preserving and quoted
|
|
1505
|
-
if an appropriate naming mode has been set in the options.
|
|
1506
|
-
|
|
1507
|
-
### Fixed
|
|
1508
|
-
|
|
1509
|
-
- forHana: Correctly flatten managed associations as foreign keys used in the definition.
|
|
1510
|
-
of another managed association.
|
|
1511
|
-
- OData: Don't render aspects as `edm.ComplexType`.
|
|
1512
|
-
|
|
1513
|
-
## Version 1.32.0 - 2020-07-10
|
|
1514
|
-
|
|
1515
|
-
### Added
|
|
1516
|
-
|
|
1517
|
-
- Provide semantic code completion for elements, enums, actions and parameters
|
|
1518
|
-
in `annotate` and `extend`.
|
|
1519
|
-
- forHana: Allow the relational comparison of structures or managed associations in an ON condition.
|
|
1520
|
-
Both operands must be structurally compatible, that is both structures must be expandable
|
|
1521
|
-
to an identical set of leaf paths. Each leaf path must terminate on a builtin CDS scalar type.
|
|
1522
|
-
The original relational term of the form `s1 op s2` is replaced by the resulting expression
|
|
1523
|
-
`s1.leafpath_0 op s2.leafpath_0 (AND s1.leafpath_i op s2.leafpath_i)*` with `i < n leaf paths`.
|
|
1524
|
-
|
|
1525
|
-
### Changed
|
|
1526
|
-
|
|
1527
|
-
- toCdl: String enums without a value are no longer rendered with their name's string representation as their value.
|
|
1528
|
-
|
|
1529
|
-
### Fixed
|
|
1530
|
-
|
|
1531
|
-
- parseCdl: Fix missing extensions in files that extend unknown services/contexts.
|
|
1532
|
-
- OData: Do not render an EDM document in case of raised errors
|
|
1533
|
-
- to.cdl: Aspects are now correctly rendered as aspects and not as types
|
|
1534
|
-
|
|
1535
|
-
## Version 1.31.2 - 2020-07-03
|
|
1536
|
-
|
|
1537
|
-
### Fixed
|
|
1538
|
-
|
|
1539
|
-
- HANA/SQLite: Correctly handle already resolved types when a cds.linked CSN is passed in
|
|
1540
|
-
- HANA/SQLite: Ensure that all elements in a Draft are non-virtual
|
|
1541
|
-
|
|
1542
|
-
## Version 1.31.0 - 2020-06-26
|
|
1543
|
-
|
|
1544
|
-
### Added
|
|
1545
|
-
|
|
1546
|
-
- forHana/toSql: A (proxy) entity representing a HANA User Defined Function or a HANA Calculation View
|
|
1547
|
-
can now be annotated with `@cds.persistence { udf, calcview }` so that queries to these artifacts are
|
|
1548
|
-
rendered with the appropriate parameter lists. Parameters for HANA Calculation Views are decorated with
|
|
1549
|
-
`PLACEHOLDER."$$<id>$$"`. HANA User Defined Functions without arguments require an empty argument
|
|
1550
|
-
list `()` as part of the query source.
|
|
1551
|
-
Entities that are assigned with `@cds.persistence { udf, calcview }` cannot contain associations or act as
|
|
1552
|
-
association targets, even if they have no defined parameter list.
|
|
1553
|
-
Multiple assignments of `@cds.persistence { table, udf, calcview }` to the same entity are rejected.
|
|
1554
|
-
- OData V4: Elements with type `array of <scalar type>` are now supported in flat mode
|
|
1555
|
-
|
|
1556
|
-
### Changed
|
|
1557
|
-
|
|
1558
|
-
- Option `beta` now only works with selective feature flags. Instead of `beta: true`, a dictionary of `<feature>: true` is expected. Available feature flags are:
|
|
1559
|
-
1. subElemRedirections
|
|
1560
|
-
2. keyRefError
|
|
1561
|
-
3. aspectCompositions
|
|
1562
|
-
4. odataProxies
|
|
1563
|
-
5. uniqueconstraints
|
|
1564
|
-
- OData V4: Unmanaged associations/compositions with a target cardinality of exactly one (that is `[1..1]`)
|
|
1565
|
-
are rendered as `edmx:NavigationProperty` with attribute `Nullable="false"`
|
|
1566
|
-
- OData: On-condition checks are now performed when generating OData as well.
|
|
1567
|
-
- SQLite: The property length for string parameters is not longer restricted to 5000 characters.
|
|
1568
|
-
- HANA/SQLite: Improved the error message when an entity without elements is found to make it clearer what is expected.
|
|
1569
|
-
|
|
1570
|
-
### Fixed
|
|
1571
|
-
|
|
1572
|
-
- An error is emitted if parameters in functions/actions have a default value as it is not yet supported.
|
|
1573
|
-
For example by using `type of E:element` where `element` has a default value.
|
|
1574
|
-
- OData V2: Derived scalar types are not rendered as `<edmx:TypeDefinition>`, so no annotation assignments to
|
|
1575
|
-
such carriers must be rendered.
|
|
1576
|
-
- HANA/SQLite: Fixed a bug when flattening structured elements - instead of a human-readable error, an exception was thrown.
|
|
1577
|
-
|
|
1578
|
-
## Version 1.30.0 - 2020-06-12
|
|
1579
|
-
|
|
1580
|
-
### Added
|
|
1581
|
-
|
|
1582
|
-
- Projections can now have `where` and `group by`/`having` clauses.
|
|
1583
|
-
|
|
1584
|
-
### Changed
|
|
1585
|
-
|
|
1586
|
-
### Fixed
|
|
1587
|
-
|
|
1588
|
-
- `doc` comments in CDL now support Windows-style line breaks (CRLF). They are replaced with `\n` in CSN.
|
|
1589
|
-
- `toCdl` no longer renders a `*` column if no columns are used in the original source.
|
|
1590
|
-
- Types that have both `type` and `items`/`elements` properties in CSN are now checked to avoid
|
|
1591
|
-
mismatches if a unstructured / non-arrayed type is referenced but `items`/`elements` exists.
|
|
1592
|
-
- OData:
|
|
1593
|
-
+ Correctly render CRLF and LF to __
__ in EDMX
|
|
1594
|
-
|
|
1595
|
-
## Version 1.29.0 - 2020-06-08
|
|
1596
|
-
|
|
1597
|
-
### Added
|
|
1598
|
-
|
|
1599
|
-
- Projections can now have `limit` and `order by` clauses.
|
|
1600
|
-
|
|
1601
|
-
### Changed
|
|
1602
|
-
|
|
1603
|
-
- OData: Update vocabularies 'CodeList', 'Common', 'Graph', 'UI'
|
|
1604
|
-
|
|
1605
|
-
### Fixed
|
|
1606
|
-
|
|
1607
|
-
- Memory usage improvement - compile messages with id `ref-undefined-excluding` uses much less memory.
|
|
1608
|
-
|
|
1609
|
-
- HANA/SQL: Validate ON conditions of mixin association definitions in all subqueries
|
|
1610
|
-
|
|
1611
|
-
- OData V2: Assign various `@sap` annotations to the `<edmx:EnitySet>` and `<edmx:AssociationSet>`
|
|
1612
|
-
if such annotations are assigned to CDS entities or associations.
|
|
1613
|
-
|
|
1614
|
-
- OData V4 Structured: Omit foreign keys of managed associations that establish the containment relationship to
|
|
1615
|
-
a container, if this association was declared to be primary key.
|
|
1616
|
-
|
|
1617
|
-
- OData: Warn about non-integer enums as they are not supported by OData, yet.
|
|
1618
|
-
|
|
1619
|
-
- Warn about string values in integer enums and vice versa.
|
|
1620
|
-
|
|
1621
|
-
## Version 1.28.0 - 2020-05-27
|
|
1622
|
-
|
|
1623
|
-
### Added
|
|
1624
|
-
|
|
1625
|
-
- API: add `getArtifactCdsPersistenceName()` and `getElementCdsPersistenceName()` which return
|
|
1626
|
-
the value of annotation `@cds.persistence.name` for the corresponding artifact/element.
|
|
1627
|
-
|
|
1628
|
-
### Changed
|
|
1629
|
-
|
|
1630
|
-
- Issue error if old backends are used with beta mode.
|
|
1631
|
-
- Raise severity of message `Unmanaged associations cannot be used as primary key` with id `unmanaged-as-key` to error.
|
|
1632
|
-
|
|
1633
|
-
### Fixed
|
|
1634
|
-
|
|
1635
|
-
- OData:
|
|
1636
|
-
+ Render vocabulary `<edmx:Reference>` and `<edmx:Include>` if vocabulary namespace was used.
|
|
1637
|
-
+ Reduce memory consumption in EDM Renderer.
|
|
1638
|
-
+ Render annotations for navigation properties if association is annotated with `@cds.api.ignore: true`.
|
|
1639
|
-
|
|
1640
|
-
## Version 1.27.0 - 2020-05-15
|
|
1641
|
-
|
|
1642
|
-
### Added
|
|
1643
|
-
|
|
1644
|
-
### Changed
|
|
1645
|
-
|
|
1646
|
-
- Improve warning messages for integer enum missing a value and chained array of.
|
|
1647
|
-
- HANA/SQL
|
|
1648
|
-
+ Empty structures are not allowed as foreign keys.
|
|
1649
|
-
- Report a warning for integer enum elements that do not have values.
|
|
1650
|
-
- Report a warning for enums that are not integer- or string-like.
|
|
1651
|
-
- OData
|
|
1652
|
-
+ Update vocabularies 'Common', 'Core', 'Validation'
|
|
1653
|
-
+ Pass through structures without elements
|
|
1654
|
-
+ `cds.Decimal` and `cds.DecimalFloat` (deprecated) without precision/scale are rendered
|
|
1655
|
-
as `Edm.Decimal` with `Scale=variable` (V4) and `sap:variable-scale="true"` (V2)
|
|
1656
|
-
|
|
1657
|
-
### Fixed
|
|
1658
|
-
|
|
1659
|
-
- Memory usage improvement - compile messages do not inherit from Error any more.
|
|
1660
|
-
- HANA types in annotation assignments work again.
|
|
1661
|
-
- HANA/SQL: Correctly handle temporal in conjunction with namespaces.
|
|
1662
|
-
- Fix a bug in Association to Join translation that prevents exposing managed associations via subqueries.
|
|
1663
|
-
|
|
1664
|
-
### Removed
|
|
1665
|
-
|
|
1666
|
-
## Version 1.26.4 - 2020-05-08
|
|
1667
|
-
|
|
1668
|
-
### Added
|
|
1669
|
-
|
|
1670
|
-
- Add new OData vocabulary `com.sap.vocabularies.HTML5.v1`
|
|
1671
|
-
|
|
1672
|
-
### Changed
|
|
1673
|
-
|
|
1674
|
-
- Report a warning when a deprecated non-snapi backend (OData, HANA/SQL) is called.
|
|
1675
|
-
|
|
1676
|
-
- OData:
|
|
1677
|
-
+ Update vocabulary 'UI'
|
|
1678
|
-
+ Add annotation `@Common.Label: '{i18n>Draft_DraftAdministrativeData}'` to entity `DraftAdministrativeData`
|
|
1679
|
-
+ Improve info message for target mismatch on associations that are compared with $self
|
|
1680
|
-
|
|
1681
|
-
### Fixed
|
|
1682
|
-
|
|
1683
|
-
- The CSN `val` property is now allowed in enum element extensions. Such CSN can be
|
|
1684
|
-
generated using the `parseCdl` mode and it is now compilable.
|
|
1685
|
-
|
|
1686
|
-
- Again allow negative values as enum values, fixing a regression introduced with v1.24.6.
|
|
1687
|
-
|
|
1688
|
-
- OData: Correctly handle associations in arrayed elements (keyword `many`).
|
|
1689
|
-
|
|
1690
|
-
- Annotation assignment checks now recognize HANA types.
|
|
1691
|
-
|
|
1692
|
-
## Version 1.26.2 - 2020-04-24
|
|
1693
|
-
|
|
1694
|
-
### Added
|
|
1695
|
-
|
|
1696
|
-
- The client tool `cdsc` has got a new option `--beta <list>` which may be used to
|
|
1697
|
-
specify a comma separated list of experimental features to be enabled.
|
|
1698
|
-
|
|
1699
|
-
- CSN in parse-cdl mode now has a `requires` property that represents `using`s from CDL.
|
|
1700
|
-
|
|
1701
|
-
### Fixed
|
|
1702
|
-
|
|
1703
|
-
- OData:
|
|
1704
|
-
+ Change foreign key creation order for associations to respect their dependencies.
|
|
1705
|
-
+ Use correct path during on-condition flattening.
|
|
1706
|
-
+ Report error when using elements without types for **array of type of (element)** and similar definitions.
|
|
1707
|
-
|
|
1708
|
-
- HANA/SQL:
|
|
1709
|
-
+ Fix references to `null` enum values in default clauses.
|
|
1710
|
-
|
|
1711
|
-
- Type arguments are now properly set in CSN when using parse-cdl mode.
|
|
1712
|
-
|
|
1713
|
-
- Avoid unjust warning if the `extensions` property of an input CSN contain `extend` statements.
|
|
1714
|
-
|
|
1715
|
-
## Version 1.26.0 - 2020-04-17
|
|
1716
|
-
|
|
1717
|
-
### Added
|
|
1718
|
-
|
|
1719
|
-
- The client tool `cdsc` has got a new command `parseCdl` which returns a CSN
|
|
1720
|
-
that is close to the original CDL file. It does not resolve imports and does
|
|
1721
|
-
not apply extensions.
|
|
1722
|
-
|
|
1723
|
-
- Unmanaged associations as primary keys are now warned about.
|
|
1724
|
-
|
|
1725
|
-
- `localized` in combination with `key` is now warned about.
|
|
1726
|
-
|
|
1727
|
-
- Enum values are now checked to only be either numbers or a strings - a warning is raised.
|
|
1728
|
-
|
|
1729
|
-
- Elements in mixin clauses that are _not_ unmanaged associations now produce an error.
|
|
1730
|
-
|
|
1731
|
-
### Changed
|
|
1732
|
-
|
|
1733
|
-
- HANA/SQL:
|
|
1734
|
-
+ Raise warnings `rewrite-not-supported` and `rewrite-undefined-key` to errors.
|
|
1735
|
-
|
|
1736
|
-
- Compiler: Empty elements are now kept along for the propagation.
|
|
1737
|
-
|
|
1738
|
-
- OData: Annotate all elements of `DraftAdministrativeData` with `@Common.Label: '{i18n>"Draft_<elementName>"}'`
|
|
1739
|
-
and elements 'DraftUUID', 'DraftIsCreatedByMe' and 'DraftIsProcessedByMe' with `@UI.Hidden`.
|
|
1740
|
-
|
|
1741
|
-
### Fixed
|
|
1742
|
-
|
|
1743
|
-
- Compiler: `type of <unmanaged assocation>` is now handled correctly by raising an error.
|
|
1744
|
-
|
|
1745
|
-
## Version 1.25.0 - 2020-04-09
|
|
1746
|
-
|
|
1747
|
-
### Changed
|
|
1748
|
-
|
|
1749
|
-
- Downgrade `chained array of`-error to a warning
|
|
1750
|
-
- SQLite: Don't render implicit casts
|
|
1751
|
-
|
|
1752
|
-
## Version 1.24.6 - 2020-04-08
|
|
1753
|
-
|
|
1754
|
-
### Changed
|
|
1755
|
-
|
|
1756
|
-
- OData:
|
|
1757
|
-
+ Improve messages for misaligned forward/backlink associations in EDM generator
|
|
1758
|
-
+ For V2 add annotations `@sap.creatable: false`, `@sap.updatable: false`, `@sap.deletable: false`,
|
|
1759
|
-
`@sap.pageable: false` to the Parameter EntityType and `@sap.creatable: false`, `@sap.updatable: false`,
|
|
1760
|
-
`@sap.deletable: false`, `@sap.addressable: false` to the Result EntityType.
|
|
1761
|
-
+ Update vocabularies 'Common' and 'Graph' and 'ODM'.
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
### Fixed
|
|
1765
|
-
|
|
1766
|
-
- Various messages mention more appropriate source locations.
|
|
1767
|
-
|
|
1768
|
-
- Improve messages for `array of`
|
|
1769
|
-
|
|
1770
|
-
- OData:
|
|
1771
|
-
+ Render 'array of' for ReturnType correctly
|
|
1772
|
-
+ Report error for view fields with no type information early
|
|
1773
|
-
+ Handle associations in structures with an association as explicit key
|
|
1774
|
-
|
|
1775
|
-
### Removed
|
|
1776
|
-
|
|
1777
|
-
- The client tool `cdsc` does not offer the option `--std-json-parser` anymore,
|
|
1778
|
-
as it had no effect.
|
|
1779
|
-
|
|
1780
|
-
## Version 1.24.4 - 2020-03-25
|
|
1781
|
-
|
|
1782
|
-
### Added
|
|
1783
|
-
|
|
1784
|
-
### Changed
|
|
1785
|
-
|
|
1786
|
-
- `doc` comment propagation can now also be stopped by comments that only contain whitespace
|
|
1787
|
-
(including newlines) like `/** */`.
|
|
1788
|
-
|
|
1789
|
-
- OData:
|
|
1790
|
-
+ Remove redundant service name and `__` prefix out of dynamically exposed substructures.
|
|
1791
|
-
+ Update vocabularies 'Capabilities' and 'Graph'.
|
|
1792
|
-
|
|
1793
|
-
### Fixed
|
|
1794
|
-
|
|
1795
|
-
- OData:
|
|
1796
|
-
+ Process correctly "type of".
|
|
1797
|
-
+ Process correctly elements with underscore as prefix.
|
|
1798
|
-
|
|
1799
|
-
- Preserve parameter list in localized convenience views.
|
|
1800
|
-
|
|
1801
|
-
## Version 1.24.3 - 2020-03-16
|
|
1802
|
-
|
|
1803
|
-
### Added
|
|
1804
|
-
|
|
1805
|
-
### Changed
|
|
1806
|
-
|
|
1807
|
-
### Fixed
|
|
1808
|
-
|
|
1809
|
-
- Force usage of resolve@1.8.1 instead of semver to avoid issues with file cache
|
|
1810
|
-
|
|
1811
|
-
## Version 1.24.2 - 2020-03-13
|
|
1812
|
-
|
|
1813
|
-
### Added
|
|
1814
|
-
|
|
1815
|
-
- Support function calls like `count( distinct ... )` and `count( all ... )`.
|
|
1816
|
-
|
|
1817
|
-
- With option `--doc-comment` comments of the form `/**...*/` are preserved, if these comments
|
|
1818
|
-
appear at positions where annotation assignments are allowed. `doc` comments are propagated
|
|
1819
|
-
like annotations until an empty comment `/***/` disrupts the propagation.
|
|
1820
|
-
|
|
1821
|
-
- OData:
|
|
1822
|
-
+ Add new OData vocabularies `com.sap.vocabularies.Graph.v1` and `com.sap.vocabularies.ODM.v1`
|
|
1823
|
-
+ With option `--odata-containment`, `parent` association and inferred key elements for
|
|
1824
|
-
`composition of <aspect>` as well as inferred keys of `_texts` entities are not rendered.
|
|
1825
|
-
+ OData V4: Produce primary key paths with length limited alias names.
|
|
1826
|
-
|
|
1827
|
-
### Changed
|
|
1828
|
-
|
|
1829
|
-
### Fixed
|
|
1830
|
-
|
|
1831
|
-
- When not disabled by `@cds.autoexpose:false`, an entity used as composition target
|
|
1832
|
-
is auto-exposed in the current service;
|
|
1833
|
-
this did not work always if the target was a _query_ entity.
|
|
1834
|
-
|
|
1835
|
-
- Foreign key creation in odata flat-mode when following associations.
|
|
1836
|
-
|
|
1837
|
-
- Rename `@description` to `@Core.Description` in all cases as part of the OData transformation of a CSN.
|
|
1838
|
-
|
|
1839
|
-
- When generating extensions from EDMX annotations, handle correctly targets from an EntityContainer.
|
|
1840
|
-
|
|
1841
|
-
- Apply service annotations in EDMX generation.
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
### Removed
|
|
1845
|
-
|
|
1846
|
-
- Warning 'Service should not have more then one draft root artifact'
|
|
1847
|
-
|
|
1848
|
-
- Experimental annotation '@cds.odata.{v2|v4}.ignore`
|
|
1849
|
-
|
|
1850
|
-
- OData vocabulary `com.sap.vocabularies.odm.v1` (lowercase 'odm')
|
|
1851
|
-
|
|
1852
|
-
- `--beta-mode` from option `--odata-containment`.
|
|
1853
|
-
|
|
1854
|
-
## Version 1.24.1 - 2020-03-06
|
|
1855
|
-
|
|
1856
|
-
### Added
|
|
1857
|
-
|
|
1858
|
-
- Add new OData vocabulary `com.sap.vocabularies.odm.v1`
|
|
1859
|
-
|
|
1860
|
-
### Changed
|
|
1861
|
-
|
|
1862
|
-
- Expressions in mixin-definitions are now validated.
|
|
1863
|
-
- OData:
|
|
1864
|
-
+ Redirect inbound associations to entities with parameters to corresponding Parameter EntityType.
|
|
1865
|
-
+ Update vocabulary `UI`
|
|
1866
|
-
- Use semver for dependencies
|
|
1867
|
-
|
|
1868
|
-
### Fixed
|
|
1869
|
-
|
|
1870
|
-
- Resolve backlink mixin association usages uniformly in association to join translation.
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
## Version 1.24.0 - 2020-02-28
|
|
1874
|
-
|
|
1875
|
-
### Added
|
|
1876
|
-
|
|
1877
|
-
- If an entity `E` with localized elements has the annotation `@fiori.draft.enabled`,
|
|
1878
|
-
a new element `ID_texts` of type `cds.UUID` is added to `E_texts` as the _only key_ and
|
|
1879
|
-
the annotation `@odata.draft.enabled` will not be set to false for `E.texts`.
|
|
1880
|
-
- A comment of the form `/**…*/` at "annotation positions" is now considered a doc comment;
|
|
1881
|
-
its "cleaned-up" text is put into the CSN as value of the property `doc`.
|
|
1882
|
-
In the OData/EDMX, it appears as value for the annotation `@Core.Description`.
|
|
1883
|
-
|
|
1884
|
-
### Fixed
|
|
1885
|
-
|
|
1886
|
-
- HANA CDS: When casting a column to an enum type, don't render it as an enum
|
|
1887
|
-
- Ignore top-level CSN "annotations" like `@sql_mapping` in the CSN frontend.
|
|
1888
|
-
- OData: Key constraint checks for Draft enabled entities consider EDM exposed keys only.
|
|
1889
|
-
- Message level for draft key checks is raised to 'warning' again.
|
|
1890
|
-
- Action and function calls are checked for missing arguments.
|
|
1891
|
-
- All references are correctly transformed in flatten mode.
|
|
1892
404
|
|
|
1893
405
|
|
|
1894
406
|
## Older Versions
|