Last modified: 2008-02-05 11:02:36 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T14754, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 12754 - Querying for N-Ary property with a type Text fails
Querying for N-Ary property with a type Text fails
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
Semantic MediaWiki (Other open bugs)
unspecified
All All
: Normal major (vote)
: ---
Assigned To: Nobody - You can work on this!
http://ontoworld.org/wiki/NaryQueryTest
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-01-23 10:47 UTC by Markus Nitsche
Modified: 2008-02-05 11:02 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Markus Nitsche 2008-01-23 10:47:56 UTC
SMW1.0 on MW1.12alpha

Steps to reproduce:
1. Create an n-ary attribute that uses type:text (http://ontoworld.org/wiki/Property:TestNary)

Type:String, Number, Text

2. Make some annotations of this property (http://ontoworld.org/wiki/NaryTest)

[[TestNary:=Hello world;42;Some more text]]

3. Create a query asking for an exact text value, for example:

<ask>[[TestNary:=?;?;Some more text]][[TestNary:=*]]</ask> (http://ontoworld.org/wiki/NaryQueryTest)


Result:

A SQL error appears, stating:


A database query syntax error has occurred. This may indicate a bug in the software. The last attempted database query was:

    (SQL query hidden)

from within function "SMW::getQueryResult". MySQL returned error "1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')) ORDER BY `page`.page_title ASC LIMIT 51' at line 1 (localhost)".


Expected Result:
The query should deliver all pages with "Some more text" annotated in third position of this property.
Comment 1 Markus Krötzsch 2008-02-05 11:02:36 UTC
This requires some clarification:

* The fact that SMW throws SQL errors (in any situation whatsoever) is a bug.

* The fact that you cannot search for exact values of Type:Text is not a bug, but part of the design. Type:Text data is not used in query matching for performance reasons and because it is not expected that any user would search for exact matches of long texts in general. Moreover, Type:Text values do not even have a DB index, for reasons of space.

The *bug* has now been fixed in SVN. The other request remains a "wontfix" -- use Type:String for  value matching.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links