Support for `HEAD`, `WORKING` and `STAGED` in fully-qualified views
- Dominant language
- Go
- Stars
- 24.4k
- Forks
- 873
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 120
Description
Today, if I have a view like this...
```sql
create view v_diff_stat as
select * from dolt_diff_stat('main', 'WORKING');
```
...and select from the view using a fully-qualified name...
```sql
select * from `mysql/my-branch`.`v_diff_stat`;
```
...it will always ignore the branch name and use the checked-out branch instead. I think a fully-qualified name should have precedence, feels more intuitive, but I might be wrong. It would at least be pretty cool if the above worked.
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the SQL examples with a view calling dolt_diff_stat('main', 'WORKING') and a fully-qualified view name such as `mysql/my-branch`.`v_diff_stat`. Start by tracing view resolution and handling of HEAD, WORKING, and STAGED references; done means the qualified branch takes precedence and the view returns results for that branch.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, sql
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100