DB Get Batch List
Turn a list in your data file into a real ComfyUI batch
- source
- item
DBGetBatchList is the batching heart of the DataBeast pack. DBLoadData gets a file into the graph and DBGetItem pulls single values out; this is the node that takes a list from your data file and turns it into a ComfyUI batch - so each item in the list runs the whole workflow once, with that item's values available for the next step. If you've ever copy-pasted a prompt 50 times or re-queued by hand, this is the part that fixes it.
The mechanism, and why it's the "right" way
The node evaluates your expression against the loaded document, expects a list, wraps each element in a DBItem, and returns them with OUTPUT_IS_LIST = True. ComfyUI sees a genuine list output and iterates your workflow over it - no manual Queue Batch Count dance, no auto-queue hacks.
That distinction isn't trivia, it's a design decision the author made in public. On r/comfyui he asked how other node authors handle file-driven batching and laid out the two approaches: hijacking the queue system to keep re-running, versus returning an actual list from a node marked OUTPUT_IS_LIST. He chose the list approach and called it "the more standard solution" - this pack is the result. So when someone tells you to set Queue Batch Count and enable Auto Queue for DataBeast, they're describing the older hack, not this node.
Inputs and output
- source - the
DB_ITEM(normally fromDBLoadData, but a chainedDBGetItemworks too). - expression - the key path to a list inside the document. For a CSV-loaded file the whole table lives under
items, so the expression is["items"](or['items'], either quote style parses fine). For a YAML file with a top-levelprompts:list, it's["prompts"].
The output, item, is a list of DB_ITEM (note the "is_list: true" in the schema - that's what drives the batch). Feed it to DBGetItem to pull per-item values, then through the DBConvert* nodes to get real strings, ints, and floats for your prompt, CFG, seed, whatever.
A couple of practical notes:
- Because
DBLoadDatare-reads the file on every run, editing your data file and re-queuing picks up the new rows automatically. That's the whole loop: edit file → run → watch the batch. - If your expression doesn't resolve to a list - say a key is spelled wrong - the node quietly returns an empty batch and your workflow does nothing. Silent, not loud. Lint the expression against your file first.
Installing
DB Get Batch List ships in ComfyUI DataBeast, which is not in ComfyUI Manager yet (the README says it'll be added once stable). Clone it by hand:
cd ComfyUI/custom_nodes
git clone https://github.com/hanoixan/ComfyUI-DataBeast
cd ComfyUI-DataBeast
pip install -r requirements.txt
Restart, and the DB nodes appear under the DataBeast category. Dependencies are minimal - pyyaml and RestrictedPython - and there are no model downloads. One heads-up for anyone who saved workflows against the V0.1 alpha: the V0.2 API changed so DBGet* return DBItem and DBConvert* expect one; older graphs may need rewiring.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| source | DB_ITEM | Source item to get data from. | |
| expression | STRING | Expression to get batch list. A Python expression that when appended onto the input data leads to a list in the loaded table to generate the batch items from. Ex: If we assume inputs data is a table with an "items" key and list value, we would write: ["items"] |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| item | DB_ITEM | — |