SlideShare a Scribd company logo

ORMs Meet SQL

ORMs Meet SQL presentation for Tuga IT 2016

1 of 22
Download to read offline
TUGA IT 2016
LISBON, PORTUGAL
THANK YOU TO OUR
SPONSORS
THANK YOU TO OUR
TEAM
ANDRÉ BATISTA ANDRÉ MELANCIA ANDRÉ VALA ANTÓNIO LOURENÇO BRUNO LOPES CLÁUDIO SILVA
NIKO NEUGEBAUER
RUI REISRICARDO CABRAL
NUNO CANCELO PAULO MATOS PEDRO SIMÕES
SANDRA MORGADO SANDRO PEREIRARUI BASTOS
NUNO ÁRIAS SILVA
ORMs Meet SQL
Ricardo Peres
@rjperes75
About Me
• Technical Evangelist at Simplifydigital (UK)
• Microsoft MVP, Visual Studio and Development Technologies
• Blogger
@rjperes75
rjperes@hotmail.com
http://weblogs.asp.net/ricardoperes
Agenda
• ORMs: The Good Parts
• The Problem
• How ORMs Try to Solve It
• Case Studies
• NHibernate and Entity Framework
• Micro ORMs
• Conclusion
• Food for Thought
Ad

Recommended

Java Programming Important Topics
Java Programming Important Topics Java Programming Important Topics
Java Programming Important Topics SANJAYMANVATKAR1
 
Common issues, rules and principles
Common issues,  rules and principlesCommon issues,  rules and principles
Common issues, rules and principlesMnats Karakhanyan
 
How I Learned To Stop Worrying (And Love The KiCad)
How I Learned To Stop Worrying (And Love The KiCad)How I Learned To Stop Worrying (And Love The KiCad)
How I Learned To Stop Worrying (And Love The KiCad)ChrisGammell
 

More Related Content

What's hot

20200115 admin group_networking_party_v2
20200115 admin group_networking_party_v220200115 admin group_networking_party_v2
20200115 admin group_networking_party_v2Jihun Jung
 
Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...
Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...
Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...appleseeds-my
 
Object Oriented Programming in Swift Ch0 - Encapsulation
Object Oriented Programming in Swift Ch0 - EncapsulationObject Oriented Programming in Swift Ch0 - Encapsulation
Object Oriented Programming in Swift Ch0 - EncapsulationChihyang Li
 
Introduction to java
Introduction to javaIntroduction to java
Introduction to javaAhmed Abbadi
 
Introduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design PrinciplesIntroduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design PrinciplesMichael Redlich
 
Introduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design PrinciplesIntroduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design PrinciplesMichael Redlich
 
OSGi Community Event 2010 - OSGi and Android
OSGi Community Event 2010 - OSGi and AndroidOSGi Community Event 2010 - OSGi and Android
OSGi Community Event 2010 - OSGi and Androidmfrancis
 
How to write test in node.js
How to write test in node.jsHow to write test in node.js
How to write test in node.jsJason Lin
 

What's hot (9)

20200115 admin group_networking_party_v2
20200115 admin group_networking_party_v220200115 admin group_networking_party_v2
20200115 admin group_networking_party_v2
 
Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...
Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...
Optimizing Laravel for content heavy and high-traffic websites by Man, Apples...
 
Object Oriented Programming in Swift Ch0 - Encapsulation
Object Oriented Programming in Swift Ch0 - EncapsulationObject Oriented Programming in Swift Ch0 - Encapsulation
Object Oriented Programming in Swift Ch0 - Encapsulation
 
Introduction to java
Introduction to javaIntroduction to java
Introduction to java
 
Introduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design PrinciplesIntroduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design Principles
 
Introduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design PrinciplesIntroduction to Object Oriented Programming & Design Principles
Introduction to Object Oriented Programming & Design Principles
 
OSGi Community Event 2010 - OSGi and Android
OSGi Community Event 2010 - OSGi and AndroidOSGi Community Event 2010 - OSGi and Android
OSGi Community Event 2010 - OSGi and Android
 
Scala days mizushima
Scala days mizushimaScala days mizushima
Scala days mizushima
 
How to write test in node.js
How to write test in node.jsHow to write test in node.js
How to write test in node.js
 

Viewers also liked

