Web Analytics Made Easy -
StatCounter Something strange in database field selection - CodingForum

Announcement

Collapse
No announcement yet.

Something strange in database field selection

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Something strange in database field selection

    Trying to use the following code:
    Code:
    $resultTheology = mysql_query('SELECT Theology,TheologyCode FROM theology');
    But it keeps failing to pull the data. The table name and fields are correct.
    Out of curiousity I switched the query to read:
    Code:
    $resultTheology = mysql_query('SELECT * FROM theology');
    Now data is being pulled.

    I've re-typed the code several times and restarted my code editting tool.
    I'm not receiving any PHP errors. But Firefox plugin, Firebug: is revealing the following error. "missing ] after element list"
    But the source code shows different.
    Code:
    var empsTheology = [
    		['Please Choose One',''],['Bible','BIBL'],['Christian Ethics Moral Theology','CEMT'],['Church History Historical Theology','CHHT'],['Homiletics','HOML'],['Liturgics and Church Music','LTCM'],['Ministry Theory and Practice','MNST'],['Spirituality','SPRT'],['Theology Systematic','THEO'],['IE shows all and won't edit','IE'],['TEST','TEST'],['re-install Edit button leave out auto select','TODO'],['course added','ADD']	];
    Does this type of error usually mean a corrupt database table?

  • #2
    The problem was a corrupt database table.
    Had to rebuild the table to correct the problem.
    Everything works now.

    Comment

    Working...
    X