Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
Nice to hear you (not me) solved the problem. You're welcome Andrea On 3 Jan 2014 21:19, "PeterKerk" wrote: > No need, you solved it! > It was the id name, it had to be uppercase. > > btw the ; is still there in the query, but everything still works. > > Thanks! > > > > -- > View this message in

Re: Empty facets on Solr with MySQL

2014-01-03 Thread PeterKerk
No need, you solved it! It was the id name, it had to be uppercase. btw the ; is still there in the query, but everything still works. Thanks! -- View this message in context: http://lucene.472066.n3.nabble.com/Empty-facets-on-Solr-with-MySQL-tp4109170p4109425.html Sent from the Solr - User m

Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
I don't remember your dih-config.xml (could you post it again?) - remove the trailing ; from the query. It is a valid delimiter only when you run queries in mysql worlbench; - I assume there's a parent entity named (name=) article. - are you sure the column of the article entity is "id" (NB this

Re: Empty facets on Solr with MySQL

2014-01-03 Thread PeterKerk
Hi Andrea, I think you helped me to get closer, but not quite there yet. When I replace wtr.object_id='${article.id}'; with wtr.object_id=18 the cat_name field holds a value, which I checked via the schema browser of Solr dashboard! I then checked my main query SELECT p.*, ( SELECT guid FROM wp

Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
Or, in other words, assuming that the example you reported (article.id=18) returns a record with cat_name, could you hardcode that id in your dih-config (replacing ${article.id} with 18) and try to run a full-import? Another important thing: in your example you are using the object_id as an int (o

Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
Yes, that definitely matters...I was talking about a simple java class. Peter, sincerely? I don't know. Are you sure you are doing then same queries with the same article.id as solr does? and sorry for the stupid question but are you sure that for those article ids the cat_name is not null? On 3

Re: Empty facets on Solr with MySQL

2014-01-03 Thread PeterKerk
But when I execute the query directly on MySQL I do get a cat_name column in there: select wt.name as cat_name,wt.slug,wtr.term_taxonomy_id,wtt.term_id,wtt.taxonomy from wp_term_relationships wtr INNER JOIN wp_term_taxonomy wtt ON wtt.term_taxonomy_id=wtr.term_taxonomy_id AND wtt.taxonomy='catego

Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
Hi Peter, I can only guess that the result set doesn't contain a "cat_name" (case insensitive) column. Other option / question: do you have a transformer (like scriptTransformer) that manipulates the resultset? You can debug the resultset in a main class by doing rs.getString ("cat_name") Cheers,

Re: Empty facets on Solr with MySQL

2014-01-03 Thread PeterKerk
Hi Andrea, Here you go: **data-config.xml** **schema.xml**

Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
Hi Peter, Umfprtunately I deleted your first email where you wrote a piece of your schema...the problem seems to be "cat_name" and not cat_name_raw...could you please post again your schema? On 3 Jan 2014 13:40, "PeterKerk" wrote: > Hi Andrea, > > You were right, I do see errors when setting the

Re: Empty facets on Solr with MySQL

2014-01-03 Thread PeterKerk
Hi Andrea, You were right, I do see errors when setting the required=true attribute...what can it be? Logging console homepage: 13:31:54 WARN SolrWriter Error creating document : SolrInputDocument[comment_status=open,​ post_content=algemeen kpn artikeltje ook over vodafone,​ guid=http://www.tel

Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
Hi Peter Sorry I didn't see your question about the log level. I'm here with my mobile so cannot guide you step by step (don't remember exactly) but is very very easy. Prior to solr 4 there was a "logging" hyperlink on the homepage of the console. Starting from 4 you should see the same link on the

Re: Empty facets on Solr with MySQL

2014-01-03 Thread Andrea Gazzarini
Sorry I didn't get the point...so that means - if you put the required clause you must have some kind of errors (because no documets are imported) - your query doesn't throw out that field I'm quite sure that if you put again the required attribute and set to finest the log level you must see

Re: Empty facets on Solr with MySQL

2014-01-03 Thread PeterKerk
Hi Andrea, I would say the JDBC driver must be working because when I leave out the required="true" from the cat_name field, 4 documents are imported. Since my entire DB currently holds only 4 records, there's no need for a LIMIT clause I guess? Andrea Gazzarini-4 wrote > In the solr console se

Re: Empty facets on Solr with MySQL

2014-01-02 Thread Andrea Gazzarini
Hi Peter, Hi Andrea, I changed it to: When I run full-import 0 documents are indexed, but no errors in the console. That's the reason why you can't see facets and errors: 0 documents are indexed When I run my query via MySQL Workbench the statement executes correctly. Once I spent a who

Re: Empty facets on Solr with MySQL

2014-01-02 Thread PeterKerk
Hi Andrea, I changed it to: When I run full-import 0 documents are indexed, but no errors in the console. When I run my query via MySQL Workbench the statement executes correctly. How else can I debug the index process? -- View this message in context: http://lucene.472066.n3.nabble.co

Re: Empty facets on Solr with MySQL

2014-01-02 Thread Andrea Gazzarini
Then that means dih is not populating the field.. I guess if you set required=true in your field you will get some error during indexing Try to debug the index process and /or run queries outside solr in order to see results, field names matches and so on Best, Andrea I get "Sorry, no Term Info

Re: Empty facets on Solr with MySQL

2014-01-02 Thread PeterKerk
I get "Sorry, no Term Info available :(" -- View this message in context: http://lucene.472066.n3.nabble.com/Empty-facets-on-Solr-with-MySQL-tp4109170p4109186.html Sent from the Solr - User mailing list archive at Nabble.com.

Re: Empty facets on Solr with MySQL

2014-01-02 Thread Ahmet Arslan
Hi Peter, Go to your solr admin page and select your core. Hit the schema-browser URL and select cat_name_raw field. Example URL :  http://localhost:8983/solr/#/crawl/schema-browser Push the 'Load Term info' button, do you see some data there? ahmet On Thursday, January 2, 2014 9:23 PM, PeterK

Re: Empty facets on Solr with MySQL

2014-01-02 Thread PeterKerk
Hi Ahmet, I tried this URL: http://localhost:8983/solr/wordpress/select/?indent=on&facet=true&sort=post_modified%20desc&q=*:*&start=0&rows=10&fl=id,post_title,cat_name*&facet.field=cat_name_raw&facet.mincount=1 and this URL: http://localhost:8983/solr/wordpress/select/?indent=on&facet=true&sort

Re: Empty facets on Solr with MySQL

2014-01-02 Thread Ahmet Arslan
Hi Peter, I think you meant faceting on cat_name_raw field. facet=true&facet.field=cat_name_raw Second check if that field is actually popupated. Below URL or at Schema Browser link. q=*:*&fl=cat_name*  Ahmet On Thursday, January 2, 2014 8:45 PM, PeterKerk wrote: I've set up Solr with MySQL.