Get data from SQL datebase and return as string
<p>Need help to get the 1st row record and return record as string in the <code>&lt;&lt; &gt;&gt;</code> after <code>while()</code> loop.
There are a lot of columns in one row, I'm having a problem to declare it as string st? like usually <code>string st = new string()</code> please help to correct it</p>

<p>Thanks</p>

<pre><code>public string Get_aodIdeal(string SubmittedBy)
{
    String errMsg = "";
    Guid? rguid = null;
    int isOnContract = 0;
    int isFreeMM = 0;
    string _FileName;
    DateTime InstallDateTime = DateTime.Now;
    string FileDate = ToYYYYMMDD(DateTime.Now);
    errMsg = "Unknown Error.";

    SqlConnection conn = null; SqlCommand cmd = null;
    string st = null;

    conn = new SqlConnection(WebConfigurationManager.ConnectionStrings["iDeal"].ConnectionString);
    cmd = new SqlCommand();
    string SQL = "select TOP 1 * from table1 Order by SubmittedOn desc";
    SqlDataAdapter sqd = new SqlDataAdapter(SQL, conn);
    cmd.CommandTimeout = 1200;
    conn.Open();
    SqlDataReader sqr;
    //sqd.SelectCommand.Parameters.Add("@Submitted", SqlDbType.Int).Value = PostID;
    sqr = sqd.SelectCommand.ExecuteReader();
    while (sqr.Read())
st = new string{
    rguid = cmd.Parameters["@rguid"].Value as Guid?,
                ridno = int.Parse(sqr["ridno"].ToString()),
                SubmittedOn= DateTime.Parse(sqr["SubmittedOn"].ToString()),
                SubmittingHost = sqr["SubmittingHost"].ToString(),
                ServiceAgreementNo = sqr["ServiceAgreementNo"].ToString(),
                DocumentID = sqr["DocumentID"].ToString(),
                Source = sqr["Source"].ToString(),
                FileName = sqr["FileName"].ToString(),
                FileType = sqr["FileType"].ToString(),
                FileDate = DateTime.Parse(sqr["FileDate"].ToString()),
                InstallTime = DateTime.Parse(sqr["InstallTime"].ToString()),
                CalenderCode = cmd.Parameters["CalenderCode"].Value as Guid,
                isFreeMM = bool.Parse(sqr["isFreeMM"].ToString()),
                isOnContract = bool.Parse(sqr["isOnContract"].ToString()),
                isProcessed = bool.Parse(sqr["isProcessed"].ToString()),
                ProcessedByFullName = sqr["ProcessedByFullName"].ToString(),
                isDelete = bool.Parse(sqr["isDelete"].ToString()),
                version = int.Parse(sqr["Version"].ToString()),
                LastUpdatedBy = DateTime.Parse(sqr["LastUpdatedBy"].ToString()),
                LastUpdatedOn = DateTime.Parse(sqr["LastUpdatedOn"].ToString()),
                shopGuid = sqr["shopGuid"].ToString(),
                MacID = sqr["MacID"].ToString(),
                MSISDN = sqr["MSISDN"].ToString()
}
</code></pre>