caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: "Quinn, Chris" <chris.quinn@eds.com>
To: <caml-list@inria.fr>
Subject: RE: [Caml-list] Type-safe interface to Postgres's SQL
Date: Tue, 31 Jan 2006 16:43:01 -0000	[thread overview]
Message-ID: <4DB758040F42334883C0350EB806CA73A598AB@ukspm207.emea.corp.eds.com> (raw)

A few years ago I implemented a type safe interface to db2 (odbc
compliant).
My approach was to extend the caml compiler with a Type.typeof : 'a ->
typeinfo function
which marshalled the internal type info into a string.
This is then used at runtime to compare with the database's notion of
what a query produces
(the check is performed only once during the execution life of the
program, thereby minimising cost)
So any mismatch with the db schema is caught (as long as that bit of the
code is actually run!)

/C


             reply	other threads:[~2006-01-31 16:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-31 16:43 Quinn, Chris [this message]
2006-01-31 17:51 ` brogoff
  -- strict thread matches above, loose matches on Subject: below --
2006-01-31 14:07 Richard Jones
2006-02-18 16:01 ` [Caml-list] " Richard Jones

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4DB758040F42334883C0350EB806CA73A598AB@ukspm207.emea.corp.eds.com \
    --to=chris.quinn@eds.com \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).