public async Task <IActionResult> PutSQLquery([FromRoute] int id, [FromBody] SQLquery sQLquery) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (id != sQLquery.Query_ID) { return(BadRequest()); } _context.Entry(sQLquery).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!SQLqueryExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> Puttable([FromRoute] int id, [FromBody] table table) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (id != table.Table_Id) { return(BadRequest()); } _context.Entry(table).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!tableExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutDatabase_Info([FromRoute] int id, [FromBody] db database_Info) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (id != database_Info.database_id) { return(BadRequest()); } _context.Entry(database_Info).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!Database_InfoExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutstgSAPPurgeTableList([FromRoute] int id, [FromBody] stgSAPPurgeTableList stgSAPPurgeTableList) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (id != stgSAPPurgeTableList.TableID) { return(BadRequest()); } _context.Entry(stgSAPPurgeTableList).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!stgSAPPurgeTableListExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutArchivalreq([FromRoute] int id, [FromBody] Archivalreq archivalreq) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (id != archivalreq.Request_ID) { return(BadRequest()); } _context.Entry(archivalreq).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ArchivalreqExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }