SA-MP Forums Archive
HELP MYSQL add other table - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: HELP MYSQL add other table (/showthread.php?tid=644080)



HELP MYSQL add other table - Darkay - 03.11.2017

hello there , i need your help, i'm trying to connect two tables to my GM MYSQL. i have my gm with this accounts systems https://sampforum.blast.hk/showthread.php?tid=435485, now i need create other table to save the info of the cars, and other for the jobs, but i don't have any idea to make it, some one can help me?, ( i have the idea how to create the table, i know it, but i don't know how connect two tables)


Re: HELP MYSQL add other table - Konstantinos - 03.11.2017

You connect to 1 database that has multiple tables.


Re: HELP MYSQL add other table - Lucases - 03.11.2017

Use PhpMyAdmin and add new tables


Re: HELP MYSQL add other table - Darkay - 03.11.2017

ok i was looking for it. i am learning about the relation and the fk, pk. if i need help i reply it


Re: HELP MYSQL add other table - Lucases - 03.11.2017

Quote:
Originally Posted by Darkay
Посмотреть сообщение
ok i was looking for it. i am learning about the relation and the fk, pk. if i need help i reply it
What do you mean?


Re: HELP MYSQL add other table - Darkay - 03.11.2017

i tried but not succes... this is my gm dont save the coordenades, health :c just the password and things to the table 1


Re: HELP MYSQL add other table - Darkay - 05.11.2017

i can't load or save dates of the others tables. please help me


Re: HELP MYSQL add other table - OneDay - 06.11.2017

https://dev.mysql.com/doc/refman/5.7...ate-table.html


Re: HELP MYSQL add other table - Darkay - 06.11.2017

ID: 1452 - Error: Cannot add or update a child row: a foreign key constraint fails (`tnwdb`.`users`, CONSTRAINT `users_ibfk_1` FOREIGN KEY (`account_id`) REFERENCES `accounts` (`id_account`) ON DELETE CASCADE ON UPDATE CASCADE) - Callback - OnQueryFinish - Query: INSERT INTO `users` (id_user) VALUES ('0')


Re: HELP MYSQL add other table - Darkay - 06.11.2017

what should i do?