SET IDENTITY_INSERT [dbo].[store] ON; Select * from store where store_id = 317; if @@ROWCOUNT =0 BEGIN INSERT INTO store ( Store_ID, Description, CompanyName, TradingAs, Address, ContactNo, VATRegNo, RegNo, StoreEmailAddress ) VALUES ('317', 'Cash Crusaders President Square New','Cash Crusaders Stores (Pty) Ltd','Cash Crusaders President Square New','Shop 6 President Square, Playfair Boulevard, Powerville Extension, 1939','0877111599','4270290184','2020/027120/07',''); END ELSE BEGIN UPDATE Store set Description = 'Cash Crusaders President Square New',CompanyName = 'Cash Crusaders Stores (Pty) Ltd', TradingAs = 'Cash Crusaders President Square New', Address='Shop 113 Rustenburg Mall, Nelson Mandela Drive, Swartruggens road, Rustenburg', ContactNo = '0877111599', VATRegNo = '4270290184',RegNo = '2020/027120/07', StoreEmailAddress = '' where Store_ID = 317; END SET IDENTITY_INSERT [dbo].[store] off