Sciweavers

JCSS
2002

Polymorphic Type Inference for the Relational Algebra

14 years 7 days ago
Polymorphic Type Inference for the Relational Algebra
A database programming language is a programming language extended with database operations. In this paper we extend a core functional language with explicitly labeled tuples and the operations of the relational algebra. We present the functional database programming language Neon along with a polymorphic type inference algorithm that can infer a `type formula', that is, a type together with type constraints, for any valid Neon program. Neon has the following salient features: (1) let-bound polymorphism, (2) explicitly labeled tuples, (3) polymorphic tuple operations, notably extension, (4) sets and set operations, and (5) polymorphic relational algebra operations, notably natural join. To type-check a Neon program the standard Damas-Milner type inference algorithm needs to be extended so that it collects constraints on type variables imposed by tuple and relational operations. The type inference algorithm has been successfully implemented in Haskell.
Jan Van den Bussche, Emmanuel Waller
Added 22 Dec 2010
Updated 22 Dec 2010
Type Journal
Year 2002
Where JCSS
Authors Jan Van den Bussche, Emmanuel Waller
Comments (0)