當前位置: 首頁>>代碼示例>>C#>>正文


C# DatabaseManager.SqlCeDataManager類代碼示例

本文整理匯總了C#中WebSpider.Data.DatabaseManager.SqlCeDataManager的典型用法代碼示例。如果您正苦於以下問題:C# SqlCeDataManager類的具體用法?C# SqlCeDataManager怎麽用?C# SqlCeDataManager使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


SqlCeDataManager類屬於WebSpider.Data.DatabaseManager命名空間,在下文中一共展示了SqlCeDataManager類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: DeleteByPart

 public int DeleteByPart(String AdiNumber)
 {
     String Query = "DELETE FROM ADIInventory WHERE AdiNumber = @AdiNumber";
     SqlCeDataManager oDm = new SqlCeDataManager(ConnectionString, Query, true);
     oDm.AddVarcharPara("AdiNumber", 4000, AdiNumber);
     return oDm.RunActionQuery();
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:ADIInventoryDetailsManager.cs

示例2: GetBySite

 public List<FinalExport> GetBySite(String ExportSite)
 {
     String Query = "SELECT * FROM FinalExport WHERE ExportSite = @ExportSite ORDER BY CreatedDate";
     SqlCeDataManager oDm = new SqlCeDataManager(ConnectionString, Query, true);
     oDm.AddVarcharPara("ExportSite", 4000, ExportSite);
     return DataParser.ToList<FinalExport>(oDm.GetTable());
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:FinalExportManager.cs

示例3: DeleteById

 public int DeleteById(Int64 TaskID)
 {
     String Query = "DELETE FROM TaskDetail WHERE TaskID = @TaskID";
     SqlCeDataManager oDm = new SqlCeDataManager(ConnectionString, Query, true);
     oDm.AddIntegerBigPara("TaskID", TaskID);
     return oDm.RunActionQuery();
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:TaskDetailManager.cs

示例4: GetCategoryByParent

 public List<AdiCategory> GetCategoryByParent(String ParentValue)
 {
     String Query = "SELECT * FROM ADICategory WITH (NOLOCK) WHERE ParentValue = @ParentValue";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.AddVarcharPara("ParentValue", 255, ParentValue);
     return DataParser.ToList<AdiCategory>(oDm.GetTable());
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:ADICategoryManager.cs

示例5: GetDataById

 public List<TaskDetail> GetDataById(Int64 TaskID)
 {
     String Query = "SELECT * FROM TaskDetail WHERE TaskID = @TaskID";
     SqlCeDataManager oDm = new SqlCeDataManager(ConnectionString, Query, true);
     oDm.AddIntegerBigPara("TaskID", TaskID);
     return DataParser.ToList<TaskDetail>(oDm.GetTable());
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:TaskDetailManager.cs

示例6: ProductCount

 //public List<ADIInventoryExport> FillByProduct(String PART_NUM)
 //{
 //    String Query = "SELECT * FROM ADIInventoryExport WHERE PART_NUM = @PART_NUM";
 //    SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
 //    oDm.AddVarcharPara("PART_NUM", 4000, PART_NUM);
 //    return DataParser.ToList<ADIInventoryExport>(oDm.GetTable());
 //}
 public int ProductCount(String PART_NUM)
 {
     String Query = "SELECT COUNT(1) FROM ADIInventoryExport WITH (NOLOCK) WHERE PART_NUM = @PART_NUM";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.AddVarcharPara("PART_NUM", 4000, PART_NUM);
     return (int) oDm.GetTable().Rows[0][0];
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:14,代碼來源:ADIInventoryExportManager.cs

示例7: DeleteById

 public int DeleteById(Int64 ScheduleID)
 {
     String Query = "DELETE FROM [TaskHeader] WHERE [ScheduleID] = @ScheduleID";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.AddIntegerBigPara("ScheduleID", ScheduleID);
     return oDm.RunActionQuery();
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:TaskHeaderManager.cs

示例8: GetDataTableByPartNumber

 public DataTable GetDataTableByPartNumber(String PART_NUM)
 {
     String Query = "SELECT * FROM ADIChild WITH (NOLOCK) WHERE PART_NUM = @PART_NUM";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.AddVarcharPara("PART_NUM", 4000, PART_NUM);
     return oDm.GetTable();
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:ProductSpecificationManager.cs

示例9: Insert

 private int Insert(String ManufacturerCode, InManufacturerSeries manufacturer)
 {
     String Query = "INSERT INTO [SecLockManufacturerSeries]([ManufacturerCode],[Name]) VALUES('"
         +  ManufacturerCode + "','" + manufacturer.Name + "');";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     return oDm.RunActionQuery();
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:InManufacturerSeriesManager.cs

示例10: GetTop

 public FinalExport GetTop()
 {
     String Query = "SELECT TOP 1 * FROM FinalExport ORDER BY CreatedDate";
     SqlCeDataManager oDm = new SqlCeDataManager(ConnectionString, Query, true);
     List<FinalExport> finalExports = DataParser.ToList<FinalExport>(oDm.GetTable());
     return finalExports.Count == 0 ? null : finalExports[0];
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:FinalExportManager.cs

示例11: GenerateScheduleNextRun

 public void GenerateScheduleNextRun()
 {
     String Query = String.Empty;
     SqlCeDataManager oDm;
     Query = "UPDATE	[TaskHeader] WITH (ROWLOCK) SET [NextRun] = DATEADD(yy, [TaskRepeatInterval], CASE WHEN [LastRun] IS NULL THEN [ScheduleFrom] ELSE [LastRun] END) WHERE	[TaskRepeatUnit] = 'YEAR' AND (ISNULL([NextRun]) = 1 OR [NextRun] < GETDATE())";
     oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.RunActionQuery();
     Query = "UPDATE	[TaskHeader] WITH (ROWLOCK) SET [NextRun] = DATEADD(q, [TaskRepeatInterval], CASE WHEN [LastRun] IS NULL THEN [ScheduleFrom] ELSE [LastRun] END) WHERE	[TaskRepeatUnit] = 'QUARTER' AND (ISNULL([NextRun]) = 1 OR [NextRun] < GETDATE())";
     oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.RunActionQuery();
     Query = "UPDATE	[TaskHeader] WITH (ROWLOCK) SET [NextRun] = DATEADD(m, [TaskRepeatInterval], CASE WHEN [LastRun] IS NULL THEN [ScheduleFrom] ELSE [LastRun] END) WHERE	[TaskRepeatUnit] = 'MONTH' AND (ISNULL([NextRun]) = 1 OR [NextRun] < GETDATE())";
     oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.RunActionQuery();
     Query = "UPDATE	[TaskHeader] WITH (ROWLOCK) SET [NextRun] = DATEADD(ww, [TaskRepeatInterval], CASE WHEN [LastRun] IS NULL THEN [ScheduleFrom] ELSE [LastRun] END) WHERE	[TaskRepeatUnit] = 'WEEK' AND (ISNULL([NextRun]) = 1 OR [NextRun] < GETDATE())";
     oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.RunActionQuery();
     Query = "UPDATE	[TaskHeader] WITH (ROWLOCK) SET [NextRun] = DATEADD(d, [TaskRepeatInterval], CASE WHEN [LastRun] IS NULL THEN [ScheduleFrom] ELSE [LastRun] END) WHERE	[TaskRepeatUnit] = 'DAY' AND (ISNULL([NextRun]) = 1 OR [NextRun] < GETDATE())";
     oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.RunActionQuery();
     Query = "UPDATE	[TaskHeader] WITH (ROWLOCK) SET [NextRun] = DATEADD(hh, [TaskRepeatInterval], CASE WHEN [LastRun] IS NULL THEN [ScheduleFrom] ELSE [LastRun] END) WHERE	[TaskRepeatUnit] = 'HOUR' AND (ISNULL([NextRun]) = 1 OR [NextRun] < GETDATE())";
     oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.RunActionQuery();
     Query = "UPDATE	[TaskHeader] WITH (ROWLOCK) SET [NextRun] = DATEADD(mi, [TaskRepeatInterval], CASE WHEN [LastRun] IS NULL THEN [ScheduleFrom] ELSE [LastRun] END) WHERE	[TaskRepeatUnit] = 'MINUTE' AND (ISNULL([NextRun]) = 1 OR [NextRun] < GETDATE())";
     oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.RunActionQuery();
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:26,代碼來源:TaskHeaderManager.cs

示例12: GetDataByCatagoryID

 public List<ADICategoryExport> GetDataByCatagoryID(String Value)
 {
     String Query = "SELECT * FROM ADICategoryExport WITH (NOLOCK) WHERE Value = @Value";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.AddVarcharPara("Value", 255, Value);
     return DataParser.ToList<ADICategoryExport>(oDm.GetTable());
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:ADICategoryExportManager.cs

示例13: GetData

 public List<AdiProduct> GetData()
 {
     String Query = "SELECT * FROM ADIProduct1 WITH (NOLOCK)";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.ConnectionString = this.ConnectionString;
     return DataParser.ToList<AdiProduct>(oDm.GetTable());
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:ADIProductManager.cs

示例14: GetAllPriorityProducts

 public List<AdiProduct> GetAllPriorityProducts()
 {
     String Query = "SELECT * FROM ADIProduct1 WITH (NOLOCK) WHERE PriorityProduct = 1 AND LastUpdateDatetime <= DATEADD(d, -1, GETDATE())";
     SqlCeDataManager oDm = new SqlCeDataManager(this.ConnectionString, Query, true);
     oDm.ConnectionString = this.ConnectionString;
     return DataParser.ToList<AdiProduct>(oDm.GetTable());
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:7,代碼來源:ADIProductManager.cs

示例15: Insert

 public int Insert(String AdiNumber, String id, String dc, String region, String storeName, String address1, String address2, String address3
     , String country, String city, String state, String stateName, String zip, String phone, String fax, float? lat, float? lon, String inventory
     , String manager, String responseCode, String responseMessage, Boolean IsHub)
 {
     String Query = "INSERT INTO ADIInventory (AdiNumber, id ,dc ,region ,storeName ,address1 ,address2 ,address3 ,country ,city ,state ,stateName ,zip ,phone ,fax ,lat ,lon ,inventory ,manager ,responseCode ,responseMessage ,IsHub, LastUpdate) "
         + "VALUES (@AdiNumber, @id ,@dc ,@region ,@storeName ,@address1 ,@address2 ,@address3 ,@country ,@city ,@state ,@stateName ,@zip ,@phone ,@fax ,@lat ,@lon ,@inventory ,@manager ,@responseCode ,@responseMessage ,@IsHub, @LastUpdate)";
     SqlCeDataManager oDm = new SqlCeDataManager(ConnectionString, Query, true);
     oDm.AddVarcharPara("AdiNumber", 4000, AdiNumber);
     oDm.AddVarcharPara("id", 4000, id);
     oDm.AddVarcharPara("dc", 4000, dc);
     oDm.AddVarcharPara("region", 4000, region);
     oDm.AddVarcharPara("storeName", 4000, storeName);
     oDm.AddVarcharPara("address1", 4000, address1);
     oDm.AddVarcharPara("address2", 4000, address2);
     oDm.AddVarcharPara("address3", 4000, address3);
     oDm.AddVarcharPara("country", 4000, country);
     oDm.AddVarcharPara("city", 4000, city);
     oDm.AddVarcharPara("state", 4000, state);
     oDm.AddVarcharPara("stateName", 4000, stateName);
     oDm.AddVarcharPara("zip", 4000, zip);
     oDm.AddVarcharPara("phone", 4000, phone);
     oDm.AddVarcharPara("fax", 4000, fax);
     oDm.AddFloatPara("lat", lat);
     oDm.AddFloatPara("lon", lon);
     oDm.AddVarcharPara("inventory", 4000, inventory);
     oDm.AddVarcharPara("manager", 4000, manager);
     oDm.AddVarcharPara("responseCode", 4000, responseCode);
     oDm.AddVarcharPara("responseMessage", 4000, responseMessage);
     oDm.AddBoolPara("IsHub", IsHub);
     oDm.AddDateTimePara("LastUpdate", DateTime.Now);
     return oDm.RunActionQuery();
 }
開發者ID:riskypathak,項目名稱:WebSpider,代碼行數:32,代碼來源:ADIInventoryDetailsManager.cs


注:本文中的WebSpider.Data.DatabaseManager.SqlCeDataManager類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。