• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

New here, Website error

DannyDaniel

New Member
Joined
Sep 27, 2024
Messages
6
Reaction score
0
Hello everyone, This is my first post hopefully in the right place.
I was following step by step TFS 1.4 official release | OTS Guide (https://docs.otland.net/ots-guide/tfs-documentation/tfs-1.4) to open my LAN server to start working on my new project.
I opened made the website and in step "setting up your first server" i pressed on create account and put my info there and it just showed me this and im not sure how to fix it, any ideas?
HTML:
string(92) "SELECT `id`, `name`, `password`, `email`, `premdays` FROM `accounts` WHERE `id` = 1 LIMIT 1;"
(query - SQL error)
Type: select_single (select single row from database)

Unknown column 'premdays' in 'field list'

again sorry if I put this at the wrong place
 
Just go to your database in SQL and run this.

SQL:
 ALTER TABLE `accounts` ADD COLUMN `premdays` INT(11) NOT NULL DEFAULT 0;

This is not the correct solution, as the server will still use the other column.

The correct solution would be to adjust ZnoteAAC to use the other column, which the server uses (prem_ends_at maybe, or I don't know?).

I would suggest to switch to something more reliable, like MyAAC, or you will face similar problems in the future, as Znote hasn't been updated in a while.
 
Just go to your database in SQL and run this.

SQL:
 ALTER TABLE `accounts` ADD COLUMN `premdays` INT(11) NOT NULL DEFAULT 0;
Tried it and it did nothing, Thank you for trying to help me tho
Post automatically merged:

This is not the correct solution, as the server will still use the other column.

The correct solution would be to adjust ZnoteAAC to use the other column, which the server uses (prem_ends_at maybe, or I don't know?).

I would suggest to switch to something more reliable, like MyAAC, or you will face similar problems in the future, as Znote hasn't been updated in a while.
Umm the thing is I followed the link that I mentioned above, is there something where I can follow? like a guide? I'm new here just starting
 
I sent the wrong SQL... here's the correct one now, sorry about that.
SQL:
ALTER TABLE accounts ADD premdays int(11) NOT NULL default 0;

prem_ends_at
But the error says it wasn't found or is unknown, and it's referring to 'premdays.' If it were 'prem_ends_at,' then it would display differently. But he's using an old TFS source that doesn't have 'prem_ends_at'.
 
Adding premdays column to accounts table should fix that error.

Are you sure you are using TFS 1.4+?
Are you sure you have set server version to $config['ServerEngine'] = 'TFS_10'; in config.php of acc. maker? ( ZnoteAAC/config.php at master · Znote/ZnoteAAC (https://github.com/Znote/ZnoteAAC/blob/master/config.php#L17) )

Tutorial ( Setting up your first server | OTS Guide (https://docs.otland.net/ots-guide/running-your-first-ot-server/setting-up-your-first-server) ) points to:
Code:
You will need a set of files before you can run your server. The files can be found [URL='https://github.com/otland/forgottenserver/releases/tag/v1.2']here[/URL].
and here is link to https://github.com/otland/forgottenserver/releases/tag/v1.2 which is 8 years old version.

Last released TFS version is 1.6, its for some 13+ Tibia version:

If you want to use 10.x client/OTClient, last version for Tibia 10.x is TFS 1.4 for 10.98:
 
I sent the wrong SQL... here's the correct one now, sorry about that.
SQL:
ALTER TABLE accounts ADD premdays int(11) NOT NULL default 0;


But the error says it wasn't found or is unknown, and it's referring to 'premdays.' If it were 'prem_ends_at,' then it would display differently. But he's using an old TFS source that doesn't have 'prem_ends_at'.

I don't know what server he uses, but if there was not "premdays" column at the beginning (while importing schema.sql), then that means the server uses different column. What you do is just silencing the error on Znote side.

TLDR;

It will display wrong premium time on the Znote website!

Adding premdays column to accounts table should fix that error.

As I said, it will just silent the error. But the consequences of this are, that the wrong premium time will be displayed, as server uses different column.
 
usualy few changes in database must be done in gesior account maker, try myacc it should install without some required changes
 
usualy few changes in database must be done in gesior account maker, try myacc it should install without some required changes
Gesior2012 requires same version of TFS and acc. maker (there are GitHub branches for each TFS version).
ZnoteAAC and MyAAC accept all TFS 1.0+ as 'TFS'.
But this error with Type: select_single (select single row from database) is not from Gesior2012. Gesior2012 uses PDO MySQL connection, not mysql/mysqli PHP extension (which has function select_single).
if there was not "premdays" column at the beginning (while importing schema.sql), then that means the server uses different column.
If you set ZnoteAAC config.php to other value than TFS_10, it will always load premdays. If you set it to TFS_10 it will detect, if given TFS use premdays or prem_ends_at ( ZnoteAAC/engine/init.php at 70a39d4cc7d0618698504c110ef802c2dcd31b29 · Znote/ZnoteAAC (https://github.com/Znote/ZnoteAAC/blob/70a39d4cc7d0618698504c110ef802c2dcd31b29/engine/init.php#L55-L69) ).
 
ok that make sense. 1 more question, So I have no clue which TFS I should use. Is TFS like depend on which client I want to use? if no whats the difference between all of them, and which tfs is the best to use or u recommended i should use
Or should I make a whole post about it somewhere else?
 
Last edited:
I don't know what server he uses, but if there was not "premdays" column at the beginning (while importing schema.sql), then that means the server uses different column. What you do is just silencing the error on Znote side.
I know, my friend. Once, I downloaded a server that was OTG 11x, and I noticed its premium system was 'premdays,' implemented in the source. However, OTG is based on TFS 1.3, which is very old. So, I uninstalled everything and implemented the new 'prem_ends_at' function, and it's working great. The guy didn’t mention anything about using OTX or an old version of TFS, etc. He should provide information about the TFS or OTX version to understand better.
 
Back
Top