ElkArte Community

Elk Development => Bug Reports => Exterminated Bugs => Topic started by: kucing on November 04, 2017, 02:39:58 am

Title: Guest cannot register
Post by: kucing on November 04, 2017, 02:39:58 am
Hi, anyone can help me? Using Elk 1.1

When trying to register or opening existing member profile it will failed:
Code: [Select]
    Type of error: Database
    Database Error: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'rows, cols
    FROM elk_custom_fields
    WHERE active = 1 AND show_reg != 0
    OR' at line 3
what should i do to fix it?
Title: Re: Guest cannot register
Post by: emanuele on November 04, 2017, 08:56:20 am
I think the query is the one in Profile.subs.php at line 185.
Would you mind either put here the query or attach the whole file?
Title: Re: Guest cannot register
Post by: Spuds on November 04, 2017, 11:45:50 am
I wonder if its due to MariaDB and the use of the column name "rows"
Title: Re: Guest cannot register
Post by: kucing on November 04, 2017, 06:16:17 pm
thanks. attached the file.

my setup for this forum:
    256 MB NAT VPS (only using IPv6, no IPv4)
    Ubuntu 14.04
    Hiawatha Web Server 10.6
    PHP 7.0.23
    MariaDB 10.2.8

-

maybe not related. after recognizing a problem with the forum. i checked the admin and see the addons (i want to disable all first for troubleshooting). but on package>browse / installed. it says that none of my addons installed.  and i don't know why all saying [emulating 1.0].

Title: Re: Guest cannot register
Post by: emanuele on November 05, 2017, 03:09:04 pm
Yep, looks like Spuds idea is the right one.
@kucing would you mind trying to replace:
Code: [Select]
, rows, cols
with:
Code: [Select]
, "rows", cols
in both Profile.subs.php and ManageFeatures.subs.php?
Title: Re: Guest cannot register
Post by: kucing on November 06, 2017, 12:11:53 am
thanks! fixed.
Title: Re: Guest cannot register
Post by: Spuds on November 06, 2017, 09:24:34 am
add to 1.1.1 as well ?
Title: Re: Guest cannot register
Post by: emanuele on November 06, 2017, 12:17:38 pm
Yep, the report is for 1.1, I'm not sure if it affects 1.0 as well.
Title: Re: Guest cannot register
Post by: live627 on November 07, 2017, 01:21:46 am
I think MySQL needs to be in ANSI mode. Haven't checked for sure, though.
Title: Re: Guest cannot register
Post by: emanuele on November 07, 2017, 02:15:52 am
Seems like that @live627 I'd go with the fully qualified, that should make everyone happy, YAY! :D (Hopefully :P)