How can i store the value in db(MySql) ??

  • Thread starter Deepak Kumar Shivhare
  • Start date
D

Deepak Kumar Shivhare

Hello,

I am new in Ruby.

Can you tell me how can I store the value in databse(MySql).

I have 2 Textbox one is User Name and another one is Password and 2
button i.e., Submit and Cancel. I want whenever I click on the submit
button the value should be stored in the database.

I have made a table i.e., user in the database(MySql) having fields id,
username and password. id is a primary key.


Thanks in Advance
Deepak
 
P

Phillip Gawlowski

Deepak said:
Hello,

I am new in Ruby.

Can you tell me how can I store the value in databse(MySql).

I have 2 Textbox one is User Name and another one is Password and 2
button i.e., Submit and Cancel. I want whenever I click on the submit
button the value should be stored in the database.

I have made a table i.e., user in the database(MySql) having fields id,
username and password. id is a primary key.

How do you access the database?
Are you using ActiveRecord or the MySQL/Ruby gem?

And if you are using the Rails framework, you might want to ask this
question (in a smarter[0] way) on the Rails-ML.

[0] http://www.catb.org/~esr/faqs/smart-questions.html

--
Phillip "CynicalRyan" Gawlowski

Rule of Open-Source Programming #20:

Open Code != Good Code
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top