Geo-targeting Project [11-25]
Before we start calculating the distance between the store and the customer's address, let's check if there are any missing coordinates in the SALES_Q1_LOC_POS table.
where store_x = . or
store_y = . or
cust_x = . or
cust_y = .;
keep customer_postcode store_postcode store_x store_y cust_x cust_y;
Did the code fail because the input data sets don't exist?
Copy and run the code below to create the input data sets.
The data step above checks if there are any missing coordinates.
It turns out there are more than 9000 records that are missing the CUST_X and CUST_Y coordinates.
Can you figure out why these coordinates are missing?