You want AppleScript? If so, then disregard this. If you can settle with AppleEvent, then read on. On Mac's, Mma supports AppleEvent for external program linking in addition to the standard MathLink. This is the usual dosc event that you find in HyperCard and others**. Usual Mma expressions can be sent out from external programs to Mma (frontend, not the kernel, i.e., signature of OMEG, not Math) for their evaluations in this dosc event. It's that simple! If your database program allows you to write AppleEvent code, then that should do it. I've written a small Lisp program using this technique, and if you are interested, it's available from DIGITOOL's user contribution site (ftp.digitool.com/...---you'll find out).
** In version 2.0, this was unorthodoxed class OMEG with id EvSt. In version 2.2, things got straightened out with class misc and id dosc. Now, you are using version 3.0... Well, you can figure out yourself!
PS. If you got gripes about AppleScript, I've got my own with MathLink library format. WRI was very unhelpful with this. You know, a guy by the name of Mark has recently posted a series of gripes to this group. After all, we all got gripes of one form or the other, don't we?