Is "
columne name
" the column containing the size? And why do you a
data.GetInt32(data.GetOrdinal("columne name"))
instead of
data.GetInt32("columne name")
? Perhaps a
GetInt64
would do the trick.
In case that "
columne name
" contains the image, you could use the
OCTET_LENGTH
function in a query to retrieve its length:
SELECT OCTET_LENGTH("columne name") FROM YOURTABLE WHERE ....