Pecha Kucha Rene
Pecha Kucha RenePecha Kucha Rene
Pecha Kucha Reneguestcbb062
 
Presentation On Edf 2005
Presentation On Edf 2005Presentation On Edf 2005
Presentation On Edf 2005stewart2008sem3
 
Presentación1
Presentación1Presentación1
Presentación1alumne3ESO
 
Web app first scan
Web app first scanWeb app first scan
Web app first scanAlex Vetrov
 
Sma tee adapter female female female
Sma tee adapter female female femaleSma tee adapter female female female
Sma tee adapter female female femaleChetan Shah
 
Sma female to reverse polarity sma male adapter
Sma female to reverse polarity sma male adapterSma female to reverse polarity sma male adapter
Sma female to reverse polarity sma male adapterChetan Shah
 
Enrique rojas-el-hombre-light
Enrique rojas-el-hombre-lightEnrique rojas-el-hombre-light
Enrique rojas-el-hombre-lightCarolina Diaz
 
Building Enterprise Search Engines using Open Source Technologies
Building Enterprise Search Engines using Open Source TechnologiesBuilding Enterprise Search Engines using Open Source Technologies
Building Enterprise Search Engines using Open Source TechnologiesAnant Corporation
 
Log Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar SeriesLog Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar SeriesAmazon Web Services
 
A Retrospective Study to Investigate Association among Age, BMI and BMD in th...
A Retrospective Study to Investigate Association among Age, BMI and BMD in th...A Retrospective Study to Investigate Association among Age, BMI and BMD in th...
A Retrospective Study to Investigate Association among Age, BMI and BMD in th...IOSR Journals
 

Viewers also liked (16)

Pecha Kucha Rene
Pecha Kucha RenePecha Kucha Rene
Pecha Kucha Rene
 
Avisos
AvisosAvisos
Avisos
 
Presentation On Edf 2005
Presentation On Edf 2005Presentation On Edf 2005
Presentation On Edf 2005
 
Presentación1
Presentación1Presentación1
Presentación1
 
Web app first scan
Web app first scanWeb app first scan
Web app first scan
 
Sma tee adapter female female female
Sma tee adapter female female femaleSma tee adapter female female female
Sma tee adapter female female female
 
Piscina
PiscinaPiscina
Piscina
 
Sma female to reverse polarity sma male adapter
Sma female to reverse polarity sma male adapterSma female to reverse polarity sma male adapter
Sma female to reverse polarity sma male adapter
 
Elasticsearch
ElasticsearchElasticsearch
Elasticsearch
 
GLIIFCA 22 final (1)
GLIIFCA 22 final (1)GLIIFCA 22 final (1)
GLIIFCA 22 final (1)
 
Bomba Jacuzzi Série F-G
Bomba Jacuzzi Série F-GBomba Jacuzzi Série F-G
Bomba Jacuzzi Série F-G
 
Enrique rojas-el-hombre-light
Enrique rojas-el-hombre-lightEnrique rojas-el-hombre-light
Enrique rojas-el-hombre-light
 
Building Enterprise Search Engines using Open Source Technologies
Building Enterprise Search Engines using Open Source TechnologiesBuilding Enterprise Search Engines using Open Source Technologies
Building Enterprise Search Engines using Open Source Technologies
 
Log Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar SeriesLog Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar Series
 
KOOS-BMECTE
KOOS-BMECTEKOOS-BMECTE
KOOS-BMECTE
 
A Retrospective Study to Investigate Association among Age, BMI and BMD in th...
A Retrospective Study to Investigate Association among Age, BMI and BMD in th...A Retrospective Study to Investigate Association among Age, BMI and BMD in th...
A Retrospective Study to Investigate Association among Age, BMI and BMD in th...
 

Similar to ORMs Meet SQL

Scaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHPScaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHP120bi
 
Scaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsScaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsAchievers Tech
 
Why databases cry at night
Why databases cry at nightWhy databases cry at night
Why databases cry at nightMichael Yarichuk
 
The economies of scaling software - Abdel Remani
The economies of scaling software - Abdel RemaniThe economies of scaling software - Abdel Remani
The economies of scaling software - Abdel Remanijaxconf
 
The Economies of Scaling Software
The Economies of Scaling SoftwareThe Economies of Scaling Software
The Economies of Scaling SoftwareAbdelmonaim Remani
 
