Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I have a table named SUPPLIER that is set up like this SUPPLIER(SupplierName(PK)

ID: 3767839 • Letter: I

Question

I have a table named SUPPLIER that is set up like this

SUPPLIER(SupplierName(PK), ContactName, Notes, PhoneNumber, Email).

This table is already populated with records and we had to add a city and state column so now the table looks like this

SUPPLIER(SupplierName(PK), ContactName, Notes, PhoneNumber, Email, city, state).

My question is how can I add the city and state data to this table with one statement instead of multiple INSERT WHERE statements. Currently all city and states are null and I need to add the given city and state data.

Thank you,

Brad

Explanation / Answer

This would add the columns city and state:-

ALTER TABLE SUPPLIER

ADD (city varchar2(45),

state varchar2(45));

To populate it with data with single insert statement:-

INSERT INTO SUPPLIER(city,state)VALUES

('City1', 'state1'),('city2','state2'),('city3','state3')...;

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote