473,388 Members | 1,417 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

Using DMax "a hard one"

I am in need of help for a problem using Dmax to find out the cycle
time of a machine which was running for an 8 hour shift "BUT" the
cycle time is changing for what was on the machine for that period.

I have set up using a union query the to show the following:-

what i would like it to do is work out the "max" cycle time for a
given period for which it ran up to when it changes = of
(Start/finish)
JOB Ref Time ON-OFF Cycle time

100 07:00 ON 1.5
200 07:00 0N 1.3
300 07:00 0N 1.5
100 10:00 OF.... 1.5 .......Max 1.5
400 10:15 ON 2.5
200 15:00 OF .... 1.3........Max 2.5
300 15:00 OF .... 1.5........Max 2.5
400 15:00 OF .... 2.5 .......Max 2.5
Is this possible or am i going at it totally wrong! any other options

appreciate any help

Thanks...
Nov 13 '05 #1
2 1573

"Alex" <ge****@yas1.freeserve.co.uk> escreveu na mensagem
news:b7**************************@posting.google.c om...
I am in need of help for a problem using Dmax to find out the cycle
time of a machine which was running for an 8 hour shift "BUT" the
cycle time is changing for what was on the machine for that period.

I have set up using a union query the to show the following:-

what i would like it to do is work out the "max" cycle time for a
given period for which it ran up to when it changes = of
(Start/finish)
JOB Ref Time ON-OFF Cycle time

100 07:00 ON 1.5
200 07:00 0N 1.3
300 07:00 0N 1.5
100 10:00 OF.... 1.5 .......Max 1.5
400 10:15 ON 2.5
200 15:00 OF .... 1.3........Max 2.5
300 15:00 OF .... 1.5........Max 2.5
400 15:00 OF .... 2.5 .......Max 2.5
Is this possible or am i going at it totally wrong! any other options

appreciate any help

Thanks...


Hi,
as you have an union query, say [union_query],

instead Dmax, an alternative way would be with a query that retrieves the
max Cycle Time with a subquery, something like

Select *,

(SELECT Max([Cycle Time]) FROM [union_query] As UQ
WHERE [union_query].ON-OFF = 'OF'
AND UQ.[Ref Time] <= [union_query].[Ref Time]) As [Cycle Time]

FROM [union_query]

Hope my english makes sense :)

Roberto


Nov 13 '05 #2
Not sure I understand what you are asking for...

Can you post your desired result set? Are you looking for a single
value or multiple values? How are you using the results?

ge****@yas1.freeserve.co.uk (Alex) wrote in message news:<b7**************************@posting.google. com>...
I am in need of help for a problem using Dmax to find out the cycle
time of a machine which was running for an 8 hour shift "BUT" the
cycle time is changing for what was on the machine for that period.

I have set up using a union query the to show the following:-

what i would like it to do is work out the "max" cycle time for a
given period for which it ran up to when it changes = of
(Start/finish)
JOB Ref Time ON-OFF Cycle time

100 07:00 ON 1.5
200 07:00 0N 1.3
300 07:00 0N 1.5
100 10:00 OF.... 1.5 .......Max 1.5
400 10:15 ON 2.5
200 15:00 OF .... 1.3........Max 2.5
300 15:00 OF .... 1.5........Max 2.5
400 15:00 OF .... 2.5 .......Max 2.5
Is this possible or am i going at it totally wrong! any other options

appreciate any help

Thanks...

Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Robert Brewer | last post by:
Paul Moore wrote: > ...I *can* defend an argument that the proposal must > take a stance on the keyword proposed. The existence of people (me, > as an example :-)) whose vote would be changed by...
17
by: Fresh Air Rider | last post by:
Hello Could anyone please explain how I can pass more than one arguement/parameter value to a function using <asp:linkbutton> or is this a major shortfall of the language ? Consider the...
10
by: serge | last post by:
Using "SELECT * " is a bad practice even when using a VIEW instead of a table? I have some stored procedures that are identical with the difference of one statement in the WHERE clause. If I...
43
by: markryde | last post by:
Hello, I saw in some open source projects a use of "!!" in "C" code; for example: in some header file #define event_pending(v) \ (!!(v)->vcpu_info->evtchn_upcall_pending & \...
4
by: Gérard Talbot | last post by:
Hello fellow stylers, What would be the best CSS equivalent of MSIE's wrap="off" and wrap="hard"? hard Text is displayed with wordwrapping and submitted with soft returns and line feeds. ...
7
by: sami | last post by:
Hi I am trying to write a facebook application in python - I have been programming simple desktop applications till now and am not really familiar with web apps Pyfacebook is the wrapper for...
13
by: marathoner | last post by:
I would like to read the following entries of mixed data types from a ascii text file using C#. This can be easily performed in C using fscanf. Is there an equivalent function in C#? 1 2...
3
by: ElBeardo | last post by:
Hello, I´m new to Python.. so this is a newbee question. I´d like to put the value enterd in the entryfield in a variable. I´m trying to build a calculator with python and TKinter, coding it in...
16
by: Joe Strout | last post by:
One thing I miss as I move from REALbasic to Python is the ability to have static storage within a method -- i.e. storage that is persistent between calls, but not visible outside the method. I...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.