Alert.png The wiki is deprecated and due to be decommissioned by the end of September 2022.
The content is being migrated to other supports, new updates will be ignored and lost.
If needed you can get in touch with EGI SDIS team using operations @

GOCDB/Selecting Fields Shown in a Web Portal Table

From EGIWiki
Revision as of 13:28, 20 December 2010 by Aesch (talk | contribs)
Jump to navigation Jump to search

Back to GOCDB/Release4/Customisation

Modifying Fields Shown in a Table View

To add or remove a field from a table shown in the web portal, follow these three steps:

  • Find out the name of the query used to get the table's data
  • Find the individual query XML file corresponding to this query
  • Add or remove fields from this XML file

Getting the Table's Query Name

When a table page is requested, the query name is specified in the URL as the &query= parameter. The parameter is the query name. For example in the URL:


The query name is "Get_Site_Production".

Finding the Individual XML Query File

The individual XML query file contains a list of fields that are returned by a query. These are the fields to modify. Firstly, this file needs to be located.

To find out which individual query file corresponds to a query name, the "XML Output" queries XML file (containing data for all available queries) is used. In this release of GOCDB-4, the XML Output queries file is in the following location:


Each available query is uniquely named in this file. Searching for a query name (in this case, "Get_Site_Production" in the 4.0d1 release) leads to the following XML:

  inner join
   tobjects objects
    objects.cdateoff > sysdate
    objects.cdateoff is null
  order by
 <description>Get a list of Site objects</description>

The final leaf node of this XML tree "output_file_format" specifies the individual query file location and name.

Modifying the Individual Query File

The individual file for the Get_Sites_Production query is as follows:

<?xml version="1.0" encoding="UTF-8"?>

Each field specified here is drawn in the table shown in the web portal. To remove a field, simply remove one of the leaf nodes. For example, deleting the line


will stop the location field from being drawn in the web portal.

The format of these fields is as follows:


The database field name is the field name returned by the query specified in the "XML Output" queries XML file.

Special Cases

Some configuration files are used internally within the system to provide functionalities like the "Search" page and the individual tables shown when a "Site" object is viewed.

A list of these functions and their associated XML query name and individual query file name are included here:

Web Portal Table Query Name Individual Query File Name
Search results: users table  Get_User_Search  Get_User_Search.xml
Search results: site table  Get_Site_Search  Get_Site_Search.xml
Search results: service endpoints table  Get_Site_Search  Get_Site_Search.xml
Viewing an individual site: downtimes table  Downtimes_For_Specified_Site  Get_Downtime_Production.xml
Viewing an individual site: service endpoints table  Get_Endpoints_By_Site  Get_Service_Endpoint_By_Site.xml