Viewing 15 posts - 1 through 15 (of 77 total)
Sue,
I had to pull the data into Excel via Oracle to get the desired output. I did however, attempt to aggregate the data into a view thinking that would...
November 21, 2017 at 11:13 am
You're correct on both fronts - posting DDL and not using Pivot. I'm working on getting the DDL together. Below is another query I wrote only works for...
November 17, 2017 at 11:51 am
Hi guys,
I can tell you following:
1. if you're connecting to AS400 from the desktop using an iSeries client, you'll need that client on the SQL server.
2. Connect to AS400 using...
January 28, 2015 at 12:14 pm
Alvin and Andrew,
Those both achieved my goal. I was having difficulty with querying against a getDate() Inserted value. The time is also captured at insert which had thrown some of...
January 19, 2015 at 1:40 pm
select
c.operator,
c.unit,
c.unitcompleted,
GR_Operator,
GR_Date,
HS_Operator,
HS_Date,
HA_Operator,
HA_Date,
case when oa.SN is not null then 'Scanned' else 'Not Scanned' end as Inspected
from
...
July 11, 2014 at 12:19 pm
Yes!!!! I ran this and returned 116207 rows in 00:00:17. Are you open to connect on LinkedIN? BTW, Thanks!
July 11, 2014 at 11:17 am
Got it!!!!! Returns the results I want but performance issues. Will create view.
select c.operator, c.unit, c.unitcompleted,
(select s.qcOperator from assemblyQC s where s.sn = c.sn) as GR_Operator,
(select s.grFPDate from assemblyQC s...
July 10, 2014 at 2:50 pm
Lynn,
Thanks! Problem found, tested and resolved.
CREATE TABLE
[dbo].[Test_completedUnit](
[unit] [nvarchar](4) NOT NULL,
[operator] [nvarchar](50) NULL,
[SN] [varchar](50) PRIMARY KEY NOT NULL,
[Workorder][varchar](7)NOT NULL
)
INSERT INTO test_completedUnit
(unit, workorder, operator, sn)
SELECT '01','17879','VERHEY, CHARLES','05201417879001' UNION ALL
SELECT '02','17879','VERHEY, CHARLES','05201417879002'...
July 10, 2014 at 11:56 am
Lynn,
Will this work? I really appreciate the assistance!!!
CREATE TABLE
[dbo].[Test_completedUnit](
[unit] [nvarchar](4) NOT NULL,
[operator] [nvarchar](50) NULL,
[SN] [varchar](50) PRIMARY KEY NOT NULL,
[Workorder][varchar](7)NOT NULL
)
INSERT INTO test_completedUnit
(unit, workorder, operator, sn)
SELECT '01','17879','VERHEY, CHARLES','05201417879001' UNION ALL
SELECT...
July 10, 2014 at 11:33 am
This gets me nearer to my results but now I'm not getting my relational data from the Inspected table. Anyway, I'm getting closer!!! On another note I'm seeing performance issues.
select...
July 9, 2014 at 1:15 pm
Getting closer......
select c.operator, c.unit, q.grfpdate, q.qcoperator, q.dateinspectedFP, hsOperator, hadateFP, haOperator,
case when c.sn = q.sn then 'Scanned' else 'Not Scanned' end Inspected
from completedUnit c
join assemblyQC q on c.sn = q.sn
where...
July 9, 2014 at 12:59 pm
Sean,
Thanks! I use that WHERE
clause for static overview type queries. I will definitely take that into consideration.
June 10, 2014 at 12:58 pm
Thanks! I worked through it resolve
select b.model,
count(case when substring(u.unitcompleted, 1,2) = '05' then 0 end) '5AM',
count(case when substring(u.unitcompleted, 1,2) = '06' then 0 end) '6AM',
count(case when substring(u.unitcompleted, 1,2) =...
June 10, 2014 at 10:55 am
Viewing 15 posts - 1 through 15 (of 77 total)