//------------------- UPDATE ------------------------------- /* * Overwrites a row with the input given */ public async Task UpdateStepperResponse(Label_Stepper stepper) { if (stepper != null) { await db.QueryAsync <Label_Stepper>("UPDATE [StepperLabels] SET Value = ? WHERE CPQID = ? AND QID = ?", stepper.Value, stepper.CPQID, stepper.QID); Console.WriteLine("\n CPQID:" + stepper.CPQID + "\n StepperID: " + stepper.QID + "\n StepperText: " + stepper.Label + "\n StepperValue: " + stepper.Value); } else { Console.WriteLine("\n STEPPER null"); } }
//------------------- DELETE -------------------------------- /* * Deletes a specific row in a specific table * */ public async Task DeleteStepperResponse(Label_Stepper stepper) { await db.QueryAsync <Label_Stepper>("DELETE FROM [StepperLabels] WHERE CPQID = ? AND QID = ?", stepper.CPQID, stepper.QID); }
public async Task AppendStepperResponse(Label_Stepper stepper) { await db.InsertAsync(stepper); }