Re: [GENERAL] Imperative Query Languages

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [GENERAL] Imperative Query Languages
Дата
Msg-id 1437.1499234500@sss.pgh.pa.us
обсуждение исходный текст
Ответ на [GENERAL] Imperative Query Languages  (Jason Dusek <jason.dusek@gmail.com>)
Ответы Re: [GENERAL] Imperative Query Languages  (Jason Dusek <jason.dusek@gmail.com>)
Список pgsql-general
Jason Dusek <jason.dusek@gmail.com> writes:
> This more of a general interest than specifically Postgres question. Are
> there any “semi-imperative” query languages that have been tried in the
> past? I’m imagining a language where something like this:

> for employee in employees:
>     for department in department:
>         if employee.department == department.department and
>            department.name == "infosec":
>             yield employee.employee, employee.name, employee.location,
> employee.favorite_drink

I'm pretty sure that that is the model that relational databases (and the
SQL language in particular) replaced, back in the 70s or so.  Look up
"network" databases (eg CODASYL) and "hierarchical" DBs (eg IMS) for some
ancient history here.  Yeah, you can do it like that, but it's seriously
painful to develop and maintain.  People were more excited about spending
human effort to save machine cycles forty years ago than they are today.

            regards, tom lane


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

Предыдущее
От: John Turner
Дата:
Сообщение: Re: [GENERAL] Imperative Query Languages
Следующее
От: Chris Travers
Дата:
Сообщение: Re: [GENERAL] Imperative Query Languages