The Scenario
You are putting together a sector-rotation strategy overview for the investment committee. The committee wants a breakdown of the current watchlist by sector and industry — how many holdings are in technology versus healthcare versus financials, and whether the portfolio is concentrating risk in any single industry group.
You have 50 tickers in column A of your Excel workbook. Columns B, C, and D are labeled Exchange, Sector, and Industry — all blank. Marketstack has this metadata. Getting it into the workbook is a separate problem from the analysis.
Someone on the team spent an hour earlier this week manually looking up a handful of the tickers on the exchange's website and copying the sector labels by hand. They got through 12 before moving on to something more urgent. The other 38 are still blank.
The bad version:
- Call Marketstack's ticker info endpoint for the first ticker, inspect the JSON to find the exchange, sector, and industry fields, and paste them into columns B, C, and D
- Repeat for 49 more tickers — noticing somewhere around ticker 20 that some tickers return a sector label of "N/A" because Marketstack does not have classification data for every exchange
- Finish the 50 tickers and realize you still need to build a summary count by sector, which means a pivot table you have not started yet
The sector breakdown was supposed to be ready for the 2 PM call. It is 1:15.
The Easy Way: One Prompt in SheetXAI
SheetXAI is an AI agent that lives inside your Excel workbook. It reads the ticker list in column A and through its Marketstack integration it can fetch exchange name, sector, and industry classification for every ticker and write them into the adjacent columns.
For each ticker in column A, call Marketstack to get ticker info and write the exchange name into column B, sector into column C, and industry into column D; leave a note in column E if Marketstack does not return sector data for a given ticker
What You Get
- Exchange name in column B for every ticker
- Sector classification in column C
- Industry classification in column D
- Column E flagging any ticker where Marketstack returned no sector data, so you know where to fill in manually
What If the Data Is Not Quite Ready
Some tickers are listed on multiple exchanges and you want the primary listing
For each ticker in column A, fetch ticker info from Marketstack and write the name of the primary exchange, sector, and industry into columns B, C, and D — if Marketstack returns multiple exchange listings, use the one with the highest trading volume
You want a summary worksheet added automatically
For each ticker in column A, fetch exchange, sector, and industry from Marketstack and write into columns B, C, and D; then add a Summary worksheet counting the number of tickers per sector and the number per industry, sorted by count descending
Some rows already have sector data and you only want to fill in the blanks
For each ticker in column A where column C is blank, fetch the sector and industry from Marketstack and fill in columns C and D; leave any row where column C already has a value untouched
Full enrichment pipeline: fetch metadata, flag concentration, add a summary breakdown
For each ticker in column A, fetch exchange, sector, and industry from Marketstack and write into columns B, C, and D; then build a Summary worksheet with sector counts, highlight any sector that contains more than 20 percent of the total tickers, and add an Industry Breakdown worksheet showing the top 10 industries by count
Doing the enrichment and the concentration analysis in a single prompt means the committee presentation is ready rather than still in progress.
Try It
Get the 7-day free trial of SheetXAI and open the Excel workbook with your ticker list, then ask it to enrich every row with exchange, sector, and industry from Marketstack. The Marketstack integration is included in every SheetXAI plan.
See also: resolving company names to ticker symbols and exporting the full exchange catalog.
