[mythtv-users] python bindings

Jeremy Jones jeremy.dwain.jones at gmail.com
Thu Jan 23 14:10:35 UTC 2014


On Wed, Jan 22, 2014 at 10:51 PM, Raymond Wagner <raymond at wagnerrp.com>wrote:

>
>  4) And this is really what I need: Is there a place that I can look that
>> will tell me about accessing the following database tables using the
>> python bindings?
>>    a) music_playlists
>>    b) music_songs
>>    c) music_directories
>>
>
> The relevant pages list objects for those, but it seems I never filled
> them in.
>
> http://www.mythtv.org/wiki/0.26_Python_bindings/Data_
> Handlers#MusicPlaylist
>
> Also see...
>
> http://code.mythtv.org/cgit/mythtv/tree/mythtv/bindings/
> python/MythTV/dataheap.py#n1229
>
> In any case, they follow the same behavior of all other database-derived
> objects.  They can be accessed by the class constructor by using the
> table's primary keys, and all columns are accessible as attributes.  You
> can alter the attributes and run .update() to push the changes, or you can
> feed those changes into .update({}) with a dict argument.  You can create a
> new, empty object, populate it, and then push it with .create().  You can
> delete an existing object with .delete().
>
>
That's exactly what I needed.  Thank you Raymond.

Jeremy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mythtv.org/pipermail/mythtv-users/attachments/20140123/7459b31c/attachment.html>


More information about the mythtv-users mailing list