unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* #<guile-dbi> undefined symbol
@ 2013-04-30  9:29 Dmitry Bogatov
  2013-05-01 11:26 ` Mark H Weaver
  0 siblings, 1 reply; 2+ messages in thread
From: Dmitry Bogatov @ 2013-04-30  9:29 UTC (permalink / raw)
  To: guile-user

[-- Attachment #1: Type: text/plain, Size: 538 bytes --]


Hello! The following, slightly modified example from  from guile-dbi
manual returns error:
	#<guile-dbi close sqlite3 my-example-db (1 . /usr/lib/libguile-dbi.so.2: undefined symbol: __sqlite3_query_g_db_handle)>
	#<guile-dbi close sqlite3 my-example-db (1 . /usr/lib/libguile-dbi.so.2: undefined symbol: __sqlite3_query_g_db_handle)>

and do not create database file.
    guile (GNU Guile) 2.0.9
    guile-dbi 2.1.5

Also, probably a bit offtopic, but what was reason to reimplement it all
in Guile and not write bindings to C libdbi?


[-- Attachment #2: Example --]
[-- Type: text/plain, Size: 535 bytes --]

#!/usr/bin/guile -s
!#
;(use-modules (im irc))
(use-modules (dbi dbi))

(define +channel-init-query+
"CREATE TABLE channel (
    chanid int unsigned auto_increment,
    topic text);")

(define (initialize-database-tables db-obj)
  (or (and (dbi-query db-obj +channel-init-query+))
      (error "Failed to initialize database table")))



(define db-obj (dbi-open "sqlite3" "my-example-db"))
(dbi-query db-obj "create table hellotable(id int, name varchar(15))")
(display db-obj) (newline)
(dbi-close db-obj)
(display db-obj) (newline)

[-- Attachment #3: Type: text/plain, Size: 275 bytes --]


--
Best regards, Dmitry Bogatov <KAction@gnu.org>,
Free Software supporter and netiquette guardian.
	git clone git://gitorious.org/illusionoflife-read-only/rc-files.git --depth 1
        GPG: 54B7F00D
Html mail and proprietary format attachments are forwarded to /dev/null.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: #<guile-dbi> undefined symbol
  2013-04-30  9:29 #<guile-dbi> undefined symbol Dmitry Bogatov
@ 2013-05-01 11:26 ` Mark H Weaver
  0 siblings, 0 replies; 2+ messages in thread
From: Mark H Weaver @ 2013-05-01 11:26 UTC (permalink / raw)
  To: Dmitry Bogatov; +Cc: guile-user

Dmitry Bogatov <KAction@gnu.org> writes:

> Hello! The following, slightly modified example from  from guile-dbi
> manual returns error:
> 	#<guile-dbi close sqlite3 my-example-db (1 . /usr/lib/libguile-dbi.so.2: undefined symbol: __sqlite3_query_g_db_handle)>
> 	#<guile-dbi close sqlite3 my-example-db (1 . /usr/lib/libguile-dbi.so.2: undefined symbol: __sqlite3_query_g_db_handle)>
>
> and do not create database file.
>     guile (GNU Guile) 2.0.9
>     guile-dbi 2.1.5

The problem is that you haven't installed 'guile-dbd-sqlite3'.
It is available at http://download.gna.org/guile-dbi/

    Regards,
      Mark



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-05-01 11:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-30  9:29 #<guile-dbi> undefined symbol Dmitry Bogatov
2013-05-01 11:26 ` Mark H Weaver

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 read-only IMAP folder(s) and NNTP newsgroup(s).