Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/284.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 校准失败了_C#_Stored Procedures_Teradata - Fatal编程技术网

C# 校准失败了

C# 校准失败了,c#,stored-procedures,teradata,C#,Stored Procedures,Teradata,我得到了下面的代码作为字符串返回。但是,输出返回的是一个凌乱的代码,所有对齐都已取消。是否仍要将存储过程作为原始编码返回 command = "SHOW PROCEDURE Inventory.pr_demand_curr()" using (TdConnection cn = new TdConnection(connectionString)) { cn.Open(); TdCommand cmd = cn.CreateCom

我得到了下面的代码作为字符串返回。但是,输出返回的是一个凌乱的代码,所有对齐都已取消。是否仍要将存储过程作为原始编码返回

command = "SHOW PROCEDURE Inventory.pr_demand_curr()"

using (TdConnection cn = new TdConnection(connectionString))
        {
            cn.Open();
            TdCommand cmd = cn.CreateCommand();
            cmd.CommandText = command;

            reader = cmd.ExecuteReader();
            while (reader.Read())
            {
               output += reader.GetString(0);
            }
        }
        return output;

我想知道cmd.CommandType=System.Data.CommandType.StoredProcess;你能解决这个问题吗?我试图在CreateCommand()下面添加此内容,但查询失败,因为executeReader()无法读取show store过程。列中的数据是什么格式的?例如,是否需要在每个GetString()之后添加新行?