View Single Post
Old 09-16-2011, 06:34 AM   #15
drMerry
Addict
drMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmosdrMerry has become one with the cosmos
 
drMerry's Avatar
 
Posts: 293
Karma: 21022
Join Date: Mar 2011
Location: NL
Device: Sony PRS-650
authors:#=<n>

That's what I was looking for for A and B.
I knew calibre had advanced options I could not remember

But Kovid's last reaction is true for C.

I have made some other queries to find some more info.

Does one of you know how to put this in a plugin?

I did make these queries:
# of books per tag (already available in browser)
# of tags per book (the mentioned search will show this)
# tags per author.
Not available yet (as far as I know)

The sql I use is:

Code:
SELECT authors.name, COUNT(DISTINCT books_tags_link.tag) AS NumberOfTags
FROM books_tags_link INNER JOIN books_authors_link
ON books_tags_link.book = books_authors_link.book JOIN authors
ON authors.id = books_authors_link.author
GROUP BY authors.name
ORDER BY NumberOfTags
How can I put this in a plugin?
drMerry is offline   Reply With Quote