[firebase-br] Firebird - Estrutura de tabelas

Márcio Schmeling schmeda em gmail.com
Ter Jul 2 17:27:14 -03 2019


*ALTER COLUMN: SET DEFAULT*



*Available in: DSQL*

*Added in: 2.0*
*Description:* Firebird 2 adds the possibility to set/alter defaults on
existing columns. If the column already had
a default, the new default will replace it. Column-level defaults always
override domain-level defaults.

*Syntax:*

ALTER TABLE tablename ALTER [COLUMN] colname SET DEFAULT <default>
> <default> ::= literal-value | context-variable | NULL


*Example:*

alter table Customers alter EnteredBy set default current_user


Márcio Schmeling
schmeda em gmail.com


Em ter, 2 de jul de 2019 às 17:10, UPSAI | Informatica <
informatica em upsai.com.br> escreveu:

> Prezados
>
> Como posso fazer uma alteração em uma tabela existem, para que quando um
> novo registro for incluído, um de seus campos existentes seja inicializado
> com um valor default?
>
> Saudações
>
> Wagner Aranha
>
>
> ______________________________________________
> FireBase-BR (www.firebase.com.br) - Hospedado em www.locador.com.br
> Para saber como gerenciar/excluir seu cadastro na lista, use:
> http://www.firebase.com.br/fb/artigo.php?id=1107
> Para consultar mensagens antigas:
> http://www.firebase.com.br/pesquisa_lista.html
>



Mais detalhes sobre a lista de discussão lista