Is there any way to fetch the master data like Ledgers from tally ranging from xyz AlterId to abc AlterId or the Ledgers whose alterId is greater then xyz AlterId?
Convert Exactly what you required into a TDL Formula and Filter Masters Based on That Formulae
$ALTERID > '100'
>
is escaped text of >
If you want filter between Range(Ex:100 to 120) then
$ALTERID > '100' AND $ALTERID < '120'
If you go any problem then try removing quotes for $ALTERID > 100
Final XML will look like
<ENVELOPE>
<HEADER>
<VERSION>1</VERSION>
<TALLYREQUEST>Export</TALLYREQUEST>
<TYPE>Collection</TYPE>
<ID>CustMasterColl</ID>
</HEADER>
<BODY>
<DESC>
<STATICVARIABLES>
<SVEXPORTFORMAT>$$SysName:XML</SVEXPORTFORMAT>
</STATICVARIABLES>
<TDL>
<TDLMESSAGE>
<COLLECTION ISMODIFY="No" ISFIXED="No" ISINITIALIZE="No" ISOPTION="No" ISINTERNAL="No" NAME="CustMasterColl">
<!-- * Tally Masters Types like Ledger, Group, StockItem ..etc., -->
<TYPE>Ledger</TYPE>
<FILTERS>Masterfilter</FILTERS>
</COLLECTION>
<!-- * IF you want Between then $ALTERID > '100' AND $ALTERID < '120' -->
<SYSTEM TYPE="Formulae" NAME="Masterfilter">$ALTERID > '100'</SYSTEM>
</TDLMESSAGE>
</TDL>
</DESC>
</BODY>
</ENVELOPE>