IF object_id('tempdb..#tmpTable') IS NOT NULL  
DROP TABLE [dbo].[#tmpTable]  
		
CREATE TABLE #tmpTable
(
   Zone VARCHAR(50),
   ExtRef VARCHAR(50)
)

-- **** all the mapping list provided from CFA should be inserted here 
INSERT INTO #tmpTable 
Values 
('East Texas','9'),
('ATL-Coweta/Fayette','10'),
('Athens','11'),
('Columbus','12'),
('Indianapolis North','14'),
('Orlando South','20'),
('Triad East','24'),
('Triad West','25'),
('Philadelphia Central','32'),
('Philadelphia West','34'),
('Wilmington','35'),
('DFW Denton County','36'),
('DFW Dallas South','37'),
('Northern Indiana','38'),
('Orlando North','42'),
('Orlando Central','43'),
('N Central Florida','44'),
('New Jersey North','45'),
('ATL-Forsyth/Fulton','48'),
('ATL-East Cobb','50'),
('ATL-BuckheadDowntown','52'),
('ATL-20 West','54'),
('ATL-20 East','55'),
('Charlotte III','56'),
('Augusta','57'),
('Chattanooga','59'),
('Charlotte I','60'),
('Charlotte II','61'),
('Central VA West','62'),
('Central Mississippi','66'),
('Central Alabama','67'),
('Denver North','68'),
('Denver South','69'),
('Central Pennsylvania','70'),
('DFW Dallas East','72'),
('DFW Dallas North','73'),
('Daytona','75'),
('Dayton','76'),
('El Paso','77'),
('Charlotte IV','79'),
('Emerald Coast','80'),
('Houston Central','82'),
('Houston North','83'),
('Houston Southeast','84'),
('Indianapolis South','85'),
('Louisville','89'),
('North Louisiana','90'),
('Michigan','92'),
('Myrtle Beach','94'),
('North Alabama','95'),
('New Jersey South','97'),
('Northern Ohio','98'),
('Palm/Treasure Coast','103'),
('South Georgia','109'),
('Space Coast','110'),
('South Texas','111'),
('St. Louis','112'),
('Georgia Low Country','114'),
('Southwest Florida','115'),
('Tallahassee','117'),
('Tidewater Peninsula','118'),
('Tampa East','119'),
('Tri-Cities','121'),
('Central Texas','125'),
('Tulsa','126'),
('West Virginia','131'),
('Hampton Roads South','133'),
('Virginia Beach','134'),
('South Louisiana','136'),
('Middle Georgia','137'),
('ATL-75/285 North','138'),
('ATL-DeKalb','139'),
('ATL-Northwest','140'),
('ATL-North Perimeter','141'),
('ATL-Gwinnett','142'),
('ATL-Northern Loop','143'),
('ATL-North Georgia','144'),
('Tampa Southwest','149'),
('Tampa Northwest','150'),
('Tampa Central','151'),
('Sarasota/Bradenton','189'),
('Tri-Valleys','210'),
('Columbus Ohio','249'),
('Kansas City','270'),
('Charlotte V','369'),
('Columbia I','391'),
('Columbia II','392'),
('Richmond South','393'),
('Richmond North','394'),
('Eastern N Carolina I','409'),
('Eastern N Carolina 2','410'),
('Houston Northwest','429'),
('Houston Southwest','430'),
('Austin North','431'),
('Austin South','432'),
('San Antonio West','433'),
('San Antonio East','434'),
('Western N. Carolina','449'),
('Inland Empire','470'),
('LA County South','471'),
('San Diego Co.','472'),
('Memphis 2','509'),
('Jacksonville Central','569'),
('Jacksonville North','570'),
('Jacksonville South','571'),
('Central Arkansas','629'),
('Southern Virginia 1','709'),
('Southern Virginia 2','710'),
('Jackson','729'),
('Pittsburgh North','749'),
('Pittsburgh South','750'),
('Raleigh Durham 1','769'),
('Raleigh Durham 2','770'),
('Raleigh Durham 3','771'),
('Raleigh Durham 4','772'),
('Asheville','789'),
('Cleveland','890'),
('New Jersey Central','1049'),
('Denver Southeast','1070'),
('Colorado Springs','1071'),
('Upstate North','1089'),
('Upstate South','1090'),
('DFW Fort Worth','1129'),
('Upstate Central','1149'),
('Idaho','1189'),
('Eastern NC 3','1229'),
('DFW Irving','1249'),
('DFW Fort Worth South','1250'),
('Birmingham North','1269'),
('Birmingham South','1272'),
('Gulf Coast East','1273'),
('Gulf Coast West','1274'),
('Eastern Pennsylvania','1289'),
('Philadelphia','1290'),
('Cincinnati South','1291'),
('Northern WV','1292'),
('Cincinnati North','1293'),
('NE Philadelphia','1294'),
('Northwest Arkansas','1309'),
('Southwest Missouri','1310'),
('Lexington','1311'),
('Oklahoma City North','1329'),
('Oklahoma City South','1330'),
('Houston Northeast','1349'),
('LA Valley','1370'),
('Knoxville East','1390'),
('Knoxville West','1391'),
('I-75 South Georgia','1393'),
('Chicago South','1449'),
('Memphis 3','1469'),
('West Tennessee','1470'),
('Triad Central','1489'),
('Minnesota','1569'),
('Orange County South','1589'),
('Orange County North','1590'),
('Baltimore Northwest','1609'),
('Baltimore Northeast','1610'),
('Baltimore Southwest','1611'),
('Baltimore Southeast','1612'),
('Colorado North','1649'),
('Auburn','1669'),
('Dothan','1670'),
('Montgomery','1671'),
('Utah Central','1689'),
('Utah South','1695'),
('Utah North','1696'),
('Bay Area','1709'),
('Sacramento','1710'),
('Chicago Central','1730'),
('Chicago West','1770'),
('Chicago North','1771'),
('Wisconsin','1829'),
('Charleston I','1849'),
('Nashville East','1869'),
('Nashville North','1870'),
('Nashville South','1871'),
('LA City','1893'),
('LA Westside','1894'),
('Ventura','1895'),
('Denver West','1896'),
('Northern New Mexico','1898'),
('New Orleans N Shore','1912'),
('New Orleans S Shore','1913'),
('Houston South','1914'),
('DFW-Arlington','1915'),
('DFW Frisco','1916'),
('DFW Midcities North','1917'),
('DFW Midcities South','1918'),
('DFW McKinney','1919'),
('Northeast Mississipp','1920'),
('Tuscaloosa','1921'),
('OklahomaCity Central','1922'),
('DC Southwest','1929'),
('Loudoun County','1930'),
('MD South','1933'),
('DC West','1934'),
('DC North','1935'),
('Fairfax','1936'),
('Delaware North','1949'),
('Delmarva','1950'),
('Portland','1969'),
('Orange County East','2009'),
('Arizona West','2010'),
('Arizona Central','2011'),
('Arizona East','2029'),
('Arizona South','2030'),
('DFW Dallas/Plano N','2031'),
('DFW Dallas/Plano S','2032'),
('New Jersey Shore','2049'),
('Toledo','2069'),
('Puget Sound','2109'),
('Manhattan','2129'),
('Long Island','2130'),
('Nevada South','2149'),
('Silicon Valley','2150'),
('New England East','2169'),
('New England West','2170'),
('North GA Mountains','2191'),
('Youngstown Ohio','2209'),
('Central Kansas','2210'),
('Des Moines','2212'),
('Central Illinois','2213'),
('Eastern Iowa','2229'),
('South West Texas','2290'),
('South Florida 3','2310'),
('South Florida 2','2330'),
('South Florida 1','2331'),
('San Antonio Central','2349'),
('Central VA East','2370'),
('West Kentucky','2411'),
('Montana Northwest','2429'),
('Midland','2449'),
('Laredo','2451'),
('Orlando West','2469'),
('Orlando East','2470'),
('ATL-285 South','2471'),
('Dakotas','2489'),
('Upstate New York','2529'),
('Sacramento East','2609'),
('Sacramento West','2610'),
('Lower Sabine','2629'),
('Greater Hartford','2669'),
('Connecticut South','2670'),
('Greater Boston','2671'),
('Greater Providence','2672'),
('SAT Central 1','2673'),
('SAT Central 2','2674'),
('Denver Central','2749'),
('MBM - LEW','25698'),
('MBM - MCN','25700'),
('MBM - DEN','86581'),
('QCD SVCS','184774'),
('QCD - PIN','211196'),
('QCD - SUF','211197'),
('QCD - APO','219863'),
('MBM - ELKHORN','251594'),
('MAINES PAPER & FOOD SERVICE INC','280197'),
('MBM CORPORATION','21586'),
('MARTIN BROWER COMPANY','306215'),
('FOOD AUTHORITY SOUTH','307734'),
('FOOD AUTHORITY OF MASSACHUSETTS LLC','307754'),
('MBM - RIV','315098'),
('MBM - SUM','319458'),
('MAINES - ABD','333662'),
('MBM - LOC','344187'),
('MBM - SHA','347807'),
('QCD - PHX','348389'),
('MARTIN BROWER - ATL','348909'),
('MBM - MEM','350168'),
('MARTIN BROWER - BTR','350169'),
('MARTIN BROWER - LTR','350170'),
('MARTIN BROWER - SJO','350428'),
('MBM - HOU','350429'),
('QCD - DEN','350430'),
('DH','DH'),
('DWH','DWH'),
('MALL','MALL'),
('SAT','SAT')

-- **** 


Declare @Zone VARCHAR(50), @extref VARCHAR(50)
-- declare a cursor
DECLARE sample_cursor CURSOR FOR 
SELECT Zone,ExtRef from #tmpTable

-- open cursor and fetch first row into variables
OPEN sample_cursor
FETCH NEXT FROM sample_cursor into @Zone,@extref

-- check for a new row
WHILE @@FETCH_STATUS=0
BEGIN
-- do complex operation here
PRINT 'Zone: ' + @Zone + ' Ext Ref: ' + @extref

update tbZone set ZoneExtRef = @extref where Zone = @Zone 

-- get next available row into variables
FETCH NEXT FROM sample_cursor into @Zone,@extref 
END
close sample_cursor
Deallocate sample_cursor

DROP TABLE #tmpTable

--select * from tbZone 