SlideShare a Scribd company logo
1 of 47
Windows Mobile:  Data Access and Storage Vinod Kumar M Technology Evangelist Microsoft India http://blogs.sqlxml.org/vinodkumar http://www.ExtremeExperts.com
Where We’re Going today What’s New In… ,[object Object],[object Object],[object Object],[object Object]
Changes in SQL Mobile
Changes in SQL Mobile Key new features ,[object Object],[object Object],[object Object],[object Object],[object Object]
Changes in SQL Mobile Desktop Support ,[object Object],[object Object],[object Object],[object Object]
Changes in SQL Mobile Smartphone ,[object Object],[object Object],[object Object],[object Object],[object Object]
Direct Data Management
Direct Data Management ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
SqlCeResultSet ,[object Object],[object Object],[object Object],[object Object],[object Object]
SqlCeResultSet Features vs. Performance ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
SqlCeResultSet Compatability with SqlCeDataReader ,[object Object],[object Object],[object Object],[object Object],[object Object]
SqlCeResultSet Usage ,[object Object],[object Object]
SqlCeResultSet Usage (continued) string sql = "Select ProductId, Desc, Qty, UnitPrice"; SqlCeConnection conn =  new SqlCeConnection(@"Data Source = rders.sdf"); SqlCeCommand commmand = new SqlCeCommand(sql, conn); SqlCeResultSet rs =  commmand.ExecuteResultSet(ResultSetOptions.None); while (rs.Read()) { // retrieve column values from the current record }
SqlCeResultSet Updatability ,[object Object],[object Object],[object Object],[object Object],[object Object]
SqlCeResultSet Updatability(continued) SqlCeResultSet rs =  commmand.ExecuteResultSet(ResultSetOptions.Updatable); int idxProductId = rs.GetOrdinal("ProductId"); int idxDesc = rs.GetOrdinal("Desc"); int idxUnitPrice = rs.GetOrdinal("UnitPrice"); while (rs.Read()) { // Retrieve current values string productId = rs.GetString(idxProductId); string desc = rs.GetString(idxDesc); double unitPrice = rs.GetDouble(idxUnitPrice); // Prepend Product ID to the description rs.SetString(idxDesc, productId + " - " + desc); // Increase the price by 10% rs.SetDouble(idxUnitPrice, unitPrice * 1.1); // Apply record changes to db rs.Update(); }
SqlCeResultSet Scrolling Access ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
SqlCeResultSet Scrolling Access (continued) SqlCeResultSet rs =  commmand.ExecuteResultSet(ResultSetOptions.Scrollable |  ResultSetOptions.Updatable ); // Read entire result backwards rs.ReadLast(); while(rs.ReadPrevious(); {  // ... } // Absolute positioning rs.ReadAbsolute(10);  // Read 10 records from beginning rs.ReadAbsolute(-10); // Read 10 records from end // Relative positioning rs.ReadRelative(5);  // Read forward 5 records rs.ReadRelative(-5);  // Read backward 5 records
SqlCeResultSet Databinding ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
SqlCeResultSet Databinding  (continued) SqlCeResultSet rs =  commmand.ExecuteResultSet(ResultSetOptions.Scrollable); listBox1.DataSource = rs.ResultSetView; listBox1.DisplayMember = "Desc"; listBox1.ValueMember = "ProductId"; textBox1.DataBindings.Add("Text", rs, "UnitPrice");
DataSet ,[object Object],[object Object],[object Object]
DataSet New Features/Methods ,[object Object],[object Object],[object Object],[object Object]
DataSet DataTable Serialization ,[object Object],[object Object],[object Object],[object Object],[object Object]
DataSet DataTable Serialization private void DeptComplete(string deptName, DataSet ds) { DataTable dt = ds.Tables["DeptDetail"]; dt.WriteXml(deptName + ".xml"); dt.Clear(); } private void DeptRestore(string deptName, DataSet ds) { DataTable dt = ds.Tables["DeptDetail"]; dt.Clear(); dt.ReadXml(deptName + ".xml"); }
DataSet Copy Method ,[object Object],[object Object],[object Object],[object Object],[object Object]
DataSet Copy Method (continued) [WebMethod] public void SaveSnapshot(DataSet ds) { WriteDataSetToDatabase(ds); } private void Upload(DataSet ds) { DataServerProxy wsProxy = new DataServerProxy(); wsProxy.SaveSnapshot(ds); } Target Web Service Device call – Too slow, user must wait for whole upload
DataSet Copy Method (continued) private void Upload(DataSet ds) { DataServerProxy wsProxy = new DataServerProxy(); wsProxy.BeginSaveSnapshot(ds, null, null); } private void Upload(DataSet ds) { DataServerProxy wsProxy = new DataServerProxy(); DataSet dsDupe = ds.Copy(); wsProxy.BeginSaveSnapshot(dsDupe, null, null); } Device call – Changes to data during upload will corrupt upload Device call – Send copy in background, this is safe
DataSet Getting changes ,[object Object],[object Object],[object Object],[object Object],[object Object]
DataSet Merging Changes ,[object Object],[object Object],[object Object],[object Object]
DataSet Retrieving Changes from server [WebMethod] public DataSet GetLatest(DateTime startingDate) { return RetrieveChangesFromDatabase(startingDate); } private void GetUpdates(DataSet currentDs,  DateTime lastUpdate) { DataServerProxy wsProxy = new DataServerProxy(); DataSet changeDs = wsProxy.GetLatest(lastUpdate); currentDs.Merge(changeDs); } Web method on server Call to web method from device
DataSet Sending Changes to the server [WebMethod] public void StoreUpdates(DataSet changeDs) { ApplyChangesToDataBase(changeDs); } private void SendChanges(DataSet currentDs) { DataServerProxy wsProxy = new DataServerProxy(); DataSet changeDs = currentDs.GetChanges(); wsProxy.StoreUpdates(changeDs); } Web method on server Call to web method from device
XML Support ,[object Object],[object Object],[object Object],[object Object],[object Object]
XML Serializer ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
XPath ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
XmlSchema ,[object Object],[object Object],[object Object],[object Object],[object Object]
Connectivity and Data Transfer
Connectivity and Data Transfer ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Connectivity Detecting changes in connectivity ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Tools and Productivity Enhancements
Tools and Productivity Enhancements ,[object Object],[object Object],[object Object],[object Object]
Create and Manage  ,[object Object],[object Object],[object Object],[object Object]
Create New Database
Creating New Table
Automatically adds to device
Typed DataSets ,[object Object],[object Object],[object Object]
Summary ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
[object Object],[object Object]
© 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

More Related Content

What's hot

Data Love Conference - Window Functions for Database Analytics
Data Love Conference - Window Functions for Database AnalyticsData Love Conference - Window Functions for Database Analytics
Data Love Conference - Window Functions for Database AnalyticsDave Stokes
 
Using New Data Types In2008
Using New Data Types In2008Using New Data Types In2008
Using New Data Types In2008PhilWinstanley
 
5\9 SSIS 2008R2_Training - DataFlow Basics
5\9 SSIS 2008R2_Training - DataFlow Basics5\9 SSIS 2008R2_Training - DataFlow Basics
5\9 SSIS 2008R2_Training - DataFlow BasicsPramod Singla
 
ASP.NET 08 - Data Binding And Representation
ASP.NET 08 - Data Binding And RepresentationASP.NET 08 - Data Binding And Representation
ASP.NET 08 - Data Binding And RepresentationRandy Connolly
 
Introduction to ADO.NET
Introduction to ADO.NETIntroduction to ADO.NET
Introduction to ADO.NETrchakra
 
For Beginners - Ado.net
For Beginners - Ado.netFor Beginners - Ado.net
For Beginners - Ado.netTarun Jain
 
Database connectivity to sql server asp.net
Database connectivity to sql server asp.netDatabase connectivity to sql server asp.net
Database connectivity to sql server asp.netHemant Sankhla
 
6.1\9 SSIS 2008R2_Training - DataFlow Transformations
6.1\9 SSIS 2008R2_Training - DataFlow Transformations6.1\9 SSIS 2008R2_Training - DataFlow Transformations
6.1\9 SSIS 2008R2_Training - DataFlow TransformationsPramod Singla
 
7\9 SSIS 2008R2_Training - Script Task
7\9 SSIS 2008R2_Training - Script Task7\9 SSIS 2008R2_Training - Script Task
7\9 SSIS 2008R2_Training - Script TaskPramod Singla
 

What's hot (20)

Ch 7 data binding
Ch 7 data bindingCh 7 data binding
Ch 7 data binding
 
ADO.NET -database connection
ADO.NET -database connectionADO.NET -database connection
ADO.NET -database connection
 
Ado.net
Ado.netAdo.net
Ado.net
 
ADO.NET by ASP.NET Development Company in india
ADO.NET by ASP.NET  Development Company in indiaADO.NET by ASP.NET  Development Company in india
ADO.NET by ASP.NET Development Company in india
 
ADO.NET
ADO.NETADO.NET
ADO.NET
 
Data Love Conference - Window Functions for Database Analytics
Data Love Conference - Window Functions for Database AnalyticsData Love Conference - Window Functions for Database Analytics
Data Love Conference - Window Functions for Database Analytics
 
Using New Data Types In2008
Using New Data Types In2008Using New Data Types In2008
Using New Data Types In2008
 
5\9 SSIS 2008R2_Training - DataFlow Basics
5\9 SSIS 2008R2_Training - DataFlow Basics5\9 SSIS 2008R2_Training - DataFlow Basics
5\9 SSIS 2008R2_Training - DataFlow Basics
 
Ado .net
Ado .netAdo .net
Ado .net
 
ASP.NET 08 - Data Binding And Representation
ASP.NET 08 - Data Binding And RepresentationASP.NET 08 - Data Binding And Representation
ASP.NET 08 - Data Binding And Representation
 
Ado.net
Ado.netAdo.net
Ado.net
 
Ado.net
Ado.netAdo.net
Ado.net
 
Ado.Net Tutorial
Ado.Net TutorialAdo.Net Tutorial
Ado.Net Tutorial
 
Introduction to ADO.NET
Introduction to ADO.NETIntroduction to ADO.NET
Introduction to ADO.NET
 
For Beginners - Ado.net
For Beginners - Ado.netFor Beginners - Ado.net
For Beginners - Ado.net
 
ASP.NET 09 - ADO.NET
ASP.NET 09 - ADO.NETASP.NET 09 - ADO.NET
ASP.NET 09 - ADO.NET
 
Database connectivity to sql server asp.net
Database connectivity to sql server asp.netDatabase connectivity to sql server asp.net
Database connectivity to sql server asp.net
 
6.1\9 SSIS 2008R2_Training - DataFlow Transformations
6.1\9 SSIS 2008R2_Training - DataFlow Transformations6.1\9 SSIS 2008R2_Training - DataFlow Transformations
6.1\9 SSIS 2008R2_Training - DataFlow Transformations
 
Database Connection
Database ConnectionDatabase Connection
Database Connection
 
7\9 SSIS 2008R2_Training - Script Task
7\9 SSIS 2008R2_Training - Script Task7\9 SSIS 2008R2_Training - Script Task
7\9 SSIS 2008R2_Training - Script Task
 

Viewers also liked

Viewers also liked (8)

Q3 2009 Earning Report of General Electric
Q3 2009 Earning Report of General ElectricQ3 2009 Earning Report of General Electric
Q3 2009 Earning Report of General Electric
 
Presentation on Q1 2009 Earning Report of Key Corp
Presentation on Q1 2009 Earning Report of Key CorpPresentation on Q1 2009 Earning Report of Key Corp
Presentation on Q1 2009 Earning Report of Key Corp
 
Q1 2009 Earning Report of Kimberly Clark Corp.
Q1 2009 Earning Report of Kimberly Clark Corp.Q1 2009 Earning Report of Kimberly Clark Corp.
Q1 2009 Earning Report of Kimberly Clark Corp.
 
Q1 2009 Earning Report of Duke Realty Corp.
Q1 2009 Earning Report of Duke Realty Corp.Q1 2009 Earning Report of Duke Realty Corp.
Q1 2009 Earning Report of Duke Realty Corp.
 
Q3 2009 Earning Report of RPM International Inc.
Q3 2009 Earning Report of RPM International Inc.Q3 2009 Earning Report of RPM International Inc.
Q3 2009 Earning Report of RPM International Inc.
 
Q3 Earning report of Daimler AG
Q3 Earning report of Daimler AGQ3 Earning report of Daimler AG
Q3 Earning report of Daimler AG
 
Q3 2009 Earning Report of Banco Santander S.A.
Q3 2009 Earning Report of Banco Santander S.A.Q3 2009 Earning Report of Banco Santander S.A.
Q3 2009 Earning Report of Banco Santander S.A.
 
Technology and TV
Technology and TVTechnology and TV
Technology and TV
 

Similar to Windows Mobile 5.0 Data Access And Storage Webcast

ADO.Net Improvements in .Net 2.0
ADO.Net Improvements in .Net 2.0ADO.Net Improvements in .Net 2.0
ADO.Net Improvements in .Net 2.0David Truxall
 
SQL Server 2008 for Developers
SQL Server 2008 for DevelopersSQL Server 2008 for Developers
SQL Server 2008 for Developersukdpe
 
Windows Azure and a little SQL Data Services
Windows Azure and a little SQL Data ServicesWindows Azure and a little SQL Data Services
Windows Azure and a little SQL Data Servicesukdpe
 
Ado.Net Architecture
Ado.Net ArchitectureAdo.Net Architecture
Ado.Net ArchitectureUmar Farooq
 
SQLite in Adobe AIR
SQLite in Adobe AIRSQLite in Adobe AIR
SQLite in Adobe AIRPeter Elst
 
Saying goodbye to SQL Server 2000
Saying goodbye to SQL Server 2000Saying goodbye to SQL Server 2000
Saying goodbye to SQL Server 2000ukdpe
 
Novidades do SQL Server 2016
Novidades do SQL Server 2016Novidades do SQL Server 2016
Novidades do SQL Server 2016Marcos Freccia
 
Change tracking
Change trackingChange tracking
Change trackingSonny56
 
Visual Studio 2005 Database Professional Edition
Visual Studio 2005 Database Professional EditionVisual Studio 2005 Database Professional Edition
Visual Studio 2005 Database Professional EditionDavid Truxall
 
SQL Server 2019 CTP 2.5
SQL Server 2019 CTP 2.5SQL Server 2019 CTP 2.5
SQL Server 2019 CTP 2.5Gianluca Hotz
 
Application development using Microsoft SQL Server 2000
Application development using Microsoft SQL Server 2000Application development using Microsoft SQL Server 2000
Application development using Microsoft SQL Server 2000webhostingguy
 
Data Access Mobile Devices
Data Access Mobile DevicesData Access Mobile Devices
Data Access Mobile Devicesvenkat987
 
Grid Objects in InduSoft Web Studio
Grid Objects in InduSoft Web StudioGrid Objects in InduSoft Web Studio
Grid Objects in InduSoft Web StudioAVEVA
 

Similar to Windows Mobile 5.0 Data Access And Storage Webcast (20)

ADO.Net Improvements in .Net 2.0
ADO.Net Improvements in .Net 2.0ADO.Net Improvements in .Net 2.0
ADO.Net Improvements in .Net 2.0
 
Cis266 final review
Cis266 final reviewCis266 final review
Cis266 final review
 
Mobile
MobileMobile
Mobile
 
SQL Server 2008 for Developers
SQL Server 2008 for DevelopersSQL Server 2008 for Developers
SQL Server 2008 for Developers
 
Windows Azure and a little SQL Data Services
Windows Azure and a little SQL Data ServicesWindows Azure and a little SQL Data Services
Windows Azure and a little SQL Data Services
 
Ado.Net Architecture
Ado.Net ArchitectureAdo.Net Architecture
Ado.Net Architecture
 
SQLite in Adobe AIR
SQLite in Adobe AIRSQLite in Adobe AIR
SQLite in Adobe AIR
 
Saying goodbye to SQL Server 2000
Saying goodbye to SQL Server 2000Saying goodbye to SQL Server 2000
Saying goodbye to SQL Server 2000
 
Novidades do SQL Server 2016
Novidades do SQL Server 2016Novidades do SQL Server 2016
Novidades do SQL Server 2016
 
Change tracking
Change trackingChange tracking
Change tracking
 
Lecture13
Lecture13Lecture13
Lecture13
 
Ado
AdoAdo
Ado
 
Visual Studio 2005 Database Professional Edition
Visual Studio 2005 Database Professional EditionVisual Studio 2005 Database Professional Edition
Visual Studio 2005 Database Professional Edition
 
SQL Server 2019 CTP 2.5
SQL Server 2019 CTP 2.5SQL Server 2019 CTP 2.5
SQL Server 2019 CTP 2.5
 
Practical OData
Practical ODataPractical OData
Practical OData
 
AWS RDS Migration Tool
AWS RDS Migration Tool AWS RDS Migration Tool
AWS RDS Migration Tool
 
Application development using Microsoft SQL Server 2000
Application development using Microsoft SQL Server 2000Application development using Microsoft SQL Server 2000
Application development using Microsoft SQL Server 2000
 
Data Access Mobile Devices
Data Access Mobile DevicesData Access Mobile Devices
Data Access Mobile Devices
 
Grid Objects in InduSoft Web Studio
Grid Objects in InduSoft Web StudioGrid Objects in InduSoft Web Studio
Grid Objects in InduSoft Web Studio
 
B_110500002
B_110500002B_110500002
B_110500002
 

More from Vinod Kumar

Backup beyond just a strategy with SQL Server
Backup beyond just a strategy with SQL ServerBackup beyond just a strategy with SQL Server
Backup beyond just a strategy with SQL ServerVinod Kumar
 
SQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query PerformanceSQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query PerformanceVinod Kumar
 
Advanced t sql - querying and programming inside sql server
Advanced t sql - querying and programming inside sql serverAdvanced t sql - querying and programming inside sql server
Advanced t sql - querying and programming inside sql serverVinod Kumar
 
Choosing a concurrency model, optimistic or pessimistic
Choosing a concurrency model, optimistic or pessimisticChoosing a concurrency model, optimistic or pessimistic
Choosing a concurrency model, optimistic or pessimisticVinod Kumar
 
Choosing A Concurrency Model, Optimistic Or Pessimistic
Choosing A Concurrency Model, Optimistic Or PessimisticChoosing A Concurrency Model, Optimistic Or Pessimistic
Choosing A Concurrency Model, Optimistic Or PessimisticVinod Kumar
 
Sql Server Security
Sql Server SecuritySql Server Security
Sql Server SecurityVinod Kumar
 
Protecting Your Key Asset – Data Protection Best Practices V2.0 Final
Protecting Your Key Asset – Data Protection Best Practices V2.0   FinalProtecting Your Key Asset – Data Protection Best Practices V2.0   Final
Protecting Your Key Asset – Data Protection Best Practices V2.0 FinalVinod Kumar
 

More from Vinod Kumar (7)

Backup beyond just a strategy with SQL Server
Backup beyond just a strategy with SQL ServerBackup beyond just a strategy with SQL Server
Backup beyond just a strategy with SQL Server
 
SQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query PerformanceSQL Server Query Optimization, Execution and Debugging Query Performance
SQL Server Query Optimization, Execution and Debugging Query Performance
 
Advanced t sql - querying and programming inside sql server
Advanced t sql - querying and programming inside sql serverAdvanced t sql - querying and programming inside sql server
Advanced t sql - querying and programming inside sql server
 
Choosing a concurrency model, optimistic or pessimistic
Choosing a concurrency model, optimistic or pessimisticChoosing a concurrency model, optimistic or pessimistic
Choosing a concurrency model, optimistic or pessimistic
 
Choosing A Concurrency Model, Optimistic Or Pessimistic
Choosing A Concurrency Model, Optimistic Or PessimisticChoosing A Concurrency Model, Optimistic Or Pessimistic
Choosing A Concurrency Model, Optimistic Or Pessimistic
 
Sql Server Security
Sql Server SecuritySql Server Security
Sql Server Security
 
Protecting Your Key Asset – Data Protection Best Practices V2.0 Final
Protecting Your Key Asset – Data Protection Best Practices V2.0   FinalProtecting Your Key Asset – Data Protection Best Practices V2.0   Final
Protecting Your Key Asset – Data Protection Best Practices V2.0 Final
 

Recently uploaded

Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusZilliz
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfOverkill Security
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 

Recently uploaded (20)

Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 

Windows Mobile 5.0 Data Access And Storage Webcast

  • 1. Windows Mobile: Data Access and Storage Vinod Kumar M Technology Evangelist Microsoft India http://blogs.sqlxml.org/vinodkumar http://www.ExtremeExperts.com
  • 2.
  • 3. Changes in SQL Mobile
  • 4.
  • 5.
  • 6.
  • 8.
  • 9.
  • 10.
  • 11.
  • 12.
  • 13. SqlCeResultSet Usage (continued) string sql = "Select ProductId, Desc, Qty, UnitPrice"; SqlCeConnection conn = new SqlCeConnection(@"Data Source = rders.sdf"); SqlCeCommand commmand = new SqlCeCommand(sql, conn); SqlCeResultSet rs = commmand.ExecuteResultSet(ResultSetOptions.None); while (rs.Read()) { // retrieve column values from the current record }
  • 14.
  • 15. SqlCeResultSet Updatability(continued) SqlCeResultSet rs = commmand.ExecuteResultSet(ResultSetOptions.Updatable); int idxProductId = rs.GetOrdinal("ProductId"); int idxDesc = rs.GetOrdinal("Desc"); int idxUnitPrice = rs.GetOrdinal("UnitPrice"); while (rs.Read()) { // Retrieve current values string productId = rs.GetString(idxProductId); string desc = rs.GetString(idxDesc); double unitPrice = rs.GetDouble(idxUnitPrice); // Prepend Product ID to the description rs.SetString(idxDesc, productId + " - " + desc); // Increase the price by 10% rs.SetDouble(idxUnitPrice, unitPrice * 1.1); // Apply record changes to db rs.Update(); }
  • 16.
  • 17. SqlCeResultSet Scrolling Access (continued) SqlCeResultSet rs = commmand.ExecuteResultSet(ResultSetOptions.Scrollable | ResultSetOptions.Updatable ); // Read entire result backwards rs.ReadLast(); while(rs.ReadPrevious(); { // ... } // Absolute positioning rs.ReadAbsolute(10); // Read 10 records from beginning rs.ReadAbsolute(-10); // Read 10 records from end // Relative positioning rs.ReadRelative(5); // Read forward 5 records rs.ReadRelative(-5); // Read backward 5 records
  • 18.
  • 19. SqlCeResultSet Databinding (continued) SqlCeResultSet rs = commmand.ExecuteResultSet(ResultSetOptions.Scrollable); listBox1.DataSource = rs.ResultSetView; listBox1.DisplayMember = "Desc"; listBox1.ValueMember = "ProductId"; textBox1.DataBindings.Add("Text", rs, "UnitPrice");
  • 20.
  • 21.
  • 22.
  • 23. DataSet DataTable Serialization private void DeptComplete(string deptName, DataSet ds) { DataTable dt = ds.Tables["DeptDetail"]; dt.WriteXml(deptName + ".xml"); dt.Clear(); } private void DeptRestore(string deptName, DataSet ds) { DataTable dt = ds.Tables["DeptDetail"]; dt.Clear(); dt.ReadXml(deptName + ".xml"); }
  • 24.
  • 25. DataSet Copy Method (continued) [WebMethod] public void SaveSnapshot(DataSet ds) { WriteDataSetToDatabase(ds); } private void Upload(DataSet ds) { DataServerProxy wsProxy = new DataServerProxy(); wsProxy.SaveSnapshot(ds); } Target Web Service Device call – Too slow, user must wait for whole upload
  • 26. DataSet Copy Method (continued) private void Upload(DataSet ds) { DataServerProxy wsProxy = new DataServerProxy(); wsProxy.BeginSaveSnapshot(ds, null, null); } private void Upload(DataSet ds) { DataServerProxy wsProxy = new DataServerProxy(); DataSet dsDupe = ds.Copy(); wsProxy.BeginSaveSnapshot(dsDupe, null, null); } Device call – Changes to data during upload will corrupt upload Device call – Send copy in background, this is safe
  • 27.
  • 28.
  • 29. DataSet Retrieving Changes from server [WebMethod] public DataSet GetLatest(DateTime startingDate) { return RetrieveChangesFromDatabase(startingDate); } private void GetUpdates(DataSet currentDs, DateTime lastUpdate) { DataServerProxy wsProxy = new DataServerProxy(); DataSet changeDs = wsProxy.GetLatest(lastUpdate); currentDs.Merge(changeDs); } Web method on server Call to web method from device
  • 30. DataSet Sending Changes to the server [WebMethod] public void StoreUpdates(DataSet changeDs) { ApplyChangesToDataBase(changeDs); } private void SendChanges(DataSet currentDs) { DataServerProxy wsProxy = new DataServerProxy(); DataSet changeDs = currentDs.GetChanges(); wsProxy.StoreUpdates(changeDs); } Web method on server Call to web method from device
  • 31.
  • 32.
  • 33.
  • 34.
  • 36.
  • 37.
  • 38. Tools and Productivity Enhancements
  • 39.
  • 40.
  • 44.
  • 45.
  • 46.
  • 47. © 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.