99 ways to skin a cat.

But you're right, this can be done in your layers. Slap on the wrist for us.

You'll need to create a method in your codebehind, which takes two values - the cog and the dsc. This method should check cog for null and if it's null, return a string 'INDEX' else return the dsc value.

You then call this codebehind method from your inline code in the gridview.

It will look something like

<%# MethodName(Container.DataItem("cog"), Container.DataItem("dsc")) %>

Not sure about the exact syntax, but it's a matter of calling a method, passing the values and having the MethodName() return a string.