REVENSE
Posts: 46
|
| Posted: 07/25/2008, 5:43 AM |
|
hai guys
i was crated store procedure on mysql, but when try to call that procedure from codecharge it became error but when i am trying to call that procedure on mysql everything is ok . for the record this is my first time using procedure on codecharge, i am usually using query(manual).
my question is any one know step by step to input parameter on codecharge while using procedure mode.
i realy need help guys,
thx
Rev
|
 |
 |
maxhugen
Posts: 272
|
| Posted: 07/28/2008, 4:57 PM |
|
Hi Rev
I've been trying to use stored procedures, but have run into problems because my web service provider hasn't upgraded to the latest version of MySQL yet, which allows a user other than root to specify a Definer other than CURRENT_USER...
But assuming you don't have that issue.... your stored proc should have an IN parameter defined - yes?
In your CCS page, in the php code somewhere, you would call the procedure using an sql statement that you've prepared. This would include your parameter. As a rough example:
$db = new clsDBMyConnection();
$sql = "CALL my_procedure(" . $db->ToSQL(my_parameter,ccsInteger) . ");";
$db->query($sql);
$db->close();
I can't promise this will work, as I'm still having different probs with stored procedures, but I think that's how it should be done.
HTH
_________________
Max
www.gardenloco.com | www.eipdna.com | www.chrisarminson.com |
 |
 |
REVENSE
Posts: 46
|
| Posted: 08/12/2008, 11:27 PM |
|
hai max
thx for your help i really apriciate that :)
Rev
|
 |
 |
|