Radio Streaming - 50% Lifetime Discount with purchase of any Joomla Web Radio Addon. Discount Code: STR15-Z
See Radio Streaming Plans

Results 1 to 6 of 6

Thread: Championship error

  1. #1

    Championship error

    Hi,

    Just setting up championship as now have 16 players but have got the following error message :-

    An error has occurred.
    1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1 SQL=INSERT INTO `#__masterleaguepro_minileague_users` (user_id,minileague_id,group_id,season_points,seas on_goal_difference) VALUES (418,2,2,0,)

    Any help would be great, regards, Steve

  2. #2
    Hi,

    Think the problem was because some of the players didn't have any points, after this weeks game result entered, the Championship was able to be created.

  3. #3
    Administrator
    Join Date
    Jul 2015
    Posts
    65
    Hello,

    This issue will be resolved in the next available version , but you can fix it on your own
    file : <joomla directory>/administrator/components/com_masterleaguepro/models/multileague.php

    add to the function insertUserToGroup (should be at line 346)

    FROM:

    Code:
    public function insertUserToGroup($user,$league,$group,$points,$goal_difference){
            $query=$this->db->getQuery(true);
            $query="INSERT INTO `#__masterleaguepro_minileague_users` (user_id,minileague_id,group_id,season_points,season_goal_difference) VALUES (".$user.",".$league.",".$group.",".$points.",".$goal_difference.")";
            $this->db->setQuery($query);
    
    
            return $this->db->query();
        }
    TO:


    Code:
    public function insertUserToGroup($user,$league,$group,$points,$goal_difference){
            if($goal_difference==""){
                $goal_difference=0;
            }
            $query=$this->db->getQuery(true);
            $query="INSERT INTO `#__masterleaguepro_minileague_users` (user_id,minileague_id,group_id,season_points,season_goal_difference) VALUES (".$user.",".$league.",".$group.",".$points.",".$goal_difference.")";
            $this->db->setQuery($query);
    
    
            return $this->db->query();
        }

  4. #4
    Thanks for the reply.
    i have looked but cannot seems to see multileague.php in folder models.

    regards

  5. #5
    Administrator
    Join Date
    Jul 2015
    Posts
    65
    Hello,
    make sure you look for multileague.php into the administrator part of the component

    Best Regards

  6. #6
    My bad, many thanks

Posting Permissions

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