An interface to the Kdb+ database is available at the Kx wiki (authorization required). In that wiki, look for cookbooks|kdb+ foreign language interfacing|Integrating with J.