using System;
using System.Collections.Generic;
using System.Text;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Data;
namespace NullInstance
{
    class Program
    {
        static void Main(string[] args)
        {
    
            SqlConnection conn = new SqlConnection("server=(local);database=scratch;integrated security=true");
            SqlCommand cmd = new SqlCommand("DECLARE @dim LDim;DECLARE @i int;SELECT @dim, @i", conn);
            conn.Open();
            SqlDataReader rdr = cmd.ExecuteReader();
            DataTable t = rdr.GetSchemaTable();
            t.WriteXml(Console.Out);
            while (rdr.Read())
            {
                Object o = rdr.GetValue(0);
                SqlInt32 d = (SqlInt32)(rdr.GetValue(0));
                //Dimensions.LDim d = (Dimensions.LDim)(rdr.GetSqlValue(0));
            }
        }
    }
}