Babysitting your orm essenmacher, adam
Babysitting your orm   essenmacher, adamBabysitting your orm   essenmacher, adam
Babysitting your orm essenmacher, adamAdam Essenmacher
 
ITB2017 - Slaying the ORM dragons with cborm
ITB2017 - Slaying the ORM dragons with cbormITB2017 - Slaying the ORM dragons with cborm
ITB2017 - Slaying the ORM dragons with cbormOrtus Solutions, Corp
 
Hard Coding as a design approach
Hard Coding as a design approachHard Coding as a design approach
Hard Coding as a design approachOren Eini
 
MySQL Optimization from a Developer's point of view
MySQL Optimization from a Developer's point of viewMySQL Optimization from a Developer's point of view
MySQL Optimization from a Developer's point of viewSachin Khosla
 
Big Data! Great! Now What? #SymfonyCon 2014
Big Data! Great! Now What? #SymfonyCon 2014Big Data! Great! Now What? #SymfonyCon 2014
Big Data! Great! Now What? #SymfonyCon 2014Ricard Clau
 
Introduction to Machine Learning for Oracle Database Professionals
Introduction to Machine Learning for Oracle Database ProfessionalsIntroduction to Machine Learning for Oracle Database Professionals
Introduction to Machine Learning for Oracle Database ProfessionalsAlex Gorbachev
 
20140228 fp and_performance
20140228 fp and_performance20140228 fp and_performance
20140228 fp and_performanceshinolajla
 
Fontys Lecture - The Evolution of the Oracle Database 2016
Fontys Lecture -  The Evolution of the Oracle Database 2016Fontys Lecture -  The Evolution of the Oracle Database 2016
Fontys Lecture - The Evolution of the Oracle Database 2016Lucas Jellema
 
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...BIWUG
 
Dev buchan 30 proven tips
Dev buchan 30 proven tipsDev buchan 30 proven tips
Dev buchan 30 proven tipsBill Buchan
 
Ideas spracklen-final
Ideas spracklen-finalIdeas spracklen-final
Ideas spracklen-finalsupportlogic
 

Similar to ORMs Meet SQL (20)

The tortoise and the ORM
The tortoise and the ORMThe tortoise and the ORM
The tortoise and the ORM
 
Scaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHPScaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHP
 
Scaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsScaling High Traffic Web Applications
Scaling High Traffic Web Applications
 
Why databases cry at night
Why databases cry at nightWhy databases cry at night
Why databases cry at night
 
The economies of scaling software - Abdel Remani
The economies of scaling software - Abdel RemaniThe economies of scaling software - Abdel Remani
The economies of scaling software - Abdel Remani
 
The Economies of Scaling Software
The Economies of Scaling SoftwareThe Economies of Scaling Software
The Economies of Scaling Software
 
Babysitting your orm essenmacher, adam
Babysitting your orm   essenmacher, adamBabysitting your orm   essenmacher, adam
Babysitting your orm essenmacher, adam
 
Breaking data
Breaking dataBreaking data
Breaking data
 
ORM Methodology
ORM MethodologyORM Methodology
ORM Methodology
 
Clean code
Clean codeClean code
Clean code
 
ITB2017 - Slaying the ORM dragons with cborm
ITB2017 - Slaying the ORM dragons with cbormITB2017 - Slaying the ORM dragons with cborm
ITB2017 - Slaying the ORM dragons with cborm
 
Hard Coding as a design approach
Hard Coding as a design approachHard Coding as a design approach
Hard Coding as a design approach
 
MySQL Optimization from a Developer's point of view
MySQL Optimization from a Developer's point of viewMySQL Optimization from a Developer's point of view
MySQL Optimization from a Developer's point of view
 
Big Data! Great! Now What? #SymfonyCon 2014
Big Data! Great! Now What? #SymfonyCon 2014Big Data! Great! Now What? #SymfonyCon 2014
Big Data! Great! Now What? #SymfonyCon 2014
 
Introduction to Machine Learning for Oracle Database Professionals
Introduction to Machine Learning for Oracle Database ProfessionalsIntroduction to Machine Learning for Oracle Database Professionals
Introduction to Machine Learning for Oracle Database Professionals
 
20140228 fp and_performance
20140228 fp and_performance20140228 fp and_performance
20140228 fp and_performance
 
