Sql query errro
#1

pawn Code:
mysql_tquery(g_SQL, "INSERT INTO `drugpoints`", "OnDrugPointCreated", "d", i);
What's wrong in this sql query? i'm getting syntax error.
Reply
#2

https://www.w3schools.com/sql/sql_insert.asp
Reply
#3

Quote:
Originally Posted by Banditul18
View Post
Thank you but that doesn't help me. Do you mind tell me what's wrong with my query?
Reply
#4

Quote:
Originally Posted by KinderClans
View Post
Thank you but that doesn't help me. Do you mind tell me what's wrong with my query?
If you looked on how the querry looks like in the link you would have deducted that you miss to specificy the colums to be insert to and values of that colums to be add
Reply
#5

I dont need to add any values. Just the OnDrugPointCreated...
Reply
#6

You can always make all the colums in the that table have defaults values(so querry will not fail) and make that query acording to the corect syntax(maybe inserting a default value)
Reply
#7

I can't make default values since are connected to a dynamic drug point system. Can you please help me and show me how to fix this query? Thanks.
Reply
#8

Fixed. At the end i setup interior default value to 0.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)