Question: xsd how to define attribute?
Answer: Syntax. <xs:attribute name = "attribute-name" type = "attribute-type"/> ...  Example. Consider the following XML Element <student rollno = "393" /> ...  Default Value. Attribute can have a default value assigned to it. ...  Fixed Value. Attribute can have a fix value assigned. ...  Restriction.