Re: Input validation

Поиск
Список
Период
Сортировка
От Rob Sargent
Тема Re: Input validation
Дата
Msg-id f6250b9c-56ba-fb72-0fe9-33a145c91421@gmail.com
обсуждение исходный текст
Ответ на Input validation  (stan <stanb@panix.com>)
Ответы Re: Input validation  (Benedict Holland <benedict.m.holland@gmail.com>)
Список pgsql-general
On 8/7/19 12:07 PM, stan wrote:
>   Have table that contains employee keys, paired up with work type keys
>   (both foreign keys) and a 3rd column that you enter a billing rate in.
>   Then I have a table where employees enter their work. I need to validate
>   that the employee, work type pair exists, before allowing the new record
>   to be inserted.
>
>   Any thoughts as to good way to do this?
>
>
Does the employee interactively specify the "work type" then some 
time-spent value?

Can the work-type be chosen from a drop-down generated by

     select work_type from table where employee = <current user>

Otherwise you'll need a trigger on the insert into "enter their work" 
table.  Sad thing here is the user has likely left the scene.




В списке pgsql-general по дате отправления:

Предыдущее
От: Adrian Klaver
Дата:
Сообщение: Re: Input validation
Следующее
От: Bryn Llewellyn
Дата:
Сообщение: Re: Why must AUTOCOMMIT be ON to do txn control in plpgsql procedure?