MOD 2.0 Error - SQL ERROR

Forum dedicato allo script per i tornei e ladder di videogames PHP Rivals mod.
Form about phpRivals Mod script.

MOD 2.0 Error - SQL ERROR

Messaggioda Super64 » 07/02/2012, 0:50

I was doing some more testing last night. I was logged in as Super64 which owns a clan called Rusty in Places (id 1). I accidently created another clan with that user, so I deleted the clan in the ACP. But now, none of the clans work.

Clan List:
http://www.wararrangers.com/rivals.php?action=clan_full

Clicking on a clan causes:
Codice: Seleziona tutto

General Error
SQL ERROR [ mysqli ]
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 [1064]
An SQL error occurred while fetching this page   
 
   
SQL 
SELECT * FROM phpbb_users WHERE user_id =   
BACKTRACE 

FILE: includes/db/mysqli.php
LINE: 163
CALL: dbal->sql_error() 
FILE: rivals/group_profile.php
LINE: 36
CALL: dbal_mysqli->sql_query() 
FILE: rivals.php
LINE: 42
CALL: include('rivals/group_profile.php') 
Immagine
Immagine
http://www.youtube.com/user/ldoddrell
Avatar utente
Super64
Donors
 
Messaggi: 38
Iscritto il: 22/06/2011, 12:55
Numero MVP totali: Nessuno

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Dutch_com_freak » 10/02/2012, 18:03

did you upgrade from 1.3? btw what phpbb3 version are you using?

Dutch_com_freak
Donors
 
Messaggi: 171
Iscritto il: 29/12/2010, 21:10
Numero MVP totali: Nessuno

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Super64 » 10/02/2012, 21:34

Latest phpBB and it's a fresh install of 2.0.
Immagine
Immagine
http://www.youtube.com/user/ldoddrell
Avatar utente
Super64
Donors
 
Messaggi: 38
Iscritto il: 22/06/2011, 12:55
Numero MVP totali: Nessuno

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Dutch_com_freak » 10/02/2012, 23:50

i'm having some issue's after the new update too.... maybe it's the update

Dutch_com_freak
Donors
 
Messaggi: 171
Iscritto il: 29/12/2010, 21:10
Numero MVP totali: Nessuno

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Soshen » 12/02/2012, 1:20

I will check soon..

I've upgraded all system (maybe you notice that :P) in these days so i was a bit busy.
Vedi le mie collezioni
Avatar utente
Soshen
Site Admin
 
Messaggi: 1357
Iscritto il: 09/07/2010, 23:54
Nazionalità: Italy (it)
Numero MVP totali: 4
Gamername: Soshen

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Super64 » 15/02/2012, 19:02

An update...

Any clan created before this problem happened, doesn't work. Any clan created after, does work. Very odd.
Immagine
Immagine
http://www.youtube.com/user/ldoddrell
Avatar utente
Super64
Donors
 
Messaggi: 38
Iscritto il: 22/06/2011, 12:55
Numero MVP totali: Nessuno

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Soshen » 17/02/2012, 9:55

Can you explain me more?
Vedi le mie collezioni
Avatar utente
Soshen
Site Admin
 
Messaggi: 1357
Iscritto il: 09/07/2010, 23:54
Nazionalità: Italy (it)
Numero MVP totali: 4
Gamername: Soshen

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Super64 » 17/02/2012, 11:33

I was logged in as the user 'Super64'
I already have a clan created with the user 'Super64' called 'Rusty in Places'
I created a second clan with the user Super64 called 'Cerberus'
In ACP, I deleted the 'Cerberus' clan (because I realised I was not logged in as 'Super64b' to create the Cerberus clan)
Now when clicking on the name/link for a clan, any clan that was created before I made my mistake... shows the error:
Codice: Seleziona tutto
General Error
SQL ERROR [ mysqli ]
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 [1064]
An SQL error occurred while fetching this page   
 
   
SQL 
SELECT * FROM phpbb_users WHERE user_id =   
BACKTRACE 

FILE: includes/db/mysqli.php
LINE: 163
CALL: dbal->sql_error() 
FILE: rivals/group_profile.php
LINE: 36
CALL: dbal_mysqli->sql_query() 
FILE: rivals.php
LINE: 42
CALL: include('rivals/group_profile.php')

Any clan created after my mistake displays the clan profile correctly with no errors.

So two issues:

1) I need to fix the clans that we made before my mistake so they display properly
2) We should limit the user to one clan only...

A) A user can create one clan only
B) If they are a member of a clan they did not create, they have to leave the clan before joining another clan
C) If they created the clan, they have to move ownership of the clan to another member, but if they are the only member of the clan then they must delete the clan
Immagine
Immagine
http://www.youtube.com/user/ldoddrell
Avatar utente
Super64
Donors
 
Messaggi: 38
Iscritto il: 22/06/2011, 12:55
Numero MVP totali: Nessuno

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Soshen » 17/02/2012, 17:34

It's was a my f*k keyword error i wrote to delete the clan user link value that isn't (and not is) the one that we delete lol

For fix old clan you must read the USER CLAN link at least the founder manually, sorry.

here the fix
acp_rivals_edit_groups.php
(18.67 KiB) Scaricato 140 volte
Vedi le mie collezioni
Avatar utente
Soshen
Site Admin
 
Messaggi: 1357
Iscritto il: 09/07/2010, 23:54
Nazionalità: Italy (it)
Numero MVP totali: 4
Gamername: Soshen

Re: MOD 2.0 Error - SQL ERROR

Messaggioda Super64 » 17/02/2012, 18:46

Thank you for the fixed file. But I don't understand what you mean by:
"For fix old clan you must read the USER CLAN link at least the founder manually, sorry."
Immagine
Immagine
http://www.youtube.com/user/ldoddrell
Avatar utente
Super64
Donors
 
Messaggi: 38
Iscritto il: 22/06/2011, 12:55
Numero MVP totali: Nessuno

Prossimo

Torna a phpRivals Mod

Chi c’è in linea

Visitano il forum: Nessuno e 1 ospite

cron