Hi
I am using the this time syntax in an acess query; iif([Setup
Time]>=#12:00:00 PM#,"PM","AM"). Problem is that I am getting error on the
date expression. What is the correct expression to represent 12 noon in an
access query?
Thanks
Regards 2 1673
If it is an access query, you need to extract the time or supply a date. A
date/time field includes both, and represents a point in time, not a time of
day. When you only put in the time, the date part internally is 0, which
represents Dec. 30, 1899.
If is a query against a server database, then the time representation will,
no doubt, be different.
Larry Linson
Microsoft Access MVP
"John" <Jo**@nospam.in fovis.co.uk> wrote in message
news:40******** *************** @news-text.dial.pipex .com... Hi
I am using the this time syntax in an acess query; iif([Setup Time]>=#12:00:00 PM#,"PM","AM"). Problem is that I am getting error on the date expression. What is the correct expression to represent 12 noon in an access query?
Thanks
Regards
So is something like
IIf(Format([SetupTime],"hh:nn:ss")>Ti meSerial(12,0,0 ),"PM","AM")
OK?
Regards
"Larry Linson" <bo*****@localh ost.not> wrote in message
news:0X******** **********@nwrd dc02.gnilink.ne t... If it is an access query, you need to extract the time or supply a date. A date/time field includes both, and represents a point in time, not a time
of day. When you only put in the time, the date part internally is 0, which represents Dec. 30, 1899.
If is a query against a server database, then the time representation
will, no doubt, be different.
Larry Linson Microsoft Access MVP
"John" <Jo**@nospam.in fovis.co.uk> wrote in message news:40******** *************** @news-text.dial.pipex .com... Hi
I am using the this time syntax in an acess query; iif([Setup Time]>=#12:00:00 PM#,"PM","AM"). Problem is that I am getting error on
the date expression. What is the correct expression to represent 12 noon in
an access query?
Thanks
Regards
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: shank |
last post by:
1) I'm getting this error: Syntax error (missing operator) in query
expression on the below statement. Can I get some advice.
2) I searched ASPFAQ and came up blank. Where can find the "rules" for when
and how to use single quotes and double quotes in ASP?
thanks!
----------------------
SQL = SQL & "WHERE '" &
REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE("GenKTitles.
|
by: Karaoke Prince |
last post by:
Hi There,
I have an update statement to update a field of a table (~15,000,000
records). It took me around 3 hours to finish 2 weeks ago. After that
no one touched the server and no configuration changed. Until
yesterday, I re-ran it again and it took me more than 18hrs and still
not yet finished!!!
What's wrong with it? I can ran it successfully before. I have tried
two times but the result was still the same.
|
by: KevLow |
last post by:
Hi,
Hope some kind soul can help me out here..
I'm trying to programmatically modify the column headings of a crosstab
query such that it can be dynamic based on user specified period (Month
Year to Month Year)
So far i have tried to use the following code:
//
|
by: Johnny Ruin |
last post by:
What do you think of a query that generates a
System.Data.SqlClient.SqlException when submitted via a application,
but when run through QueryAnalyzer or EnterpriseManager doesn't
generate a error? Here are 2 examples of the query:
SELECT table1.*,table2.field1,table2.field2,table2.field3 FROM
table1,table2 WHERE table1.field1 = table2.field1 AND
table1.field2='103' AND
table2.TStamp > '12/19/2005 12:20:14 PM' ORDER BY table2.TStamp
|
by: bryant |
last post by:
Hi all.
I am new to ASP and working in Expression Web. The following query
displays the information I need in the gridview for a single record.
SELECT "OE_HDR"."ORD_NO", "OE_HDR"."CUST_NAM", "OE_HDR"."SLS_MAN_NO",
"OE_HDR"."SLS_MAN_INITIALS", "OE_HDR"."ORD_DAT", "OE_HDR"."SHIP_DAT"
FROM "OE_HDR" WHERE ("OE_HDR"."ORD_NO"='174310')
I also have DropDownList1 working properly. For the WHERE portion of
| |
by: =?Utf-8?B?Um9iZXJ0IEUuIEZsYWhlcnR5?= |
last post by:
What is the C# command to wait for a specified period of time?
I am writing a windows service that will process a file once it has beed
created or changed. I'm using the fileSystemWatcher to detect when a
specific file has been created or changed. That works fine to a point. The
event does fire when the file is being created or changed but I then blow up
when I attempt to open the file because the creation or changing has not...
|
by: srinathvs |
last post by:
Hi,
I have an access db that I am trying to query from a vb6 program. I've the following code:
Dim sSQLQuery As String
sSQLQuery = "SELECT * FROM TblData WHERE ID = " & Chr(39) & ID & Chr(39)
ID here is equal to 1234567890
MsgBox sSQLQuery
the msgbox says: SELECT * FROM TblData WHERE ID = '1234567890 Note that the quotation is missing at the end
Set rs = db.OpenRecordset(sSQLQuery, dbOpenDynaset)
|
by: ghjk |
last post by:
I want to insert current server time to the postgres database. Data type is timestamp. When I insert the date, got an error saying
Warning: pg_query() : Query failed: ERROR: invalid input syntax for type timestamp: "1246960321" in C:\Program Files\xampp\htdocs\xxx\xxx\xxx.php on line 57
Error in SQL query: ERROR: invalid input syntax for type timestamp: "1246960321"
I take the time as follows.
$today = strtotime("now");
Please help...
|
by: rolltide |
last post by:
I've seen many similar threads, but despite repeated efforts I cannot figure out my problem. I am running Access 2003, VB 6.5, Office XP Pro. Code excerpt is below (you can see where I've tried debugging myself). My problem is in the DLookup command.
UserName = Me.cboUserName.Value
Debug.Print "User Name is "; UserName
strPassword = DLookup("Password", "Employees", "EmpName ='" & UserName)
Debug.Print "Password is ";...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |