<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: Difference between element and attributes while creating data types in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345498#M1340375</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mohan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Elements and Attributes &lt;/P&gt;&lt;P&gt;You create complex data types using elements and attributes in the XSD editor:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Node Type&lt;/P&gt;&lt;P&gt; Use&lt;/P&gt;&lt;P&gt; Example Instance&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Element&lt;/P&gt;&lt;P&gt; Create structured data types. Elements that have a type cannot contain subelements.&lt;/P&gt;&lt;P&gt; &amp;lt;myElem&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;f1&amp;gt; Value of f1 &amp;lt;/f1&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;f2&amp;gt; Value of f2 &amp;lt;/f2&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/myElem&amp;gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Attribute&lt;/P&gt;&lt;P&gt; Add attributes to elements. Attributes cannot usually have subnodes. &lt;/P&gt;&lt;P&gt; &amp;lt;myElem myAttr="AttributeValue"&amp;gt;&lt;/P&gt;&lt;P&gt;  Element Value&lt;/P&gt;&lt;P&gt;&amp;lt;/myElem&amp;gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can flag an attribute as optional or required in the Occurrence column. These values mean the same for elements with an occurrence of 0..1 or 1. The only difference between elements and attributes is that attributes cannot have subnodes and that the same attribute cannot be used more than once in an element.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Phani&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if Helpful &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 23 Jan 2008 12:28:09 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-01-23T12:28:09Z</dc:date>
    <item>
      <title>Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaq-p/3345494</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gurus,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please provide me the difference between element and attribute.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It would be great,if I can get some example with exact usage.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;MohanRaj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2008 12:18:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaq-p/3345494</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-23T12:18:11Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345495#M1340372</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mohan!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is a philosophycal question - attributes vs. elements. Technically it will work if you do in anyhow. The difference is only logical.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can create a DT like&lt;/P&gt;&lt;P&gt;&amp;lt;person&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;name&amp;gt;&amp;lt;/name&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;age&amp;gt;&amp;lt;/name&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/person&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but also like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;person name="myname" age="myage"/&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so, depends just on your opinion, what you like more. The truth is, it is a bit easier to process attributes in XSLT and in some programming languages. But as I said, depends only on you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2008 12:23:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345495#M1340372</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-23T12:23:25Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345496#M1340373</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mohan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Elements contains information as an independent field, while attributes are those which contains data about that element means its meta data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For eg: If ABC is a Node and it contain Field Name then Field Name is its element and at the same level If ABC have color, size, etc like fields then they are attributes which are common for all elements.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rewards if found helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR, Kasturika Phukan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2008 12:23:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345496#M1340373</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-23T12:23:26Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345497#M1340374</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, attribute is only an attribute of element's entity. You can have just element w/o attribute, but can't have attribute w/o element.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See some pages about XML.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2008 12:25:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345497#M1340374</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-23T12:25:42Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345499#M1340376</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Refer this thread &lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04/helpdata/en/0d/5ab43b274a960de10000000a114084/frameset.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/0d/5ab43b274a960de10000000a114084/frameset.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sakthi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2008 12:28:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345499#M1340376</guid>
      <dc:creator>former_member267355</dc:creator>
      <dc:date>2008-01-23T12:28:09Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345498#M1340375</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mohan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Elements and Attributes &lt;/P&gt;&lt;P&gt;You create complex data types using elements and attributes in the XSD editor:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Node Type&lt;/P&gt;&lt;P&gt; Use&lt;/P&gt;&lt;P&gt; Example Instance&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Element&lt;/P&gt;&lt;P&gt; Create structured data types. Elements that have a type cannot contain subelements.&lt;/P&gt;&lt;P&gt; &amp;lt;myElem&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;f1&amp;gt; Value of f1 &amp;lt;/f1&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;f2&amp;gt; Value of f2 &amp;lt;/f2&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/myElem&amp;gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Attribute&lt;/P&gt;&lt;P&gt; Add attributes to elements. Attributes cannot usually have subnodes. &lt;/P&gt;&lt;P&gt; &amp;lt;myElem myAttr="AttributeValue"&amp;gt;&lt;/P&gt;&lt;P&gt;  Element Value&lt;/P&gt;&lt;P&gt;&amp;lt;/myElem&amp;gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can flag an attribute as optional or required in the Occurrence column. These values mean the same for elements with an occurrence of 0..1 or 1. The only difference between elements and attributes is that attributes cannot have subnodes and that the same attribute cannot be used more than once in an element.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Phani&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if Helpful &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2008 12:28:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345498#M1340375</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-23T12:28:09Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345500#M1340377</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Element&lt;/STRONG&gt; is everything from (including) the element's start tag to (including) the element's end tag.&lt;/P&gt;&lt;P&gt;An element can contain other elements, simple text or a mixture of both. Elements can also have attributes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Attributes&lt;/STRONG&gt; often provide information that is not a part of the data. In the example below, the file type is irrelevant to the data, but important to the software that wants to manipulate the element.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In case you use the JDBC Adapter, for example. The muster XML-SQL from help.sap.com use attribute action to describe what kind of action should be performed, but action does not belongs to Payload, for example the content you want to insert into one table, does NOT contain action.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;root&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;StatementName1&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;dbTableName action=&amp;#148;UPDATE&amp;#148; | &amp;#147;UPDATE_INSERT&amp;#148;&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;table&amp;gt;realDbTableName&amp;lt;/table&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;access&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;col1&amp;gt;val1&amp;lt;/col1&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;col2&amp;gt;val2new&amp;lt;/col2&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/access&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;key1&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;col2&amp;gt;val2old&amp;lt;/col2&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;col4&amp;gt;val4&amp;lt;/col4&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/key1&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;key2&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;col2&amp;gt;val2old2&amp;lt;/col2&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/key2&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/dbTableName&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/StatementName1&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;Hai&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2008 12:32:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345500#M1340377</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-23T12:32:47Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between element and attributes while creating data types</title>
      <link>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345501#M1340378</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;go through this link &lt;A class="active_link" href="http://help.sap.com/saphelp_erp2004/helpdata/en/3b/d2a3f7a166514abb8cf5635b71974f/content.htm" title="http://help.sap.com/saphelp_erp2004/helpdata/en/3b/d2a3f7a166514abb8cf5635b71974f/content.htm"&gt;http://help.sap.com/saphelp_erp2004/helpdata/en/3b/d2a3f7a166514abb8cf5635b71974f/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_erp2004/helpdata/en/3b/d2a3f7a166514abb8cf5635b71974f/content.htm" title="http://help.sap.com/saphelp_erp2004/helpdata/en/3b/d2a3f7a166514abb8cf5635b71974f/content.htm"&gt;http://help.sap.com/saphelp_erp2004/helpdata/en/3b/d2a3f7a166514abb8cf5635b71974f/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Brahmaji&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Oct 2013 07:55:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/difference-between-element-and-attributes-while-creating-data-types/qaa-p/3345501#M1340378</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-10-17T07:55:56Z</dc:date>
    </item>
  </channel>
</rss>

