[#wallet-DescriptorScriptPubKeyMan-TopUpWithDB]
= xref:wallet.adoc[wallet]::xref:wallet/DescriptorScriptPubKeyMan.adoc[DescriptorScriptPubKeyMan]::TopUpWithDB
:relfileprefix: ../../
:mrdocs:

Same as &apos;TopUp&apos; but designed for use within a batch transaction context

== Synopsis

Declared in `&lt;wallet&sol;scriptpubkeyman&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
bool
TopUpWithDB(
    xref:wallet/WalletBatch.adoc[WalletBatch]& batch,
    unsigned int size = 0);
----

== Return Value

true if the cache was successfully topped up&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *batch*
| The database batch to write new cache entries through&period;
| *size*
| Number of keys to top up to, or 0 to use the configured keypool size&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
