G
Guest
If I have a table sample shown below, how can I update the State values if
Null, to the State value of the closest record above it that isn't null. For
example, I want the state for ID 3 and 4 to be populated with "CA". Also I
would want the state for ID 6 to be populated with "IL". (Purpose: I created
a table from importing a text document that had this format. But I can not
run the queries I need with out all the States being populated, since I need
to join by State to get the results I need)
ID State City
1 NY New York City
2 CA Los Angelas
3 San Diego
4 Sacramento
5 IL Chicago
6 Peoria
Null, to the State value of the closest record above it that isn't null. For
example, I want the state for ID 3 and 4 to be populated with "CA". Also I
would want the state for ID 6 to be populated with "IL". (Purpose: I created
a table from importing a text document that had this format. But I can not
run the queries I need with out all the States being populated, since I need
to join by State to get the results I need)
ID State City
1 NY New York City
2 CA Los Angelas
3 San Diego
4 Sacramento
5 IL Chicago
6 Peoria