Azure / Azure/data-api-builder
[Enh]: introduce `dab update <stored-proc> --parameter <param-name> --<property-name> <property-value>`
- Lingua principale
- C#
- Stelle
- 1.5k
- Fork
- 370
- Merge medio
- 3g 17h
- PR unite (30g)
- 8
Descrizione
## What?
Introduce:
```
dab update \
--parameter \
--
```
This allows updating a single stored procedure parameter without redefining all parameters.
## Why?
Today, modifying a single parameter requires redefining every parameter.
Also, this is
### Example of the problem
To change just one default value, you must restate all parameters:
```
dab update UpdateCustomerPreferences \
--parameters.name "CustomerID,EmailNotifications,SMSNotifications,PreferredCurrency,MarketingOptIn" \
--parameters.description "Customer ID to update,Enable email notifications for orders and promotions,Enable SMS notifications for shipping updates,Preferred billing currency (ISO 4217 code),Opt in to marketing communications" \
--parameters.required "true,false,false,false,false" \
--parameters.default ",true,false,EUR,false"
```
Even though only `PreferredCurrency` changed.
### Example of the solution
Update only the intended parameter:
```
dab update UpdateCustomerPreferences \
--parameter PreferredCurrency \
--default=EUR
```
Update description:
```
dab update FindProducts \
--parameter SearchText \
--description "This is the new description value."
```
## How?
* Keep supporting the existing bulk parameter syntax.
* Introduce targeted parameter mutation syntax.
* Update documentation to recommend the new approach.
* Leave legacy syntax for full parameter redefinition scenarios.
### Output
* When legacy syntax is used, output/log the new syntax preference.
```
Using legacy parameter syntax.
Consider using targeted syntax:
dab add \
--parameter \
--property-name
dab update \
--parameter \
--property-name
```
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia tracciando il comando esistente `dab update` e la relativa sintassi dei parametri in blocco, quindi esamina i test CLI e la documentazione correlati. La modifica è completata quando gli aggiornamenti mirati possono modificare una proprietà di un parametro di una stored procedure, la ridefinizione in blocco legacy continua a funzionare con l’output della sintassi suggerita e gli esempi documentati raccomandano la nuova forma.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- csharp
- Ambito
- cli, databases
- Tipo di issue
- Funzionalità
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 48/100