SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Guru afridy's Avatar
    Join Date
    Mar 2007
    Posts
    960
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Strange Column count doesn't match value count at row 1 problem

    Folks

    strange, strange. This error 'Column count doesn't match value count at row 1 problem' killing me. already wasted hours in this.
    what could be the problem?

    Code:
    	$query = "INSERT into dph_ot_forecast VALUES (
    			'',
    			'$empno',
    			'$_shift'
    			'$dep_id',
    			'$sec_id',
    			'$pos_id',
    			'$start',
    			'$end',
    			'$tot_hrs',
    			'$justification',
    			'$date'
    			)"; 
        if ($result=mysql_query($query) or die (mysql_error()));
    Table structure
    screenshot.jpg


  2. #2
    SitePoint Guru afridy's Avatar
    Join Date
    Mar 2007
    Posts
    960
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    found the culprit after hours of search.

    Code:
    '$_shift'
    here a comma is missing


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •