Salesforce SOQL is not working same as SQL, Why?
- Salesforce using Multitenant Architecture – Many organization using single instance including database but each org will have their own virtual hardware.
- Salesforce using platform – It is metadata-driven architecture.
- SOQL directly integrated with Apex no need to establish the connection to the database.
Force.com platform having the governor limits to allow the access Multitenant Architecture
Differences between SOQL and SQL
- It supports only SELECT statements.
- we can not include all columns at a time(Does not support SELECT * (must specify fields to include).
- It supports only “relationship queries,” which are written using parent-child syntax
- It supports the dot notation syntax to traverse table relationships.
- It is governed by LIMITS(e.g., returned rows, heap, etc.)
- It Supports statements for DML, transaction control, and SELECT statements.
- It Support SELECT * (include all columns)
- It Support joins, which are written using “left,” “right,” "inner," "outer" syntax.
- It does not support dot notation syntax to traverse table relationships.
- No governer Limits.
Let us know if you have any queries.