These paragraphs appear conflicting to me: the first implies that you can pass GL_TEXTURE_2D for <type>, but the second states that <type> is interpreted according to TexImage3D which doesn't support GL_TEXTURE_2D.
For texture types that do not have certain dimensions, this command treats those dimensions as having a size of 1. For example, to clear a portion of a two- dimensional texture, use zoffset equal to zero and depth equal to one.
format and type specify the format and type of the source data and are inter- preted as they are for TexImage3D, as described in section [COLOR=rgb(100.000000%, 0.000000%, 0.000000%)]8.4.4[/COLOR]. Textures with a base internal format of DEPTH_COMPONENT, STENCIL_INDEX, DEPTH_STENCIL require depth component, stencil, or depth/stencil component data respectively. Textures with other base internal formats require RGBA formats. Textures with in- teger internal formats (see table [COLOR=rgb(100.000000%, 0.000000%, 0.000000%)]8.12[/COLOR]) require integer data.