Deletes all the elements of a variable of the array type.
 

1 array.clear

<array.clear name='name'>
    <array /> ?
</array.clear>
Example

Delete all the elements of an array.

Copy
<xsql-script name='array_clear_test1'>
    <body>
        <array name='cities'>
            <string>Barcelona</string>
            <string>Paris</string>
            <string>Roma</string>
        </array>

        <array.clear name='cities' />

        <println><cities /></println>
    </body>
</xsql-script>

The content of the structure is deleted with this function, erasing all the elements which compose the array. Another way to empty the variable ‘cities’, would be: <array.clear ><cities/></array.clear>