Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MySQL query parameters

Status
Not open for further replies.

NearAway

Technical User
Feb 6, 2003
9
CA
Hello everyone,

I'm a sql server DBA and I'm new to MySQL. I'm using version 4.0 (with no stored procs).

What I would like to know is how queries with parameters are performed, ie:

SELECT *
FROM table
WHERE field1 = 'some value'

The impression I'm getting is that MySQL 4.0 must have complete statements passed into it. In other words, the statement is created in a front end app like asp or C or whatever and the parameters are appended and everything, then the whole statement is passed to MySQL for processing. There is no way to pass in a parameter or search value to MySQL.

Is this correct? Many thanks

Rick
 
in the user interface you can add parameters to you're sql statement

$query="SELECT *
FROM table
WHERE field1 = '$yourvariable'";

if that's what you mean and otherwise it's way out of my knowledge
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top