max() function operates improperly on multi-attribute relations
- Vorherrschende Sprache
- Haskell
- Sterne
- 952
- Forks
- 50
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
Example:
```
TutorialD (master): :showexpr employee{departmentid,salary,employeeid} group ({salary,employeeid} as dept):{maxsalary:=max(@dept)}
┌─────────────────────────┬────────────────────────────────────────────────────────────┬──────────────────────┐
│departmentid::IntAtomType│dept::relation {employeeid::IntAtomType,salary::IntAtomType}│maxsalary::IntAtomType│
├─────────────────────────┼────────────────────────────────────────────────────────────┼──────────────────────┤
│3 │┌───────────────────────┬───────────────────┐ │4 │
│ ││employeeid::IntAtomType│salary::IntAtomType│ │ │
│ │├───────────────────────┼───────────────────┤ │ │
│ ││4 │20000000 │ │ │
│ ││3 │200 │ │ │
│ │└───────────────────────┴───────────────────┘ │ │
│1 │┌───────────────────────┬───────────────────┐ │2 │
│ ││employeeid::IntAtomType│salary::IntAtomType│ │ │
│ │├───────────────────────┼───────────────────┤ │ │
│ ││2 │100 │ │ │
│ ││1 │1000000 │ │ │
│ │└───────────────────────┴───────────────────┘ │ │
└─────────────────────────┴────────────────────────────────────────────────────────────┴──────────────────────┘
```
Using max() here should likely be an error, but there should be a way to choose an attribute of the subrelation on which the function should operate. This needs more thought.
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Bewertung
Dieses Issue wurde noch nicht bewertet.