FAQ
i'm using "code.google.com/p/go-sqlite/go1/sqlite3" package for the call
back function to get called, should the update or delete operations be
executed from connection itself in golang or can they be executed from
sqlite3 terminal so that i can keep program waiting for function to be
called. callback function means i meant the UpdateFunc(). it is getting
called fine when i used conn.execute(update stmt) on db. but when i went to
terminal and executed the same update statement on db table it is not
getting called. i'm keeping the connection open and making the program wait
using waitgroup.

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

  • Maxim Khitrov at Mar 3, 2015 at 12:53 pm

    On Tue, Mar 3, 2015 at 12:58 AM, Adusumilli SeshaChandra wrote:
    i'm using "code.google.com/p/go-sqlite/go1/sqlite3" package for the call
    back function to get called, should the update or delete operations be
    executed from connection itself in golang or can they be executed from
    sqlite3 terminal so that i can keep program waiting for function to be
    called. callback function means i meant the UpdateFunc(). it is getting
    called fine when i used conn.execute(update stmt) on db. but when i went to
    terminal and executed the same update statement on db table it is not
    getting called. i'm keeping the connection open and making the program wait
    using waitgroup.
    The sqlite callback functions are not going to be called across
    different connections. Also, you should be using the github version of
    my package, though I have no idea if it still works with the current
    cgo/GC combination. I know that it crashes with a more recent version
    of sqlite amalgamation, but I haven't had the time to figure out why.

    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Adusumilli SeshaChandra at Mar 3, 2015 at 12:59 pm
    is there any method for golang to get notified if a change occours in
    sqlite db??
    On Tuesday, March 3, 2015 at 6:23:57 PM UTC+5:30, Maxim Khitrov wrote:

    On Tue, Mar 3, 2015 at 12:58 AM, Adusumilli SeshaChandra
    <adusumilli....@vembu.com <javascript:>> wrote:
    i'm using "code.google.com/p/go-sqlite/go1/sqlite3" package for the call
    back function to get called, should the update or delete operations be
    executed from connection itself in golang or can they be executed from
    sqlite3 terminal so that i can keep program waiting for function to be
    called. callback function means i meant the UpdateFunc(). it is getting
    called fine when i used conn.execute(update stmt) on db. but when i went to
    terminal and executed the same update statement on db table it is not
    getting called. i'm keeping the connection open and making the program wait
    using waitgroup.
    The sqlite callback functions are not going to be called across
    different connections. Also, you should be using the github version of
    my package, though I have no idea if it still works with the current
    cgo/GC combination. I know that it crashes with a more recent version
    of sqlite amalgamation, but I haven't had the time to figure out why.
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Maxim Khitrov at Mar 3, 2015 at 1:07 pm
    Look into the fsnotify package and just monitor the database file for
    changes. You will not know what the change is and you may get a lot of
    false positives just for lock/unlock operations.

    On Tue, Mar 3, 2015 at 7:59 AM, Adusumilli SeshaChandra
    wrote:
    is there any method for golang to get notified if a change occours in sqlite
    db??
    On Tuesday, March 3, 2015 at 6:23:57 PM UTC+5:30, Maxim Khitrov wrote:

    On Tue, Mar 3, 2015 at 12:58 AM, Adusumilli SeshaChandra
    wrote:
    i'm using "code.google.com/p/go-sqlite/go1/sqlite3" package for the call
    back function to get called, should the update or delete operations be
    executed from connection itself in golang or can they be executed from
    sqlite3 terminal so that i can keep program waiting for function to be
    called. callback function means i meant the UpdateFunc(). it is getting
    called fine when i used conn.execute(update stmt) on db. but when i went
    to
    terminal and executed the same update statement on db table it is not
    getting called. i'm keeping the connection open and making the program
    wait
    using waitgroup.
    The sqlite callback functions are not going to be called across
    different connections. Also, you should be using the github version of
    my package, though I have no idea if it still works with the current
    cgo/GC combination. I know that it crashes with a more recent version
    of sqlite amalgamation, but I haven't had the time to figure out why.
    --
    You received this message because you are subscribed to the Google Groups
    "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an
    email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-nuts @
categoriesgo
postedMar 3, '15 at 5:58a
activeMar 3, '15 at 1:07p
posts4
users2
websitegolang.org

People

Translate

site design / logo © 2021 Grokbase