QueryClear()

Clears all rows from a query

Introduced: 6.0.0.15

QueryClear( query=query );

Returns: Query

Argument Description
query
query, required

query to clear all data.

Examples

qry = queryNew( "name, age", "varchar, integer",
        [
            [ "Susi", 20 ],
            [ "Urs", 24 ],
            [ "Smith", 21 ],
            [ "John", 26 ]
        ]);
    writeOutput("Before QueryClear :");
    writeDump(qry);
<span class="nv">result</span> <span class="o">=</span> <span class="nf">queryClear</span><span class="p">(</span><span class="nv">qry</span><span class="p">);</span>
<span class="nf">writeOutput</span><span class="p">(</span><span class="s2">&quot;After QueryClear :&quot;</span><span class="p">);</span>
<span class="nf">writeDump</span><span class="p">(</span><span class="nv">qry</span><span class="p">);</span>

See also