Resolve the alias or compute a default name for a WITH/RETURN item */
| 4560 | |
| 4561 | /* Resolve the alias or compute a default name for a WITH/RETURN item */ |
| 4562 | static const char *resolve_item_alias(const cbm_return_item_t *item, char *name_buf, |
| 4563 | size_t buf_sz) { |
| 4564 | if (item->alias) { |
| 4565 | return item->alias; |
| 4566 | } |
| 4567 | if (item->property) { |
| 4568 | snprintf(name_buf, buf_sz, "%s.%s", item->variable, item->property); |
| 4569 | } else { |
| 4570 | snprintf(name_buf, buf_sz, "%s", item->variable); |
| 4571 | } |
| 4572 | return name_buf; |
| 4573 | } |
| 4574 | |
| 4575 | /* ── WITH clause: project bindings through aggregation or rename ── */ |
| 4576 |
no outgoing calls
no test coverage detected