==Perform Queries==
===PrerequisitesPreparations===
# Download a BaseX distribution with all libraries included(ZIP, EXE, WAR, DMG): http://basex.org/download# Compatible versions of the three libaries <code>basex.jar</code>, <code>basex-api.jar</code>, Start oXygen and <code>xqj-apigo to ''Options'' → ''Preferences'' → ''Data Sources''.jar</code>
===Data Source===
# Start oXygen and go to ''Options'' → ''Preferences'' → ''Data Sources''.
# Add a new Data Source with the ''New'' button.
# Enter "BaseX" as name and choose ''XQuery API for Java (XQJ)'' as type.
# Add the following three JAR files above with the ''Add'' Button: <code>basex.jar</code>, <code>basex-api.jar</code>, and <code>xqj-api.jar</code>. The JAR files might include version names.
# Now press ''OK'', and your Data Source is ready for use.
===Connection===
# Now press ''New'' in the Connection Panel (located in ''Data Sources'')below. # Enter Name "BaseXConnectionBaseX" and select "BaseX" in the Data Source box.
# Now press ''OK'', and your connection is ready.
===Usage===
The query execution works as follows:
# Configure a new transformation scenario in ''Window'' → ''Show View'' → ''Transformation Scenarios''.
# Press the <code>plus</code> sign to add a new scenario.
# Enter a Name, XML URL (your xml file or leave it empty) and the XQuery URL (your query file). # Choose "BaseXConnectionBaseX" in the combo box. # Press ''OK'', and your scenario is ready. Now you can start the transformation, e.g. by clicking on the red ''Play'' button.
# The results should immediately occur in the result panel.
[[Category:Instructions]]