官术网_书友最值得收藏!

Keeping it simple—The key to build a good query

Before you go on to the next chapter, an important concept needs to be kept in mind:

Tip

Keep it simple is the key to success to create queries efficiently.

Simplicity is in need everywhere in the current changing world. Wherever you make things complicated, you may find yourself in an awkward position to compete with others.

My slogan is: simple, simpler, the simplest.

I have a habit in query building: the last step for any new query would be checking to see if it is the simplest one. In this way, "keep it simple" would not only be kept in the already built query, but also helps new queries to be the simplest in the beginning.

By keeping a query as simple as possible, it will ensure that the system performance is not affected. It will also be a great help to the troubleshooting process. A short checklist for simplicity is as follows:

  • Other queries: Are there any other queries doing a similar job, and if yes, why does the new query need to be built?
  • Tables: Are there any tables that have not been used for the query?
  • Fields: Are there any fields that have not been used for the query?
  • Conditions: Are there any condition overlaps?

The list can be much longer. The meaning behind it is clear: there is a never ending battle to get rid of complications.

When you try this method and it becomes a routine, you will find that query building becomes an enjoyable process.

主站蜘蛛池模板: 长汀县| 昆山市| 鹤壁市| 清丰县| 永善县| 松江区| 博爱县| 万盛区| 科技| 曲阳县| 高碑店市| 上犹县| 诸城市| 英山县| 江陵县| 始兴县| 镇平县| 西充县| 丽江市| 榆中县| 平南县| 英德市| 宜城市| 庄河市| 电白县| 虎林市| 甘德县| 耒阳市| 青田县| 延寿县| 朝阳区| 吉隆县| 南平市| 宁武县| 洛南县| 许昌县| 葵青区| 平南县| 阿鲁科尔沁旗| 江孜县| 景德镇市|