TWiki> IVOA Web>TonyLinde>TonyOnUCDs (revision 7)EditAttach

My understanding of UCDs

The way this came up was my question in the plenary UCD session about how we can identify columns within a table uniquely. Basically, the answer was that UCDs will not solve this problem and are not intended to do so. This page will summarise what I now understand as the purpose of UCDs and some of the implications of this.

UCDs as Data Types

Comment was made that UCDs can be considered as data types, so a column in a table has a data type of, POS_EQ_RA, say. I assume that the reasons for having UCDs as data types are to allow:

  • operations on columns: comparison, addition, subtraction, multiplication, etc plus specific astronomical operations
  • conversion between data types: eg converting between equitorial and galactic coordinates

Do we thus need (or already have) some hierarchical structure of the UCDs based on allowable operations? In normal data types, we have numerical types, subdivided by integral and floating point, subdivided by storage size etc; one can add all numerical types but (generally) cannot add a number and a string (without pre-defining what such an addition will do).

Aligned to that: should we define the operations that can be performed on the individual data types (UCDs), the rules for those operations given specific types, and the type resulting from such operations.

UCDs as Keywords

In this context, the UCDs is part of the metadata for a table. It indicates the type of data held in a table, so having POS_EQ_RA identified with a table says that this table includes positional data in equitorial coordinates. That said, maybe the UCD for the table should include POS_EQ instead (since it is unlikely that it'll have RA without DEC).

So the idea of being able to query which resources have POS_EQ* makes sense.

Unique Column Identification

Given that we cannot use UCDs as unique column identifiers, how do we do this?

It seems that the only possible unique identifier for a column in a table is the resourceID of the table (from the Registry) plus the columnName (for explanation of resourceID, see the discussion on this in the Registry mailing list: http://www.ivoa.net/forum/registry/0091.htm and related messages).

So, to summarise the discussion from the plenary session, a query can be sent to a table with either UCDs or column names or a mixture of both. If a UCD is included in a query, the data source can resolve this if there is only one column with that UCD or there are multiple columns but one has the modifier MAIN attached to only one of the column UCDs. Otherwise the query will fail.

A possible query structure (using xml-ised SQL) would be:

<query> <from> <resourceID asName="cat1"> <authorityID>...</authorityID> <resourceKey>...</resourceKey> </resourceID> <resourceID asName="cat2"> <authorityID>...</authorityID> <resourceKey>...</resourceKey> </resourceID> </from> <select> <field asName="pos-ra" ucd="POS_EQ_RA" /> <field ucd="POS_EQ_DEC"> <isColumn columnName="DEJ2000" inResource="cat2" /> </field> <field ucd="..." /> </select> </query> </plaintext> <p /> The <em>asName</em> attribute allows the possibility of referring to an item later in the query structure. The <em>ucd</em> attribute is obvious. The key aspect of the above query is the inclusion of the <strong><isColumn ...></strong> tag within the field tag allowing for identification of columns where the UCD is not unique. </div><!-- /patternTopic--> <div class="twikiContentFooter"></div></div><!-- /patternContent--> <div class="clear"></div> <a name="topic-actions"></a><div class="patternTopicActions"><div class="patternTopicAction"><span class="patternActionButtons"><span><strike>Edit</strike></span><span class='twikiSeparator'>&nbsp;|&nbsp;</span><span><strike>Attach</strike></span><span class='twikiSeparator'>&nbsp;|&nbsp;</span><span><a href='/twiki/bin/view/IVOA/TonyOnUCDs?cover=print%3brev%3d7&amp;rev=7' rel='nofollow' title='Printable version of this topic' accesskey='p'><span class='twikiAccessKey'>P</span>rint version</a></span><span class='twikiSeparator'>&nbsp;|&nbsp;</span><span><span><a href='/twiki/bin/rdiff/IVOA/TonyOnUCDs?type=history' rel='nofollow' title='View total topic history' accesskey='h'><span class='twikiAccessKey'>H</span>istory</a></span>: <a rel="nofollow" href="/twiki/bin/view/IVOA/TonyOnUCDs?rev=11">r11</a> | <a rel="nofollow" href="/twiki/bin/view/IVOA/TonyOnUCDs?rev=9">r9</a>&nbsp;<a rel="nofollow" href="/twiki/bin/rdiff/IVOA/TonyOnUCDs?rev1=9;rev2=8">&lt;</a>&nbsp;<a rel="nofollow" href="/twiki/bin/view/IVOA/TonyOnUCDs?rev=8">r8</a>&nbsp;<a rel="nofollow" href="/twiki/bin/rdiff/IVOA/TonyOnUCDs?rev1=8;rev2=7">&lt;</a>&nbsp;r7&nbsp;<a rel="nofollow" href="/twiki/bin/rdiff/IVOA/TonyOnUCDs?rev1=7;rev2=6">&lt;</a>&nbsp;<a rel="nofollow" href="/twiki/bin/view/IVOA/TonyOnUCDs?rev=6">r6</a></span><span class='twikiSeparator'>&nbsp;|&nbsp;</span><span><a href='/twiki/bin/oops/IVOA/TonyOnUCDs?template=backlinksweb' rel='nofollow' title='Search the IVOA Web for topics that link to here' accesskey='b'><span class='twikiAccessKey'>B</span>acklinks</a></span><span class='twikiSeparator'>&nbsp;|&nbsp;</span><span><a href='/twiki/bin/view/IVOA/TonyOnUCDs?raw=on&amp;rev=7' rel='nofollow' title='View raw text without formatting' accesskey='r'><span class='twikiAccessKey'>R</span>aw View</a></span><span class='twikiSeparator'>&nbsp;|&nbsp;</span><span><strike>Raw edit</strike></span><span class='twikiSeparator'>&nbsp;|&nbsp;</span><span><strike>More topic actions...</strike></span></span></div><!--/patternTopicAction--></div><!--/patternTopicActions--> <div class="patternInfo twikiGrayText"><div class="patternRevInfo">Topic revision: r7 - 2003-05-16 <a href="https://wiki.ivoa.net/twiki/bin/edit/IVOA/TonyOnUCDs?nowysiwyg=1627179982" target="_top">-</a> <a href="/twiki/bin/view/IVOA/DougTody" class="twikiLink">DougTody</a></div><!-- /patternRevInfo--></div><!-- /patternInfo--> </div><!-- /patternMainContents--> </div><!-- /patternMain--><div id="patternLeftBar"><div id="patternClearHeaderLeft"></div> <div id="patternLeftBarContents"><div class="patternWebIndicator"> <ul> <li> <a href="/twiki/bin/view/IVOA/WebHome" class="twikiCurrentWebHomeLink twikiLink"><img src="/internal/TWiki/TWikiDocGraphics/web-bg-small.gif" width="13" height="13" alt="Web background" title="Web background" border="0" /> IVOA</a> </li></ul> </div> <strong><a href="https://wiki.ivoa.net/twiki/bin/login/TWiki/TWikiRegistration?origurl=/twiki/bin/view/TWiki/TWikiRegistration" target="_top">Log in</a> or <a href="/twiki/bin/view/IVOA/TWikiRegistrationInstructions" class="twikiLink">Register</a></strong> <div id="widgetbox"> <p /> <strong>IVOA.net</strong> <br /> <a href="/twiki/bin/view/IVOA/WebHome">Wiki Home</a> <br /> <a href="/twiki/bin/view/IVOA/WebChanges">WebChanges</a> <br /> <a href="/twiki/bin/view/IVOA/WebTopicList">WebTopicList</a> <br /> <a href="/twiki/bin/view/IVOA/WebStatistics">WebStatistics</a> <p /> <strong>Twiki Meta &amp; Help</strong> <br /><a href="/twiki/bin/view/IVOA/WebHome">IVOA</a> <br /><a href="/twiki/bin/view/Know/WebHome">Know</a> <br /><a href="/twiki/bin/view/Main/WebHome">Main</a> <br /><a href="/twiki/bin/view/Sandbox/WebHome">Sandbox</a> <br /><a href="/twiki/bin/view/TWiki/WebHome">TWiki</a> <hr /> <small><a href="/twiki/bin/view/TWiki/WelcomeGuest">TWiki intro</a> <br /> <a href="/twiki/bin/view/TWiki/TWikiTutorial">TWiki tutorial</a> <br /> <a href="/twiki/bin/view/IVOA/TWikiRegistrationInstructions">User registration</a> <br /> <a href="/twiki/bin/view/IVOA/WebNotify">Notify me</a></small> <p /> <strong>Working Groups</strong> <ul> <li> <a href="/twiki/bin/view/IVOA/IvoaApplications" class="twikiLink">Applications</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaDAL" class="twikiLink">Data Access Layer</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaDataModel" class="twikiLink">Data Model</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaGridAndWebServices" class="twikiLink">Grid &amp; Web Services</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaResReg" class="twikiLink">Registry</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaSemantics" class="twikiLink">Semantics</a> </li></ul> <p /> <strong>Interest Groups</strong> <ul> <li> <a href="/twiki/bin/view/IVOA/IvoaDCP" class="twikiLink">Data Curation</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaEducation" class="twikiLink">Education</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaKDD" class="twikiLink">Knowledge Discovery</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaOps" class="twikiLink">Operations</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaRadio" class="twikiLink">Radio Astronomy</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaSS" class="twikiLink">Solar System</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaTheory" class="twikiLink">Theory</a> </li> <li> <a href="/twiki/bin/view/IVOA/IvoaVOEvent" class="twikiLink">Time Domain</a> </li></ul> <p /> <strong>Committees</strong> <ul> <li> <a href="/twiki/bin/view/IVOA/IvoaStdsDocsProc" class="twikiLink">Stds&amp;Procs</a> </li></ul> <p /> <hr /> <p /> <a href="/">www.ivoa.net</a><br /> <a href="/Documents/latest/"><a href="http://www.ivoa.net/documents/" target="_top">Documents</a></a><br /> <a href="/twiki/bin/view/IVOA/IvoaEvents">Events</a><br /> <a href="/"> <a href="http://www.ivoa.net/members" target="_top">Members</a></a><br /> <a href="/xml/"><a href="http://www.ivoa.net/xml/index.html" target="_top">XML Schema</a></a> </div> </div><!-- /patternLeftBarContents--></div><!-- /patternLeftBar--> </div><!-- /patternFloatWrap--> <div class="clear">&nbsp;</div> </div><!-- /patternOuter--></div><!-- /patternWrapper--><div id="patternTopBar"><div id="patternTopBarContents"><table border="0" cellpadding="0" cellspacing="0" style="width:100%; margin-top:12px;"> <tr><td valign="middle"><span id="twikiLogo" class="twikiImage"><a href="/twiki/bin/view/IVOA/WebHome"><img src="/internal/IVOA/WebPreferences/ivoa_logo71x40.jpg" border="0" alt="IVOA" style="border:none;" /></a></span></td> <td align="right" valign="top" class="patternMetaMenu"> <ul> <li> <form name="jumpForm" action="/twiki/bin/view/IVOA/TonyOnUCDs"><input id="jumpFormField" type="text" class="twikiInputField" name="topic" value="" size="18" /><noscript>&nbsp;<input type="submit" class="twikiButton" size="5" name="submit" value="Jump" />&nbsp;</noscript> </form> </li> <li> <form name="quickSearchForm" action="/twiki/bin/view/IVOA/WebSearch"><input type="text" class="twikiInputField" id="quickSearchBox" name="search" value="" size="18" /><input type="hidden" name="scope" value="all" /><input type="hidden" name="web" value="IVOA" /><noscript>&nbsp;<input type="submit" size="5" class="twikiButton" name="submit" value="Search" />&nbsp;</noscript> </form> </li> <li> </li></ul> </td></tr></table></div></div><!-- /patternTopBar--><div id="patternBottomBar"><div id="patternBottomBarContents"><div id="patternWebBottomBar"><span class="twikiRight"> <a href="http://twiki.org/"><img src="/internal/TWiki/TWikiLogos/T-badge-88x31.gif" alt="This site is powered by the TWiki collaboration platform" width="88" height="31" title="This site is powered by the TWiki collaboration platform" border="0" /></a></span>Copyright &copy; 2008-2021 by the contributing authors. All material on this collaboration platform is the property of the contributing authors. <br /> Ideas, requests, problems regarding TWiki? <a href='mailto:ivoadoc@ivoa.net?subject=TWiki%20Feedback%20on%20IVOA.TonyOnUCDs'>Send feedback</a></div><!--/patternWebBottomBar--></div><!-- /patternBottomBarContents--></div><!-- /patternBottomBar--> </div><!-- /patternPage--> </div><!-- /patternPageShadow--> </div><!-- /patternScreen--> </body></html>