Fontys Lecture - The Evolution of the Oracle Database 2016
Fontys Lecture -  The Evolution of the Oracle Database 2016Fontys Lecture -  The Evolution of the Oracle Database 2016
Fontys Lecture - The Evolution of the Oracle Database 2016
 
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...
 
Dev buchan 30 proven tips
Dev buchan 30 proven tipsDev buchan 30 proven tips
Dev buchan 30 proven tips
 
Ideas spracklen-final
Ideas spracklen-finalIdeas spracklen-final
Ideas spracklen-final
 

More from Ricardo Peres

Microsoft Embracing Open Source Technologies
Microsoft Embracing Open Source TechnologiesMicrosoft Embracing Open Source Technologies
Microsoft Embracing Open Source TechnologiesRicardo Peres
 
Entity Framework 7: What's New?
Entity Framework 7: What's New?Entity Framework 7: What's New?
Entity Framework 7: What's New?Ricardo Peres
 
Microsoft ♥ Open Source
Microsoft ♥ Open SourceMicrosoft ♥ Open Source
Microsoft ♥ Open SourceRicardo Peres
 
Software Developer's Journal - 02/2012
Software Developer's Journal - 02/2012Software Developer's Journal - 02/2012
Software Developer's Journal - 02/2012Ricardo Peres
 
TechDays 2010 - Introdução ao NHibernate
TechDays 2010 - Introdução ao NHibernateTechDays 2010 - Introdução ao NHibernate
TechDays 2010 - Introdução ao NHibernateRicardo Peres
 
SharePoint 2010 Business Connectivity Services - Introdução
SharePoint 2010 Business Connectivity Services - IntroduçãoSharePoint 2010 Business Connectivity Services - Introdução
SharePoint 2010 Business Connectivity Services - IntroduçãoRicardo Peres
 
MVP Showcase 2015 - Entity Framework 7 - NoORM
MVP Showcase 2015 - Entity Framework 7 - NoORMMVP Showcase 2015 - Entity Framework 7 - NoORM
MVP Showcase 2015 - Entity Framework 7 - NoORMRicardo Peres
 

More from Ricardo Peres (11)

EF Core 7
EF Core 7EF Core 7
EF Core 7
 
Elasticsearch
ElasticsearchElasticsearch
Elasticsearch
 
Microsoft Embracing Open Source Technologies
Microsoft Embracing Open Source TechnologiesMicrosoft Embracing Open Source Technologies
Microsoft Embracing Open Source Technologies
 
Elasticsearch
ElasticsearchElasticsearch
Elasticsearch
 
Entity Framework 7: What's New?
Entity Framework 7: What's New?Entity Framework 7: What's New?
Entity Framework 7: What's New?
 
Entity Framework 7
Entity Framework 7Entity Framework 7
Entity Framework 7
 
Microsoft ♥ Open Source
Microsoft ♥ Open SourceMicrosoft ♥ Open Source
Microsoft ♥ Open Source
 
Software Developer's Journal - 02/2012
Software Developer's Journal - 02/2012Software Developer's Journal - 02/2012
Software Developer's Journal - 02/2012
 
TechDays 2010 - Introdução ao NHibernate
TechDays 2010 - Introdução ao NHibernateTechDays 2010 - Introdução ao NHibernate
TechDays 2010 - Introdução ao NHibernate
 
SharePoint 2010 Business Connectivity Services - Introdução
SharePoint 2010 Business Connectivity Services - IntroduçãoSharePoint 2010 Business Connectivity Services - Introdução
SharePoint 2010 Business Connectivity Services - Introdução
 
MVP Showcase 2015 - Entity Framework 7 - NoORM
MVP Showcase 2015 - Entity Framework 7 - NoORMMVP Showcase 2015 - Entity Framework 7 - NoORM
MVP Showcase 2015 - Entity Framework 7 - NoORM
 

Recently uploaded

killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이
killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이
killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이ssuser82c38d
 
"Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A...
"Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A..."Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A...
"Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A...ISPMAIndia
 
Steps to Build a PWA with Odoo.pdf
Steps to Build a PWA with Odoo.pdfSteps to Build a PWA with Odoo.pdf
Steps to Build a PWA with Odoo.pdfayushinwizards
 
