Using raw sql in django python
You need to use the database's table and field names in the raw query--the string you provide will be passed to the database, not interpreted by the Django ORM.
I have few things to ask for custom queries in Django

DO i need to use the DB table name in the query or just the Model name
if i need to join the various tables in raw sql. do i need to use db field name or model field name like

Person.objects.raw('SELECT id, first_name, last_name, birth_date FROM Person A
inner join Address B on A.address  = B.id
')
or B.id = A.address_id