Read items from a list (dynamic columns)
Same as reading list items with ListId, but uses get_list_items_dynamic so column types are inferred from sample rows. Use when get_list_items leaves complex fields null or wrong (e.g. Lookup, Person, Location) or types do not match.
SELECT * FROM get_list_items_dynamic
WITH (
ListId='14bdfd1d-1090-4cfe-adc1-XXXXXXXXXXXXXX'
)
--Obtain ListId from the Lists table or list_lists (e.g. SELECT id, name FROM Lists).