Embracing Change - The Impact of Generative AI on Strategic Portfolio Management
Embracing Change - The Impact of Generative AI on Strategic Portfolio ManagementEmbracing Change - The Impact of Generative AI on Strategic Portfolio Management
Embracing Change - The Impact of Generative AI on Strategic Portfolio ManagementOnePlan Solutions
 
Manual de la Mezcladora SoundCraft Notepad -12Fx
Manual de la Mezcladora SoundCraft Notepad -12FxManual de la Mezcladora SoundCraft Notepad -12Fx
Manual de la Mezcladora SoundCraft Notepad -12Fxjavierdavidvelasco17
 
SPM 2024 – Overview of and benefits of AI in Product Management
SPM 2024 – Overview of and benefits of AI in Product ManagementSPM 2024 – Overview of and benefits of AI in Product Management
SPM 2024 – Overview of and benefits of AI in Product ManagementISPMAIndia
 
OpenChain AI Study Group - North America and Europe - 2024-02-20
OpenChain AI Study Group - North America and Europe - 2024-02-20OpenChain AI Study Group - North America and Europe - 2024-02-20
OpenChain AI Study Group - North America and Europe - 2024-02-20Shane Coughlan
 
AUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdf
AUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdfAUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdf
AUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdfAutokey
 
P1 Inspection Types in Municity 5 Smartsheet
P1 Inspection Types in Municity 5 SmartsheetP1 Inspection Types in Municity 5 Smartsheet
P1 Inspection Types in Municity 5 SmartsheetMatthewTHawley
 
DBA Fundamentals Group: Continuous SQL with Kafka and Flink
DBA Fundamentals Group: Continuous SQL with Kafka and FlinkDBA Fundamentals Group: Continuous SQL with Kafka and Flink
DBA Fundamentals Group: Continuous SQL with Kafka and FlinkTimothy Spann
 
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)GDSCNiT
 
killing camp week 6 problem - maximal matrix.pdf
killing camp week 6 problem - maximal matrix.pdfkilling camp week 6 problem - maximal matrix.pdf
killing camp week 6 problem - maximal matrix.pdfssuser82c38d
 
The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...
The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...
The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...emili denli
 
Sql server types of joins with example.pptx
Sql server types of joins with example.pptxSql server types of joins with example.pptx
Sql server types of joins with example.pptxsameer gaikwad
 
AI Product Management by Abhijit Bendigiri
AI Product Management by Abhijit BendigiriAI Product Management by Abhijit Bendigiri
AI Product Management by Abhijit BendigiriISPMAIndia
 
Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...
Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...
Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...ISPMAIndia
 
sql ppt for students who preparing for sql
sql ppt for students who preparing for sqlsql ppt for students who preparing for sql
sql ppt for students who preparing for sqlbharatjanadharwarud
 
The Age of AI: Elevating Experiences & Delivering Customer Value!
The Age of AI: Elevating Experiences & Delivering Customer Value!The Age of AI: Elevating Experiences & Delivering Customer Value!
The Age of AI: Elevating Experiences & Delivering Customer Value!ISPMAIndia
 
Essence of Requirements Engineering: Pragmatic Insights for 2024
Essence of Requirements Engineering: Pragmatic Insights for 2024Essence of Requirements Engineering: Pragmatic Insights for 2024
Essence of Requirements Engineering: Pragmatic Insights for 2024Asher Sterkin
 

Recently uploaded (20)

killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이
killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이
killingcamp 광고삽입문제 풀이, killingcamp 광고삽입문제 풀이
 
"Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A...
"Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A..."Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A...
"Discovery and Delivery through Product IntelliGenAI framework" by Ramkumar A...
 
Steps to Build a PWA with Odoo.pdf
Steps to Build a PWA with Odoo.pdfSteps to Build a PWA with Odoo.pdf
Steps to Build a PWA with Odoo.pdf
 
Features of IETM Software -Code and Pixels
Features of IETM Software -Code and PixelsFeatures of IETM Software -Code and Pixels
Features of IETM Software -Code and Pixels
 
Embracing Change - The Impact of Generative AI on Strategic Portfolio Management
Embracing Change - The Impact of Generative AI on Strategic Portfolio ManagementEmbracing Change - The Impact of Generative AI on Strategic Portfolio Management
Embracing Change - The Impact of Generative AI on Strategic Portfolio Management
 
