Changes between Version 5 and Version 6 of query_builder_doc


Ignore:
Timestamp:
Feb 3, 2016, 6:14:57 PM (8 years ago)
Author:
casties
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • query_builder_doc

    v5 v6  
    1 
    2 == Query Builder tool ==
     1= Query Builder tool =
    32
    43You can find the Query Builder tool online at
     
    65https://ismi-dev.mpiwg-berlin.mpg.de/static-ismi/ng2-query-builder/index.html
    76
    8 == Example query ==
     7= Example query =
    98
    109In this simple example we will find all witnesses of titles by Nasir al-Din al-Tusi.
    1110
    12 === Start ===
     11== Start ==
    1312
    1413The tool starts with an option to select the first query step:
     
    2019 * "**object ID is**" to select one object with a certain ISMI_ID e.g. 47316 for Tusi
    2120
    22 === Show all persons ===
     21== Show all persons ==
    2322
    2423If we select "**object type is**" in the first select box we get a second select box with all the possible object types like ALIAS, CODEX, COLLECTION and more.
     
    3231Because this are a lot of objects the system will not show all of the objects automatically. If you really want to see all 2217 objects you can click on the "**show results**" button but your browser may crash or take a while to display so many objects in a table.
    3332
    34 === Select persons by name ===
     33== Select persons by name ==
    3534
    3635Now we want to narrow down the list of persons to only those that have "tusi" in their name.
     
    6059In the table we find the row containing Abū Jaʿfar Naṣīr al-Dīn Muḥammad ibn Muḥammad ibn al-Ḥasan al-Ṭūsī and we note that the corresponding ismi_id is 47316.
    6160
    62 === Select objects by ID ===
     61== Select objects by ID ==
    6362
    6463Now we click "**add step**" again to add another step to select only Nasir al-Din al-Tusi to find only his works.
     
    6968
    7069[[Image(qb-person-tusi-id.png)]]
     70
     71Under "Query result" we see that now only 1 PERSON object is selected.
     72
     73== Select texts written by a person ==
     74
     75Now we click "**add step**" again to add another step to select all texts written by Tusi.
     76
     77In the first select box we select "**Relation type is**".
     78
     79In the second select box we get a list of all relations of the Tusi object in the database like "is_alias_name_of" or "was_born_in".
     80
     81You will note that all relation types show up in the list a second time prefixed with "<-". These are the reverse relations. These are needed because the relations are directed and you have to select the direction of the relation.
     82
     83The "normal" relation is read from the last selected object, in this case a PERSON to the next possible objects. To find the birthplace of the PERSON you would select "**was_born_in**" and you would get the relation `PERSON-[was_born_in]->PLACE` going from a PERSON to a PLACE.
     84
     85To get the texts written by Tusi we need the relation `TEXT-[was_created_by]->PERSON` which goes from a TEXT to a PERSON. But in our case we want to start at the PERSON not the TEXT so we have to select the reverse relation "**<- was_created_by**".
     86
     87When we select "**<- was_created_by**" in the second select box the system runs the query to find all texts that were created by Tusi:
     88
     89[[Image(qb-person-tusi-id-created.png)]]
     90