Where to store SQL commands for execution

后端 未结 12 1465
后悔当初
后悔当初 2021-02-05 16:00

We face code quality issues because of inline mysql queries. Having self-written mysql queries really clutters the code and also increases code base etc.

Our code is clu

12条回答
  •  北荒
    北荒 (楼主)
    2021-02-05 16:37

    Put your query into database procedure and call procedure in the code, when it is needed.

    create procedure sp_query()
    select * from table1;
    

提交回复
热议问题