Symbianize Forum

Most of our features and services are available only to members, so we encourage you to login or register a new account. Registration is free, fast and simple. You only need to provide a valid email. Being a member you'll gain access to all member forums and features, post a message to ask question or provide answer, and share or find resources related to mobile phones, tablets, computers, game consoles, and multimedia.

All that and more, so what are you waiting for, click the register button and join us now! Ito ang website na ginawa ng pinoy para sa pinoy!

[HELP]How to Prevent SQL Injection?

backbutton123

Novice
Advanced Member
Messages
48
Reaction score
0
Points
26
C# gamit ko Windows Form;

up ko lang mga sir: ganito po ba yung parametized query?

string query = "Select * from Accounts where Uname=@Uname and Pword = @Pass";
OleDbCommand cmd = new OleDbCommand(query,connection);
cmd.Connection = connection;
cmd.Parameters.AddWithValue("@User",Uname_Text.Tex t);
cmd.Parameters.AddWithValue("@Pass", Pword_Text.Text);
 
Last edited:
gamit ka ng parameterized query bro
 
Stored Procedure for MS SQL Server and Routine for MySQL
 
ah sige mga boss salamat.
 
Last edited:
up ko lang mga sir: ganito po ba yung parametized query?

string query = "Select * from Accounts where Uname=@Uname and Pword = @Pass";
OleDbCommand cmd = new OleDbCommand(query,connection);
cmd.Connection = connection;
cmd.Parameters.AddWithValue("@User",Uname_Text.Text);
cmd.Parameters.AddWithValue("@Pass", Pword_Text.Text);
 
up ko lang mga sir: ganito po ba yung parametized query?

string query = "Select * from Accounts where Uname=@Uname and Pword = @Pass";
OleDbCommand cmd = new OleDbCommand(query,connection);
cmd.Connection = connection;
cmd.Parameters.AddWithValue("@User",Uname_Text.Text);
cmd.Parameters.AddWithValue("@Pass", Pword_Text.Text);

oo ganyan nga.. tamayang ginagawa mo :) Very good! hehe
 
Back
Top Bottom