Jump to content
  • 0

SQL Syntax help


trann123

Question


  • Group:  Members
  • Topic Count:  8
  • Topics Per Day:  0.00
  • Content Count:  12
  • Reputation:   0
  • Joined:  01/08/12
  • Last Seen:  

Can anyone help me how to add a table and call a value in that table and add a value in the table. Any random example would be appreciated, but of course with given info. Thanks guys. /no1

Link to comment
Share on other sites

4 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  7
  • Topics Per Day:  0.00
  • Content Count:  130
  • Reputation:   43
  • Joined:  12/11/11
  • Last Seen:  

Tutorials: http://www.mysqltuto...l-tutorial.aspx

Add a table: http://www.mysqltuto...ibe-tables.aspx

CREATE TABLE troll (
 id int(11) NOT NULL,
 name varchar(50) NOT NULL,
);

Add a value: http://www.mysqltuto...-statement.aspx

INSERT troll (id, name) VALUES (1, 'Troll facé');

Get the value: http://www.mysqltuto...query-data.aspx

SELECT name FROM troll WHERE id = 1

You will use query_sql with the emulator: http://rathena.org/wiki/Query_sql

Edited by plankt
  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  8
  • Topics Per Day:  0.00
  • Content Count:  12
  • Reputation:   0
  • Joined:  01/08/12
  • Last Seen:  

Last question, where do you put the add table in the script?

Edited by trann123
Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10013
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

run that in ur MySQL / PhpMyAdmin / etc... ?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  8
  • Topics Per Day:  0.00
  • Content Count:  12
  • Reputation:   0
  • Joined:  01/08/12
  • Last Seen:  

No I mean this

CREATE TABLE troll (

id int(11) NOT NULL,

name varchar(50) NOT NULL,

);

Do I put it in the script aswell?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...