diff --git a/documentation/src/main/asciidoc/introduction/Tuning.adoc b/documentation/src/main/asciidoc/introduction/Tuning.adoc index 66b019e06c..64c2bd6cfc 100644 --- a/documentation/src/main/asciidoc/introduction/Tuning.adoc +++ b/documentation/src/main/asciidoc/introduction/Tuning.adoc @@ -108,6 +108,8 @@ fundamental rule of thumb in ORM is: of a session/transaction, and fetch it immediately in one or two queries, - and only then start navigating associations between persistent entities. +image:images/fetching.png[width=700,align="center"] + Without question, the most common cause of poorly-performing data access code in Java programs is the problem of _N+1 selects_. Here, a list of N rows is retrieved from the database in an initial query, and then diff --git a/documentation/src/main/asciidoc/introduction/images/fetching.png b/documentation/src/main/asciidoc/introduction/images/fetching.png new file mode 100644 index 0000000000..cd9fadfebe Binary files /dev/null and b/documentation/src/main/asciidoc/introduction/images/fetching.png differ