Not very sure about your question. I think you should go through the
SQL tutorial.
Basically you can run 2 functions.
If you are using SELECT (Retrieve data) then you use ExecQuery (or ExecQuerySingleResult).
If you are using UPDATE, INSERT or DELETE then you just use ExecNonQuery.