Skip to main content

An ER-based framework for declarative web programming*


We describe a framework to support the implementation of web-based systems intended to manipulate data stored in relational databases. Since the conceptual model of a relational database is often specified as an entity-relationship (ER) model, we propose to use the ER model to generate a complete implementation in the declarative programming language Curry. This implementation contains operations to create and manipulate entities of the data model, supports authentication, authorization, session handling, and the composition of individual operations to user processes. Furthermore, the implementation ensures the consistency of the database w.r.t. the data dependencies specified in the ER model, i.e., updates initiated by the user cannot lead to an inconsistent state of the database. In order to generate a high-level declarative implementation that can be easily adapted to individual customer requirements, the framework exploits previous works on declarative database programming and web user interface construction in Curry.

Hide All

This work was partially supported by the German Research Council (DFG) under grant Ha 2457/5-2.

Hide All
Antoy, S., Echahed, R. and Hanus, M. 2000. A needed narrowing strategy. Journal of the ACM 47, 4, 776822.
Antoy, S. and Hanus, M. 2010. Functional logic programming. Communications of the ACM 53, 4, 7485.
Brassel, B., Hanus, M. and Müller, M. 2008. High-level database programming in Curry. In Proc. of the Tenth International Symposium on Practical Aspects of Declarative Languages (PADL'08), Hudak, P. and Warren, D. S., Eds. LNCS, vol. 4902. Springer, Berlin, 316332.
Chen, P. P.-S. 1976. The entity-relationship model—toward a unified view of data. ACM Transactions on Database Systems 1, 1, 936.
Fischer, S. 2005. A functional logic database library. In Proc. of the ACM SIGPLAN 2005 Workshop on Curry and Functional Logic Programming (WCFLP 2005), Antony, S. and Hanus, M., Eds. ACM Press, New York, 5459.
Hanus, M. 1997. A unified computation model for functional and logic programming. In Proc. of the 24th ACM Symposium on Principles of Programming Languages (Paris). Jones, N. D., Ed. ACM Press, New York, 8093.
Hanus, M. 2001. High-level server side web scripting in Curry. In Proc. of the Third International Symposium on Practical Aspects of Declarative Languages (PADL'01). LNCS, Ramakrishnan, I. V., Ed. vol. 1990, Springer, Berlin, 7692.
Hanus, M. 2006. Type-oriented construction of web user interfaces. In Proc. of the 8th ACM SIGPLAN International Conference on Principles and Practice of Declarative Programming (PPDP'06), Maher, M., Ed. ACM Press, New York, 2738.
Hanus, M. 2007a. Multi-paradigm declarative languages. In Proc. of the International Conference on Logic Programming (ICLP 2007). LNCS, Dahl, V. and Niemelä, I., Eds. vol. 4670. Springer, Berlin, 4575.
Hanus, M. 2007b. Putting declarative programming into the web: Translating Curry to JavaScript. In Proc. of the 9th ACM SIGPLAN International Conference on Principles and Practice of Declarative Programming (PPDP'07), Podelski, A., Ed. ACM Press, New York, 155166.
Hanus, M., ed. 2012. Curry: An integrated functional logic language (vers. 0.8.3). URL:
Huseby, S. 2003. Innocent Code: A Security Wake-Up Call for Web Programmers. Wiley, West Sussex, England.
Krasner, G. and Pope, S. 1988. A cookbook for using the model-view-controller user interface in Smalltalk-80. Journal of Object-Oriented Programming 1, 3, 2649.
Meijer, E. and van Velzen, D. 2000. Haskell server pages: Functional programming and the battle for the middle tier. In Proc. of the ACM SIGPLAN Haskell Workshop. ACM Press, Montreal.
Peyton Jones, S., ed. 2003. Haskell 98 Language and Libraries—The Revised Report. Cambridge University Press, Cambridge, UK.
Plasmeijer, R. and Achten, P. 2006. iData for the world wide web - programming interconnected web forms. In Proc. of the 8th International Symposium on Functional and Logic Programming (FLOPS 2006). LNCS, Hagiya, M. and Wadler, P., Eds. vol. 3945. Springer, Berlin, 242258.
Wadler, P. 1997. How to declare an imperative. ACM Computing Surveys 29, 3, 240263.
Yuan, M., Orshalick, J. and Heute, T. 2009. Seam Framework: Experience the Evolution of Java EE, 2nd ed. Prentice Hall, Upper Saddle River, New Jersey.
Recommend this journal

Email your librarian or administrator to recommend adding this journal to your organisation's collection.

Theory and Practice of Logic Programming
  • ISSN: 1471-0684
  • EISSN: 1475-3081
  • URL: /core/journals/theory-and-practice-of-logic-programming
Please enter your name
Please enter a valid email address
Who would you like to send this to? *



Full text views

Total number of HTML views: 0
Total number of PDF views: 0 *
Loading metrics...

Abstract views

Total abstract views: 0 *
Loading metrics...

* Views captured on Cambridge Core between <date>. This data will be updated every 24 hours.

Usage data cannot currently be displayed