[Rhythmbox-devel] Question: How to query rhythmdb case insensitive?
- From: David Jelić <burgulgoth gmail com>
- To: rhythmbox-devel gnome org
- Subject: [Rhythmbox-devel] Question: How to query rhythmdb case insensitive?
- Date: Mon, 18 Apr 2011 01:12:18 +0200
Hello,
I am trying to write a small plugin in python for syncing multiple
Rhythmbox players via Last.FM and I would appreciate some help about
little problem.
What is a proper way of querying rhythmdb for case-insensitive artist
and title?
I've been doing it like this:
query = self.db.query_new()
self.db.query_append(query, (rhythmdb.QUERY_PROP_EQUALS,
rhythmdb.PROP_ARTIST, artist, rhythmdb.QUERY_PROP_EQUALS,
rhythmdb.PROP_TITLE, title))
query_model = self.db.query_model_new_empty()
self.db.do_full_query_parsed(query_model, query)
It works fine in cases when data from last.fm and my database have the
same case, but I need to retrieve results even if case don't mach.
Appreciate your help,
--
David Jelić
http://burgulgoth.buksna.net | Personal blog
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]