SQL query from Matlab
古いコメントを表示
Hi i am trying to format my sqlstr going into mysql but can't seem to get the format correct using sprintf function
here is the code i am using:
TableType = char(PramTest); TableRow = char(DataSelection);
%TableType reurns the value of 'SPEC' and TableRow = '1'.
sqlStrtest= sprintf('select * from %s where id%s = %d', TableType, TableType, TableRow); disp(sqlStrtest)
This reurns the following:
select * from where idSPEC = 83select * from where idPEC = 49
What i need it to return is
select * from SPEC where idSPEC = 1
can you help me please in quiring a correct format.
thank you
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で ARM Cortex-A Processors についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!