Manual de la Mezcladora SoundCraft Notepad -12Fx
Manual de la Mezcladora SoundCraft Notepad -12FxManual de la Mezcladora SoundCraft Notepad -12Fx
Manual de la Mezcladora SoundCraft Notepad -12Fx
 
SPM 2024 – Overview of and benefits of AI in Product Management
SPM 2024 – Overview of and benefits of AI in Product ManagementSPM 2024 – Overview of and benefits of AI in Product Management
SPM 2024 – Overview of and benefits of AI in Product Management
 
OpenChain AI Study Group - North America and Europe - 2024-02-20
OpenChain AI Study Group - North America and Europe - 2024-02-20OpenChain AI Study Group - North America and Europe - 2024-02-20
OpenChain AI Study Group - North America and Europe - 2024-02-20
 
AUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdf
AUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdfAUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdf
AUTOKEYUNLOCKER-BRANDS-SUPPORT-STANDARD-VERSION.pdf
 
P1 Inspection Types in Municity 5 Smartsheet
P1 Inspection Types in Municity 5 SmartsheetP1 Inspection Types in Municity 5 Smartsheet
P1 Inspection Types in Municity 5 Smartsheet
 
DBA Fundamentals Group: Continuous SQL with Kafka and Flink
DBA Fundamentals Group: Continuous SQL with Kafka and FlinkDBA Fundamentals Group: Continuous SQL with Kafka and Flink
DBA Fundamentals Group: Continuous SQL with Kafka and Flink
 
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
 
killing camp week 6 problem - maximal matrix.pdf
killing camp week 6 problem - maximal matrix.pdfkilling camp week 6 problem - maximal matrix.pdf
killing camp week 6 problem - maximal matrix.pdf
 
The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...
The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...
The Game-Changer_ How Software Development Outsource Can Catapult Your Growth...
 
Sql server types of joins with example.pptx
Sql server types of joins with example.pptxSql server types of joins with example.pptx
Sql server types of joins with example.pptx
 
AI Product Management by Abhijit Bendigiri
AI Product Management by Abhijit BendigiriAI Product Management by Abhijit Bendigiri
AI Product Management by Abhijit Bendigiri
 
Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...
Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...
Product Manager vs Product Owner – Why Do Companies Still Struggle 23 Years A...
 
sql ppt for students who preparing for sql
sql ppt for students who preparing for sqlsql ppt for students who preparing for sql
sql ppt for students who preparing for sql
 
The Age of AI: Elevating Experiences & Delivering Customer Value!
The Age of AI: Elevating Experiences & Delivering Customer Value!The Age of AI: Elevating Experiences & Delivering Customer Value!
The Age of AI: Elevating Experiences & Delivering Customer Value!
 
Essence of Requirements Engineering: Pragmatic Insights for 2024
Essence of Requirements Engineering: Pragmatic Insights for 2024Essence of Requirements Engineering: Pragmatic Insights for 2024
Essence of Requirements Engineering: Pragmatic Insights for 2024
 

