[mythtv] Correct way to write out to the settings table?

Drew Whittle drew at lug.net.nz
Sat Feb 22 02:23:04 EST 2003


I'm having a go at adding some bits and pieces to Myth, but I haven't
been able to figure out the correct way to write a changed setting out
to the DB.

Currently I am doing:

 thequery = QString("UPDATE settings SET data = \"%1\" WHERE value = "
        "\"Theme\";").arg(themename);
    db->exec(thequery);

This works, but it's not correct (ie it updates all clients to that
theme), now I could go and get the right host name etc and add that into
the where clause, but I figure there must be something I can call that
will take care of all of this for me.

Disclaimer:
I don't know the internals of Myth very well
I can hardly program in C
I'm even worse at C++ 
(and thats without adding Qt into the equation)

Can anyone point me in the right direction? (and no I'm not doing this
from within any of the setup parts of Myth)

:D
-- 
Drew Whittle <drew at lug.net.nz>



More information about the mythtv-dev mailing list