I Have a table with 4 columns ID Name Address and Phone. I want to be able to edit each cell and have it change in the database. So far I have it coded to change the Name side and it works. I have some experience with programming but not a lot. The script I have is
print event.row, event.column, event.newValue
data = event.source.data
id = data.getValueAt(event.source.selectedRow, 0)
name = event.newValue
system.db.runPrepStmt(“UPDATE Customers SET Name = ? WHERE ID = ?”, [name, id])
How can I make it so I can edit the address and phone side and have it update in the database? I have tried a couple ways but it ends up changing the name in the row as well.