[Help] esx-vehicle shop menu not working

So I loaded esx_vehicleshop into my server, everything works fine the first time I walk into the marker. But once I back out of the menu and try to go back into it, it does not give me a prompt to enter the marker again. I’ve gone through the code like 10 times comparing it to other shop resources, but I can not fix the problem. Does anyone have a fix for this?

i got an other script error this one @esx_vehicleshop/client/main.lua:161: bad argument #1 to ‘insert’ (table expected, got nil) i don’t know how i can fix this error

1 Like

Do you have this in your database?

CREATE TABLE `vehicle_categories` (
	`name` varchar(60) NOT NULL,
	`label` varchar(60) NOT NULL,

	PRIMARY KEY (`name`)
);

INSERT INTO `vehicle_categories` (name, label) VALUES
	('compacts','Compacts'),
	('coupes','Coupés'),
	('sedans','Sedans'),
	('sports','Sports'),
	('sportsclassics','Sports Classics'),
	('super','Super'),
	('muscle','Muscle'),
	('offroad','Off Road'),
	('suvs','SUVs'),
	('vans','Vans'),
	('motorcycles','Motos')

Yes i got this in my database

I had the problem until recently too, then I had reset the database via Zap hosting then it went :grinning:
Srry for my bad english im a german xD

i have everything in the database but i cant open the menu no matter what no errors: its like it doesnt recognize me being on the marker…

Hey there, i have recently had the same issue but i have resolved it by making sure all vehicle
categories are there, if u have re moved a category it seems to mess it up.

make sure all are there!

Capture

Hope this helps!

help with this please guys

I FINALLY figured it out how to fix it. You just need to create vehicle table in your database in every database you use. I needed to put it in “essentialmode” but im not sure for yours. You can find this vehicle table in esx_vehicleshop.sql file

Hey I fixed it already but thanks for your help bro :+1:t2:

hey can you show me a picture of what ur database looks like please?

I know its a mess but I figured out that it doesnt matter in which database files are in, they just need to be in the same

Hi Dodoro,

I’m having this issue, so are you saying in every database table (regardless of whether they relate to vehicles or not) I have to put:

CREATE TABLE vehicle_categories (
name varchar(60) NOT NULL,
label varchar(60) NOT NULL,

PRIMARY KEY (`name`)

);

INSERT INTO vehicle_categories (name, label) VALUES
(‘compacts’,‘Compacts’),
(‘coupes’,‘Coupés’),
(‘sedans’,‘Sedans’),
(‘sports’,‘Sports’),
(‘sportsclassics’,‘Sports Classics’),
(‘super’,‘Super’),
(‘muscle’,‘Muscle’),
(‘offroad’,‘Off Road’),
(‘suvs’,‘SUVs’),
(‘vans’,‘Vans’),
(‘motorcycles’,‘Motos’)

1 Like

hey man i already create a vehicle table but it still doesnt work

1 Like

how did you fix it?