database query : add with(nolock)
This commit is contained in:
29
SubProject/FPJ0000/dsReport.Designer.cs
generated
29
SubProject/FPJ0000/dsReport.Designer.cs
generated
@@ -7587,9 +7587,9 @@ ORDER BY yymm";
|
||||
this._commandCollection[0].Connection = this.Connection;
|
||||
this._commandCollection[0].CommandText = @"SELECT ISNULL(EETGW_GroupUser.Process, '') AS processs, JobReport.uid, Users.name AS uname, JobReport.pdate, SUM(JobReport.hrs) AS hrs, SUM(JobReport.ot) AS ot, MAX(JobReport.type)
|
||||
AS jobtype
|
||||
FROM JobReport INNER JOIN
|
||||
EETGW_GroupUser ON JobReport.gcode = EETGW_GroupUser.gcode AND JobReport.uid = EETGW_GroupUser.uid LEFT OUTER JOIN
|
||||
Users ON JobReport.uid = Users.id
|
||||
FROM JobReport WITH (nolock) INNER JOIN
|
||||
EETGW_GroupUser WITH (nolock) ON JobReport.gcode = EETGW_GroupUser.gcode AND JobReport.uid = EETGW_GroupUser.uid LEFT OUTER JOIN
|
||||
Users WITH (nolock) ON JobReport.uid = Users.id
|
||||
WHERE (SUBSTRING(JobReport.pdate, 1, 7) = @yymm) AND (JobReport.uid <> '') AND (JobReport.gcode = @gcode) AND (ISNULL(EETGW_GroupUser.Process, '') LIKE @userprocess)
|
||||
GROUP BY JobReport.uid, JobReport.pdate, Users.name, EETGW_GroupUser.Process
|
||||
ORDER BY processs, JobReport.pdate, uname";
|
||||
@@ -7798,8 +7798,9 @@ ORDER BY processs, JobReport.pdate, uname";
|
||||
this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
|
||||
this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[0].Connection = this.Connection;
|
||||
this._commandCollection[0].CommandText = "SELECT Process AS processs\r\nFROM EETGW_GroupUser\r\nWHERE (ISNULL(Process, N\'" +
|
||||
"\') <> \'\') AND (gcode = @gcode)\r\nGROUP BY Process\r\nORDER BY processs";
|
||||
this._commandCollection[0].CommandText = "SELECT Process AS processs\r\nFROM EETGW_GroupUser WITH (nolock)\r\nWHERE (ISNU" +
|
||||
"LL(Process, N\'\') <> \'\') AND (gcode = @gcode)\r\nGROUP BY Process\r\nORDER BY process" +
|
||||
"s";
|
||||
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
|
||||
this._commandCollection[0].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
}
|
||||
@@ -8011,9 +8012,9 @@ SELECT Users.id, Users.name, Users.gcode FROM Users RIGHT OUTER JOIN JobReport O
|
||||
this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[0].Connection = this.Connection;
|
||||
this._commandCollection[0].CommandText = @"SELECT Users.id, Users.name, JobReport.gcode, Users.indate, Users.outdate
|
||||
FROM EETGW_GroupUser INNER JOIN
|
||||
JobReport ON EETGW_GroupUser.gcode = JobReport.gcode AND EETGW_GroupUser.uid = JobReport.uid LEFT OUTER JOIN
|
||||
Users ON JobReport.uid = Users.id
|
||||
FROM EETGW_GroupUser WITH (nolock) INNER JOIN
|
||||
JobReport WITH (nolock) ON EETGW_GroupUser.gcode = JobReport.gcode AND EETGW_GroupUser.uid = JobReport.uid LEFT OUTER JOIN
|
||||
Users WITH (nolock) ON JobReport.uid = Users.id
|
||||
WHERE (Users.id <> 'dev') AND (Users.id <> 'test') AND (EETGW_GroupUser.Process LIKE @process) AND (JobReport.gcode = @gcode)
|
||||
GROUP BY Users.id, Users.name, JobReport.gcode, Users.indate, Users.outdate
|
||||
ORDER BY Users.name";
|
||||
@@ -8394,8 +8395,8 @@ SELECT idx, pdate, free, memo, wuid, wdate FROM HolidayLIst WHERE (idx = @idx) O
|
||||
this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
|
||||
this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[0].Connection = this.Connection;
|
||||
this._commandCollection[0].CommandText = "SELECT idx, pdate, free, memo, wuid, wdate\r\nFROM HolidayLIst\r\nWHERE (pdate " +
|
||||
"LIKE @pdate)\r\nORDER BY pdate";
|
||||
this._commandCollection[0].CommandText = "SELECT idx, pdate, free, memo, wuid, wdate\r\nFROM HolidayLIst WITH (nolock)\r\n" +
|
||||
"WHERE (pdate LIKE @pdate)\r\nORDER BY pdate";
|
||||
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
|
||||
this._commandCollection[0].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@pdate", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "pdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
}
|
||||
@@ -9040,8 +9041,8 @@ ORDER BY pdate";
|
||||
this._commandCollection[0].Connection = this.Connection;
|
||||
this._commandCollection[0].CommandText = @"SELECT MAX(JobReport.idx) AS idx, dbo.getWorkWeek(JobReport.pdate) AS ww, ISNULL(JobReport.pidx, 0) AS pidx, MAX(JobReport.projectName) AS title, ISNULL(SUM(JobReport.hrs), 0) AS hrs,
|
||||
Projects.status AS PrjStatus, Projects.name AS PrjName
|
||||
FROM JobReport LEFT OUTER JOIN
|
||||
Projects ON JobReport.pidx = Projects.idx AND JobReport.gcode = Projects.gcode
|
||||
FROM JobReport WITH (nolock) LEFT OUTER JOIN
|
||||
Projects WITH (nolock) ON JobReport.pidx = Projects.idx AND JobReport.gcode = Projects.gcode
|
||||
WHERE (JobReport.gcode = @gcode) AND (JobReport.pdate BETWEEN @sd AND @ed) AND (JobReport.uid = @uid) AND (ISNULL(JobReport.hrs, 0) > 0)
|
||||
GROUP BY dbo.getWorkWeek(JobReport.pdate), ISNULL(JobReport.pidx, 0), Projects.name, Projects.status
|
||||
ORDER BY title, ww";
|
||||
@@ -9286,8 +9287,8 @@ ORDER BY title, ww";
|
||||
EETGW_ProjectsSchedule.no, EETGW_ProjectsSchedule.seq, EETGW_ProjectsSchedule.title, EETGW_ProjectsSchedule.uid, EETGW_ProjectsSchedule.sw, EETGW_ProjectsSchedule.ew,
|
||||
EETGW_ProjectsSchedule.swa, EETGW_ProjectsSchedule.ewa, Projects.sdate, Projects.ddate, EETGW_ProjectsSchedule.complete, EETGW_ProjectsSchedule.uidname,
|
||||
EETGW_ProjectsSchedule.progress, Projects.userprocess, Projects.status
|
||||
FROM Projects LEFT OUTER JOIN
|
||||
EETGW_ProjectsSchedule ON Projects.gcode = EETGW_ProjectsSchedule.gcode AND Projects.idx = EETGW_ProjectsSchedule.project
|
||||
FROM Projects WITH (nolock) LEFT OUTER JOIN
|
||||
EETGW_ProjectsSchedule WITH (nolock) ON Projects.gcode = EETGW_ProjectsSchedule.gcode AND Projects.idx = EETGW_ProjectsSchedule.project
|
||||
WHERE (Projects.gcode = @gcode) AND (Projects.status = '검토' OR
|
||||
Projects.status = '진행') AND (ISNULL(Projects.isdel, 0) = 0) AND (dbo.getLastProjectScheduleNo(Projects.gcode, Projects.idx) = EETGW_ProjectsSchedule.no) AND
|
||||
(EETGW_ProjectsSchedule.uid LIKE @uidlike)
|
||||
|
||||
Reference in New Issue
Block a user