No Lock for Crystal Report XI
Printed From: Crystal Reports Book
Category: Crystal Reports 9 through 2020
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=17301
Printed Date: 02 May 2024 at 10:50am
Topic: No Lock for Crystal Report XI
Posted By: SATELE01
Subject: No Lock for Crystal Report XI
Date Posted: 13 Aug 2012 at 10:24am
Is it possible to prevent Locking on an SQL database when executing a Crystal Report and not using a "Command" as a source? Also, can a Parameter be set in a command that will allow for multiple entries?
|
Replies:
Posted By: hilfy
Date Posted: 13 Aug 2012 at 12:05pm
I don't think there's any way to prevent locking when not using a command. Yes, you can use a multi-select parameter in a command. Then syntax looks something like this: myTable.MyField in {?MyMultiParam} -Dell
------------- Proviti, Data & Analytics Practice
http://www.protiviti.com/US-en/data-management-advanced-analytics - www.protiviti.com/US-en/data-management-advanced-analytics
|
Posted By: kevlray
Date Posted: 13 Aug 2012 at 12:40pm
Since you can only do a Select (no updates, adds). Locking should not be an issue.
|
Posted By: SATELE01
Date Posted: 13 Aug 2012 at 4:14pm
OK, I have a filed called Client in table ABC How does the MUltiParam look in the Crystal Command with the talbe and field above?
|
Posted By: hilfy
Date Posted: 14 Aug 2012 at 3:13am
If this is a command, you have to create the parameter IN THE COMMAND EDITOR - it will not work if you create it in the report! The syntax would then look like this: Where ABC.Client in {?MultiParam} -Dell
------------- Proviti, Data & Analytics Practice
http://www.protiviti.com/US-en/data-management-advanced-analytics - www.protiviti.com/US-en/data-management-advanced-analytics
|
Posted By: SATELE01
Date Posted: 14 Aug 2012 at 4:38am
Thanks for the reply. Still having difficulty in getting Multiparam to work
Here is my COMMAND. Highlighted in RED is the parameter I would like to be a paramter that allows multiple entries. Can you you help me get this right.
thx
select distinct |
(SUBSTRING(right('000000000' + cast(a3.Employee_SSN as varchar),9), 1, 3) + '-' + |
SUBSTRING(right('000000000' + cast(a3.Employee_SSN as varchar ),9), 4, 2) + '-' + |
SUBSTRING(right('000000000' + cast(a3.Employee_SSN as varchar ),9), 6, 4) |
) as ssn, |
--a1.Client_ID, |
--a1.employee_id, |
a5.Plan_Desc, |
a4.Plan_Type, |
a1.Coverage_Start_Date, |
a1.Coverage_End_Date, |
a2.Employee_First_Name, |
a2.Employee_MI, |
a2.Employee_Last_Name, |
a2.Employee_Address1, |
a2.Employee_Address2, |
a2.Employee_City, |
a2.Employee_State, |
a2.Employee_Zip_Code, |
a4.* |
from dbo.Employee_Benefit (NOLOCK) a1, |
dbo.Employee(NOLOCK) a2, |
dbo.dt_Employee_Client(NOLOCK) a3, |
dbo.Employee_Benefit_Detail(NOLOCK) a4, |
dbo.Benefit_Plans(NOLOCK) a5, |
dbo.Benefit_Plans_Plan_Type(NOLOCK) a6 |
where a1.Employee_ID = a2.employee_id |
and a1.Employee_ID = a3.employee_id |
and a1.Client_ID = a3.client_id |
and a4.Employee_ID=a1.Employee_ID |
and a4.Client_ID=a1.Client_ID |
and a4.Plan_ID=a1.Plan_ID |
and a5.Plan_ID=a1.Plan_ID |
and a2.DWH_DatabaseID=a5.DWH_DatabaseID |
and a2.DWH_DatabaseID = '10000000' |
and a1.Client_ID = {?ClientID} |
and a1.Coverage_Start_Date = '2012-09-01' |
and a1.status_code='A' |
and a4.Plan_Date_ID=(select MAX(plan_date_id) as plan_date_id from |
dbo.Employee_Benefit_Detail(NOLOCK) det where |
det.Client_ID=a1.client_id and |
det.Employee_ID=a1.employee_id and |
det.Plan_ID=a1.plan_id group by |
det.plan_id,det.client_id, det.employee_id ) |
--and a1.Employee_ID='F64287' |
order by a2.Employee_Last_Name |
|
Posted By: hilfy
Date Posted: 14 Aug 2012 at 5:30am
Change the "=" to "in". -Dell
------------- Proviti, Data & Analytics Practice
http://www.protiviti.com/US-en/data-management-advanced-analytics - www.protiviti.com/US-en/data-management-advanced-analytics
|
Posted By: SATELE01
Date Posted: 14 Aug 2012 at 6:19am
Have tried changing the "=" to "in" and the Pop up comes up asking for a Client ID - entered Client ID - but when clicked OK I get a syntax error "Incorrect syntax near the entered Client ID". MY objective is to get the same option if I am not using a COMMAND that allows me to enter multiple Client ID's or one ClientID
|
|