O'Reilly logo

Go Standard Library Cookbook by Radomir Sohlich

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Canceling the pending query

In some cases, you need to prune long running statements to limit the consumption of resources, or just if the result is not relevant, or if the statement is running too long. Since Go 1.8, the canceling of queries is possible. This recipe explains how to use this feature.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required