How to replace xml tag with DTD object

I can replace xml attribute values ​​using DTD Entity declaration using following method

//in DTD
<!ENTITY varchar "VARCHAR(200)">
// In xml 
<column name="attachment_url" type="&varchar;"/>

      

Now I want to replace the xml tag like

<column name="attachment_url" type="VARCHAR(200)"/>

using a DTD object.

I am doing my best <!ENTITY full_coulumn "&lt;column name=&quot;attachment_url&quot; type=&quot;VARCHAR(200)&quot;/&gt;">

then I get the error

 Unexpected column with text: <column name="attachment_url" type="VARCHAR(200)
"/>

      

Is it possible to replace the whole xml tag with dtd Entity? How can i do this?

I am trying to do this using a Liquibase xml file.

0


source to share


1 answer


Don't avoid markup in your object declaration; in doing so, you signal to the processor that the entity replacement text is a character string and not markup. Do you want to:



<!ENTITY full_column "<column name='attachment_url' 
                      type='VARCHAR(200)' />">

      

+1


source







All Articles