- public List<LDNo> LDNoList(Int64? LDNo)
- {
- ResultModel result = new Models.ViewModel.CommonViewModel.ResultModel();
- string error = String.Empty;
- QUERY2 query = new QUERY2();
- Dictionary<string, object> dict = new Dictionary<string, object>();//= new Dictionary<string, string>
- List<LDNo> ldnoList = new List<LDNo>();
- dict.Add("@LDNO", LDNo);
- dict.Add("@Result", 1.ToString());
- dict.Add("@Message", "Message".ToString());
- query.SQL = @"SPROC_GET_tblDyesForecastingHead_LDNO";
- query.PARAMETER = dict;
- clsDataprocess cls = new clsDataprocess();
- result = cls.ExecuteSqlStoredProcedureSaveEdit(query, "get", out error);
- if (result.Result && result.DtTable != null && result.DtTable.Rows.Count > 0)
- {
- Int64 tempi = 0;
- for (int i = 0; i < result.DtTable.Rows.Count; i++)
- {
- LDNo lDNo = new LDNo();
- Int64.TryParse(result.DtTable.Rows[i]["LDNO"].ToString(), out tempi);
- lDNo.LdNo = tempi;
- ldnoList.Add(lDNo);
- }
- string Message = result.Message;
- string Result = result.Result.ToString();
- }
- else if (!result.Result)
- {
- throw new Exception(result.Message);
- }
- return ldnoList;
- }
MY Favorite .Net Question For Interview
This are not tidy. Just for rough. In Sha Allah will make it tiddy soon. 1. DateTime2 Date range 0001-01-01 through 9999-12-31 vs Date...
Users Countries
Showing posts with label SqlClient. Show all posts
Showing posts with label SqlClient. Show all posts
Thursday, November 1, 2018
Using SqlClient connect to sql server and CRUD in Databse thorough Stored Procedure
Muhammad Ashikuzzaman
November 01, 2018
0
Wednesday, August 15, 2018
Using SqlClient connect to sql server and CRUD in Databse thorough code base Inner Query Query
Muhammad Ashikuzzaman
August 15, 2018
0
2. SqlClientCode For Calling StoredProcedure for Getting Data
2. Service
- public JsonResult BuyerList()
- {
- Chemical_DAL obj_dal = new Chemical_DAL();
- return Json(obj_dal.BuyerList());
- }
2. Service
- public class QUERY
- {
- public string SQL { get; set; }
- public Dictionary<string, string> PARAMETER { get; set; }
- public Dictionary<string, byte[]> BYTEPARAMETER { get; set; }
- }