ORMs Meet SQL

  • 2. THANK YOU TO OUR SPONSORS
  • 3. THANK YOU TO OUR TEAM ANDRÉ BATISTA ANDRÉ MELANCIA ANDRÉ VALA ANTÓNIO LOURENÇO BRUNO LOPES CLÁUDIO SILVA NIKO NEUGEBAUER RUI REISRICARDO CABRAL NUNO CANCELO PAULO MATOS PEDRO SIMÕES SANDRA MORGADO SANDRO PEREIRARUI BASTOS NUNO ÁRIAS SILVA
  • 4. ORMs Meet SQL Ricardo Peres @rjperes75
  • 5. About Me • Technical Evangelist at Simplifydigital (UK) • Microsoft MVP, Visual Studio and Development Technologies • Blogger @rjperes75 rjperes@hotmail.com http://weblogs.asp.net/ricardoperes
  • 6. Agenda • ORMs: The Good Parts • The Problem • How ORMs Try to Solve It • Case Studies • NHibernate and Entity Framework • Micro ORMs • Conclusion • Food for Thought
  • 7. ORMs: The Good Parts ORMs are good at a number of things: • Abstracting away databases and database-specific mechanisms (e.g., IDENTITY, sequences) • Shielding us from database changes (e.g., using mappings) • Ids are properly handled and propagated to children • Avoiding writing tedious and repeating SQL (e.g., SQL is generated for us) • Transactions and concurrency management is done for us • Enforcing usage of good patterns (e.g., using parameters, no *) • Embracing language-specific idioms and patterns (e.g., LINQ) • Detecting changes for us (in entities and in model) • Allow for complex scenarios that are not supported in relational databases (e.g., inheritance) • Permit focusing on the language that developers are more proficient at (e.g., Java, C#) – enter Domain Driven Design • Fast to get things working (e.g., CRUDs, lists, binding)
  • 8. The Problem (1 of 2) It is generally accepted that ORMs make our lifes, as developers, easier, but… • SQL produced by ORMs is usually far from optimal / fast This is usually because of the need for generic querying avoiding DB-specific mechanisms • Hiding complexity is not always a good thing ORMs do somewhat complex stuff and make it seem simple • Not meant to be used for everything “If all you have is a hammer, everything looks like a nail” ETL, reporting are two exemples of bad usage
  • 9. The Problem (2 of 2) It turns out that: • SQL is still the most powerful way to perform queries in relational databases ORMs generally avoid advanced SQL • Abstraction loses database-specific features Lowest common denominator • Generated schemas still require intervention / maintenance DBAs are still required to tune the generated schemas, enforce conventions, generate indexes, etc
  • 10. How ORMs Try to Solve It (1 of 5) • Two workflows: • Database first – ORMs can adapt to what is already there • Code first – It is possible to influence or bypass ORM functionality • Some ORM features may come handy: • Custom SQL • Schema hints • Lazy and eager loading • Batching • Cache • Optimistic concurrency
  • 11. How ORMs Try to Solve It (2 of 5) Custom SQL • It is possible to load, save, update and delete entities from user-supplied SQL, even stored procedures Index creation hints • Besides primary keys, it is possible to tell ORMs to generate indexes for certain columns
  • 12. How ORMs Try to Solve It (3 of 5) Lazy loading and lazy properties • References (one-to-one, many- to-one, one-to-many, many-to- many) are only loaded when and if necessary • Even simple properties can be loaded on demand (e.g., CLOB, BLOB) Eager loading • It is possible to request that entity references be loaded together with the main entity
  • 13. How ORMs Try to Solve It (4 of 5) Batching queries • ORMs can send together several queries at once (both CUDs and queries) Batch loading • When one loads a collection in a loaded entity, up to N collections in other loaded entities are loaded too
  • 14. How ORMs Try to Solve It (5 of 5) Cache • First and second level caches means that we don’t even have to go to the database Optimistic concurrency • Either a specific column or a set of columns can be used for detecting changes transparently
  • 15. Case Study: NHibernate and Entity Framework NHibernate • Mature and proven • Lots of features • Many supported databases • Steeper learning curve • No documentation • Poor community support Entity Framework • Good integration with MS prods • Is getting better on every version • Good documentation • Unstable • Less features • Only works well with SQL Server
  • 16. Case Study: NHibernate and Entity Framework Feature NHibernate Entity Framework Index creation hints X X Lazy loading X X Eager loading X X Lazy properties X Custom SQL X X Batching CUDs X X Batching queries X Batch loading X Cache X X Optimistic concurrency X X
  • 17. Case Study: Micro ORMs • Micro ORMs do not attempt to be feature-rich • Simple, sometimes it’s a single code file • Fast • No advanced features • You still have to write your own SQL - no native querying (e.g., LINQ) • Stuck to conventions for mapping
  • 18. Conclusion • ORMs are good to have at hand, but may not always be the best solution • Know your requirements • Explore your ORM and get to know its full potential • Use the best tool for the job at hand • Understand what is going on underneath • DBAs are not your enemies – learn from them! • Learn SQL
  • 19. Food for Thought • Ten advantages of an ORM • The Vietnam of Computer Science • When Should I Use An ORM? • Why debate politics when you can just blog about ORMs? • What ORMs have taught me: just learn SQL • Reply to "What ORMs have taught me: just learn SQL“ • ORM is an anti-pattern • ORM Is an Offensive Anti-Pattern • ORM Haters Don’t Get It
  • 21. Thank You! Let me hear from you!
  • 22. THANK YOU TO OUR SPONSORS