Conversation
danjoa
reviewed
Aug 12, 2025
| @@ -0,0 +1,7 @@ | |||
| { | |||
| @@ -0,0 +1,98 @@ | |||
| { | |||
index.cds
Outdated
| using from './srv/workarounds'; | ||
|
|
||
| // simulate cds export | ||
| annotate sap.capire.flights.data with @cds.external; |
srv/data-products.cds
Outdated
| key date, // preserve the flight date as a key | ||
| *, // include all other fields from my.Flights | ||
| } excluding { flight }; | ||
| } excluding { flight, date, free_seats }; |
Member
There was a problem hiding this comment.
- Why excluding
date? → it's akeybtw → does that work at all? - Why excluding
free_seats?
Contributor
Author
There was a problem hiding this comment.
I added this as the compiler was giving the following message. It was mostly added as a reminder.
Info[wildcard-excluding-one…]: This select item replaces “date” from table alias “Flights”. Add “date” to ‘excluding’ to silence this message
|
srv/data-products.cds:9:9-13, at entity:“sap.capire.flights.data.Flights”/query:1
|
9 | key date, // preserve the flight date as a key
| ^^^^
Info[wildcard-excluding-one…]: This select item replaces “free_seats” from table alias “Flights”. Add “free_seats” to ‘excluding’ to silence this message
|
srv/workarounds.cds:5:37-47, at entity:“sap.capire.flights.data.Flights”/query:1
|
5 | maximum_seats - occupied_seats as free_seats : Integer,
| ^^^^^^^^^^
Member
There was a problem hiding this comment.
Ok, thanks for the background @BobdenOs
@stewsk : I'd recommend removing these info messages or just don't display info-level messages by default (as we do in cds compile). Reason (as frequently reiterated): such messages cause wrong reactions (see here, q.e.d.) or leads to broken window effects → devs not paying attention to compiler messages anymore at all (as in Nexus).
danjoa
reviewed
Aug 12, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.