Note that there are some explanatory texts on larger screens.

plurals
  1. PODatabase contents setting themselves to 0
    text
    copied!<p>I have a Database that contains 4 tables, however I'm using 1 of them which is separated from the others. </p> <p>In this table I have 4 fields which are varchar and the rest are ints (11 other fields), when the users fill up the DB everything gets saved correctly, however it has happened 3 times so far that the database values for the int's reset to 0 without any apparent reason. At first, I thought, it was because those fields (where the numbers should go) were varchars not ints. However since I changed it, it happened again. I've already double checked my code and I have nothing that even updates or inserts a 0 value. Also I'm using codeigniter and active records which protect against SQL injections AND have XSS filtering enabled, could anyone point out something I might be missing or a reason for this to be happening?</p> <p>Also, I'm pretty sure about the answer of this but, is there ANY way to recover some data?? Other than having to ask everyone to fill in everything again.. =/</p> <p>** EDIT **</p> <p>The Storage Engine is MyISAM and Collation is latin1_swedish_ci, Pack Keys are default, for all intents and purposes it's a normal DB</p> <p>** EDIT **</p> <p>Here's my Table Structure</p> <pre><code>-- phpMyAdmin SQL Dump -- version 3.3.5 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Feb 10, 2011 at 09:31 AM -- Server version: 5.0.51 -- PHP Version: 5.2.14 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; -- -- Database: `cinesdec_prueba` -- -- -------------------------------------------------------- -- -- Table structure for table `Oscar` -- CREATE TABLE IF NOT EXISTS `Oscar` ( `Id` int(20) NOT NULL auto_increment, `Nombre` varchar(100) default NULL, `ApPaterno` varchar(100) default NULL, `ApMaterno` varchar(100) default NULL, `Edad` varchar(25) default NULL, `Twitter` varchar(250) default NULL, `Correo` varchar(250) NOT NULL default '', `BestPicture` int(10) unsigned NOT NULL, `ActorLead` int(10) unsigned NOT NULL, `ActorSupport` int(10) unsigned NOT NULL, `ActressLead` int(10) unsigned NOT NULL, `ActressSupport` int(10) unsigned NOT NULL, `Art` int(10) unsigned NOT NULL, `Directing` int(10) unsigned NOT NULL, `Foreing` int(10) unsigned NOT NULL, `Music` int(10) unsigned NOT NULL, `Visual` int(10) unsigned NOT NULL, `Desempate` int(10) unsigned NOT NULL, PRIMARY KEY (`Correo`), UNIQUE KEY `Id` (`Id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=89 ; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload