Hi Puneet,



      Schema :


                                Primary Key


                                Foreign Keys






                Column_Name                 Type_name


                PK                                           Varchar

                C_Id                                       Varchar





                Column_Name                 Type_name


                PK                                           Varchar

                A_Id                                      Varchar

                A_C_Id                                 Varchar




                Column_Name                 Type_name


                PK                                           Varchar

                O_Id                                      Varchar

O_C_Id                                 Varchar




                Column_Name                 Type_name


                PK                                           Varchar

                O_D_Id                                Varchar

                O_Id                                      Varchar               







          Query :



                select /*+ NO_STAR_JOIN */ c."C_Name",a."City",a."State" from "Address_1" WITH(NOLOCK) as a

inner join "Customers_1" WITH(NOLOCK) as c on a."A_C_Id" = c."C_Id"

inner join "Orders_1" WITH(NOLOCK) as o on a."A_C_Id" = o."O_C_Id"

inner join "Order_Details_1" WITH(NOLOCK) as od on od."O_Id" = o."O_Id"

inner join "Payterms_1" WITH(NOLOCK) as p on p."Payt_Id" = o."O_Pay_Terms"

inner join "Shipterms_1" WITH(NOLOCK) as s on s."Shipt_Id" = o."O_Ship_Terms"

where c."C_Id" = '150'


please let us know if we can ensure NO LOCK functionality .








From: Puneet Kumar Ojha [mailto:puneet.kumar@pubmatic.com]
Sent: Thursday, December 04, 2014 9:33 PM
To: user@phoenix.apache.org
Subject: RE: No Lock hint in phoenix


Hi Siddharth,


Can you send all the queries which may run on the tables.


Also if you can send the schema of the tables created on Phoenix, I may help you out.





From: Siddharth Ubale [mailto:siddharth.ubale@syncoms.com]
Sent: Thursday, December 04, 2014 7:28 PM
To: user@phoenix.apache.org
Subject: No Lock hint in phoenix


Hi ,


We are running queries in Phoenix and getting a very high latency. Since we are using Phoenix more on reporting tables and not on transactional tables, we were wondering whether it is possible to run a query using the “ with (NO LOCK) “ hint  so that we can increase the response times for queries.


A sample SQL query like this is what we aim to run using Phoenix :


FROM dbo.person p WITH (NOLOCK)
JOIN dbo.employee e WITH (NOLOCK)
ON e.person_id = p.person_id
WHERE p.person_id = 1;


Is this possible to achieve in Phoenix?




Siddharth Ubale,