Jump to content

Advertisments PROBLEM !


4KIST

Recommended Posts

Evening Everyone, I'm asking for a great help with the problem with ads on the Roleplay OWL server! What do I have to do and what to do in the database?

ERROR: advertisements\advertisements.lua:117: call: failed to call 'mysql:select' [string "?"]
 ERROR: advertisements\advertisements.lua:117: bad argument #1 to 'ipairs' (table expected, got boolean)

this ad structure is good to the database is from the OWL gamemode?

CREATE TABLE `advertisements` (
  `id` int(11) NOT NULL,
  `phone` varchar(10) NOT NULL,
  `name` varchar(50) NOT NULL,
  `address` varchar(100) NOT NULL,
  `advertisement` text NOT NULL,
  `start` int(11) NOT NULL,
  `expiry` int(11) NOT NULL,
  `created_by` int(11) NOT NULL,
  `section` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

and please nice can you give me a good ad resource and structure to go on the server!
Thank you for your support!

 

Edited by 4KIST
Link to comment
12 hours ago, Sorata_Kanda said:

Either way you don't have a connection to your MySQL database or the table/entry does not exist.

Use /debugdb and check the MySQL logs for detailed error messages.


[2019-01-26 12:39:09] ERROR: [Server]\advertisements\advertisements.lua:94: call: failed to call 'mysql:select' [string "?"]
[2019-01-26 12:39:09] ERROR: [Server]\advertisements\advertisements.lua:94: bad argument #1 to 'ipairs' (table expected, got boolean)
[2019-01-26 12:39:57] ERROR: [Server]\advertisements\advertisements.lua:94: call: failed to call 'mysql:select' [string "?"]
[2019-01-26 12:39:57] ERROR: [Server]\advertisements\advertisements.lua:94: bad argument #1 to 'ipairs' (table expected, got boolean)

Edited by 4KIST
Link to comment
On 26/01/2019 at 13:08, 4KIST said:

Yes is exists connection the MySQL

 

On 26/01/2019 at 12:04, 4KIST said:


[2019-01-26 12:39:09] ERROR: [Server]\advertisements\advertisements.lua:94: call: failed to call 'mysql:select' [string "?"]
[2019-01-26 12:39:09] ERROR: [Server]\advertisements\advertisements.lua:94: bad argument #1 to 'ipairs' (table expected, got boolean)
[2019-01-26 12:39:57] ERROR: [Server]\advertisements\advertisements.lua:94: call: failed to call 'mysql:select' [string "?"]
[2019-01-26 12:39:57] ERROR: [Server]\advertisements\advertisements.lua:94: bad argument #1 to 'ipairs' (table expected, got boolean)

Because this looks like the query you sent to your MySQL database doesn't return your values. Did you look up in the debug log files of /debugdb? Send some lines where it occurs.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...