Ho to use a between sql from 2 hours?
Attached my property filed.
In field ORA have:
11:20
15:17
...
12:26
i use Access database
BETWEEN from hours
-
- PlatinumLounger
- Posts: 4355
- Joined: 26 Apr 2010, 17:36
BETWEEN from hours
You do not have the required permissions to view the files attached to this post.
-
- Administrator
- Posts: 78475
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: BETWEEN from hours
You can use (for example)
SELECT ... FROM ... WHERE ORA_OP Between #05:00# And #14:00#
SELECT ... FROM ... WHERE ORA_OP Between #05:00# And #14:00#
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4355
- Joined: 26 Apr 2010, 17:36
Re: BETWEEN from hours
WOW!HansV wrote:You can use (for example)
SELECT ... FROM ... WHERE ORA_OP Between #05:00# And #14:00#
about this post....
i have a var MyVar=7 (is the initial hour of list)
i need to fill a combobox3 with hours and half hour from MyVar =7 to 24 with a step of half hour in this format HH:MM
similar:
07:00
07:30
08:00
08:30
...
24:00
MyVar is variable and it can assume only a fied hour 7 or 8 or 9...ecc
my test code, but not work:-(
Code: Select all
Dim INIZIO As String
INIZIO = 7
With Me.Combo3
For I = 0 To 24
INIZIO = INIZIO + 30
Me.Combo3.AddItem Format$(INIZIO, "HH:MM")
DoEvents
Next I
End With
-
- Administrator
- Posts: 78475
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: BETWEEN from hours
Try this:
Code: Select all
Dim i As Long
For i = 2 * MyVar To 48
Me.Combo3.AddItem Format(i / 48, "hh:mm")
Next i
Best wishes,
Hans
Hans
-
- PlatinumLounger
- Posts: 4355
- Joined: 26 Apr 2010, 17:36
Re: BETWEEN from hours
sorry me... butHansV wrote:You can use (for example)
SELECT ... FROM ... WHERE ORA_OP Between #05:00# And #14:00#
If the two var INIZIO & FINE are = blank wath range of hours get the sql?
-
- Administrator
- Posts: 78475
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands