I have a popup window that collectes a bunch of values from the user to update an SQL table. I have the following code statement to insert a new record into the table:
if ID == None:
fpmi.db.runPrepStmt("insert into ProdAlerts.dbo.tblPOVCIP (ProcessID,Operator,CIPDate,Protocol,Vessel,Comments,Type,Sprayhead,PSI,Sanitizer,Sprayhead2,PSI2) values (?,?,?,?,?,?,?,?,?,?,?,?)",[proc,initials,date,protocol,tank,notes,mytype,sphd1,psi1,sani,sphd2,psi2])
The problem is that I get the following error:
Gateway Error 301:
SQL Error: Data Truncation
For Query:insertinto ProdAlerts.dbo.tblPOVCIP(ProcessID,Operator,CIPDate,Protocol,Vessel,Comments,Type,Sprayhead,PSI,Sanitizer,Sprayhead2,PSI2) values (?,?,?,?,?,?,?,?,?,?,?,?)
The real weird thing is that I copied this popup window from an existing one that updates the same table. Inside that other popup window code, I run this exact command and it works fine. I have checked the variables that are being entered, and they are all valid.
Any idea why I get this error pop up?