prepare实施BUG吗

prepare执行BUG吗?
sprintf(str_cmd,"%s%s","select * from ",buffer,":systables into temp aa");
$prepare  aa from $str_cmd
$execute aa


-410    Prepare statement failed or was not executed.

This EXECUTE statement refers to a statement id that has not been
prepared. Either no PREPARE statement was done, or one was done but
returned an error code. Review the program logic to ensure that a
statement is prepared and the PREPARE return code is checked. A
negative error code from PREPARE usually reflects an error in the
statement being prepared.



请问何解?

398407063  俺在写一个,生成纯SQL的小工具。以免不同数据库造成语法不一样!




另请 

------解决方案--------------------
没有人遇到过吗
------解决方案--------------------
都没有人用吗?