Difference Between TableLookup, TableLookup, TableReader

Aspect TableLookup TableLookupEx TableReader
Purpose Executes a SQL query and returns a single value from the first row and first column. Executes a SQL query and returns a complete in-memory DataTable with all rows and columns. Executes a SQL query and returns a forward-only, read-only stream of data row by row.
Return Type Object (single value) DataTable (complete in-memory table). DbDataReader (forward-only stream).
Data Access First row, first column only. Any row, any column, any time. One row at a time, forward-only. Cannot go back to a previous row.
Memory Usage Very low. Single value only. High. Entire query result loaded into memory. Very low. Only one row in memory at a time.
Performance Fastest for single value retrieval. Slower for large datasets due to full in-memory copy. Fastest for large datasets due to streaming.
Best For Quick single value lookups. Flexible multi-row, multi-column queries needing post-processing. Large volume data reads where memory is a concern.
Requires Manual Close? No No Yes. Must be closed manually. Use Using statement to auto-close.
Supports Timeout? No No Yes. Optional .DataReaderTimeOut parameter in seconds.
DataTable Name Not applicable Optional. Defaults to "TableLookup". Not applicable.
Risk None Out-of-memory risk for very large datasets. Low. Only one row in memory at a time.
Supported In Workflows, Copy Methods, Equations. Workflows, Copy Methods, Equations. Workflows only.