We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 24969
    • 120 Posts
    « MODx Parse Error »
    MODx encountered the following error while attempting to parse the requested resource:
    « Execution of a query to the database failed - Table 'chry7248_chryshfn.tblfaq' doesn't exist »
          SQL: INSERT INTO tblfaq (Question,Answer) VALUES('test','test')
          [Copy SQL to ClipBoard]
     
    Parser timing
      MySQL: 	0.0091 s	(13 Requests)
      PHP: 	0.0727 s	 
      Total: 	0.0818 s

    For my insert record...
    snippet looks like this;
    <?php
    function faq( &$fields )
    
          {
    
          global $modx;
    
          // Init our array
    
          $dbTable = array();
    
          $dbTable[Question] = $fields[Question];
    
          $dbTable[Answer] = $fields[Answer];
          // Run the db insert query
    
          $dbQuery = $modx->db->insert($dbTable, 'tblfaq' );
    
          return true;
    
          }
    ?>


    What am I doing wrong?
      The important thing is not to stop questioning. Curiosity has its own reason for existing. One cannot help but be in awe when he contemplates the mysteries of eternity, of life, of the marvelous structure of reality. It is enough if one tries merely to comprehend a little of this mystery every day. Never lose a holy curiosity.

      -Albert Einstein (1879 - 1955)

      Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8e-fips-rhel5 DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635
      • 16251
      • 24 Posts
      "Table ’chry7248_chryshfn.tblfaq’ doesn’t exist"

      Create the table...
        • 24969
        • 120 Posts
        my bad thanks for the reply... duh
          The important thing is not to stop questioning. Curiosity has its own reason for existing. One cannot help but be in awe when he contemplates the mysteries of eternity, of life, of the marvelous structure of reality. It is enough if one tries merely to comprehend a little of this mystery every day. Never lose a holy curiosity.

          -Albert Einstein (1879 - 1955)

          Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8e-fips-rhel5 DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635