Problem

Why can I read certain parameters using the grib tools, but not from my program?

Solution

Your file may be encoded as a multi-field GRIB file. By default, ecCodes GRIB handling tools have multi-field support enabled and the API has it disabled. Check the examples to see how to enable this feature in your program: