guile-sources
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Guile-PG 0.26 available


From: Thien-Thi Nguyen
Subject: Guile-PG 0.26 available
Date: Thu, 24 Feb 2005 17:15:59 +0100

release notes:

  scheme-side munging this time around and lots of it -- feels good
  after Too Much Elisp.  speaking of which, here's a bit of elisp i
  forgot to include in the docs for those interested in playing w/
  the gxrepl module (from w/in Emacs, of course):

  (defun gxrepl (dbname)
    "Connect interactively to database DBNAME using the gxrepl."
    (interactive "sConnect to database: ")
    (when (string= "" dbname)
      (setq dbname (user-login-name)))
    (switch-to-buffer
     (make-comint (concat "gxrepl " dbname)
                  "guile"
                  nil
                  "-c"
                  (format "%S %S"
                          '(use-modules (database postgres-gxrepl))
                          `(gxrepl ,dbname))))
    (setq truncate-lines t))

  unfortunately, i haven't yet gotten around to installing PostgreSQL
  7.4.x, so the newer libpq funcs mentioned by Greg Troxel in the
  guile-user thread are not yet wrapped for this release.  they will
  fall from obscurity sooner or later...

  thi

README excerpt:

  Guile-PG is a collection of modules for Guile allowing access to
  the PostgreSQL RDBMS from Scheme programs.
  
  The low-level module `(database postgres)' provides an almost
  one-to-one correspondence with the PostgreSQL "libpq" C library
  interface.  Other higher-level modules, typically named
  `(database postgres-FOO)', provide abstractions and convenience
  procedures.
  
  This is alpha code (pre 1.0 release).  It has bugs, and the
  interfaces may change from version to version.

NEWS excerpt:

  - 0.26 | 2005-02-24
  
    - Expiration date set for opaque string support
  
        With the introduction of module (database postgres-qcons),
        Guile-PG continues moving towards fully symbolic schema and SQL
        functions/operations mirroring, and away from requiring (and
        thus accepting) SQL expressions to be "pre-rendered" as strings
        in its higher-abstraction convenience procedures.  The low-level
        `pg-exec' still requires a string, of course; the trick is how
        to derive that string from other non-string components.
  
        More concretely: `compile-outspec', used by the `#:select'
        message in `pgtable-manager', presently accepts a string as the
        SQL expression to compute for a particular column.  This support
        WILL BE REMOVED after 2005-12-31; DO NOT rely on it.
  
        Following are some examples of how to migrate away from using
        strings as SQL expressions.  We focus on the EXPR in:
  
        (((pgtable-manager ...) #:select) EXPR ...)
  
        string: "*"
        symbol: #t
        result: SELECT * ...
  
        string: "a,b,c.d"
        symbol: (a b c.d)
        result: SELECT "a", "b", c.d ...
  
        string: "count(*),avg(*)"
        symbol: ((integer #f (count *)) (real "average" (avg *)))
        result: SELECT count(*), avg(*) AS "average" ...
  
        string: "(6 * 6 + 6) AS obvious"
        symbol: ((integer "obvious" (+ 6 (* 6 6))))
        result: SELECT (6 + (6 * 6)) AS "obvious" ...
  
        string: ((integer #f "6 * 6 + 6"))
        symbol: ((integer #f (+ 6 (* 6 6))))
        result: SELECT (6 + (6 * 6)) ...
  
        Note that for the most part the result is the same as you would
        achieve using a string (if not, that's a bug, please report it!).
  
    - Expiration date set for two (database postegres-table) procs
  
        The procs `tuples-result->table' and `where-clausifier'
        WILL BE REMOVED after 2005-08-13; DO NOT rely on them.
  
    - Dropped (database postgres-types) proc: dbcoltype:name
  
        This proc takes a column-type object returned from calling
        `dbcoltype-lookup', which takes the type name.  Thus, it is
        redundant.  Removing it increases encapsulation.
  
    - New type converters in module (database postgres-types)
  
        These are the new built-in type converters:
  
        bigint int2 int8 double float8 bigserial serial4 serial8
        inet cidr macaddr inet-host
  
        Additionally, the manual now has a section on the type
        converters in chapter "Types Conversion".
  
    - New module: (database postgres-qcons)
    - New module: (database postgres-resdisp)
    - New module: (database postgres-gxrepl)

cvs tag:

  v-0-26

tarball, anoncvs instructions, and other files in dir:

  http://www.glug.org/people/ttn/software/guile-pg/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]