public void addRealStates(RealStates entity) { string query = $"INSERT INTO [dbo].[RealStates] ([Id] ,[RegistrationNumber] ,[Address] ,[Price] ,[Independency] ,[TypeId]) VALUES ({entity.Id},{entity.RegistrationNumber},'{entity.Address}',{entity.Price},{entity.Independency},{entity.TypeId})"; executeQuery(query); }
public void updateRealStates(RealStates entity) { string query = $"UPDATE [dbo].[RealStates] SET [Id] = {entity.Id} ,[RegistrationNumber] = {entity.RegistrationNumber} ,[Address] = '{entity.Address}',[Price] = {entity.Price},[Independency] = {entity.Independency} ,[TypeId] = {entity.TypeId} WHERE Id = {entity.Id}"; executeQuery(query); }