Solved

Lotus NotesSQL Year function usage

Posted on 2014-03-07
4
851 Views
Last Modified: 2014-03-07
I am trying to use the YEAR function in a query going against a Lotus Notes database via ODBC.  Here is example 1:

SELECT StartTimeDate,
	StartDate,
	YEAR(StartDate)
FROM MainTopic
WHERE StartDate >= '2014-03-01'

Open in new window

The results are:
[Lotus][ODBC Lotus Notes]Name, constant, or expression expected

[Lotus][ODBC Lotus Notes]Incorrect syntax near ','

[Check aborted]


In example 2 I removed the line with the YEAR function:
SELECT StartTimeDate,
	StartDate
FROM MainTopic
WHERE StartDate >= '2014-03-01'

Open in new window


The result is:
[Command checked successfully]
so the query will run.


Also, is there any good documentation on using NotesSQL?  I haven't found any, but would be grateful for any hints.
0
Comment
Question by:VieleFragen
  • 2
  • 2
4 Comments
 
LVL 46

Accepted Solution

by:
Sjef Bosman earned 100 total points
ID: 39913191
Probably the YEAR function isn't implemented. NotesSQL is only a very basic way to execute SQL-like queries on a Notes database. See also the documentation...

Ah, yes, that's your 2nd Frage: http://www.ibm.com/developerworks/lotus/documentation/notessql/
0
 
LVL 1

Author Comment

by:VieleFragen
ID: 39913697
That's what I was afraid of; my workaround is to use 'macro' as "StartYear" and handle it in Excel with VBA.

Vielen Dank!
0
 
LVL 1

Author Closing Comment

by:VieleFragen
ID: 39913698
The answer came back quickly and to the point, with a helpful link.  Thanks very much Experts Exchange!
0
 
LVL 46

Expert Comment

by:Sjef Bosman
ID: 39913740
Bitte sehr.  :-)
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

For beginners of Lotus Notes user this is important to know about the types of files and their location supported by IBM Notes. Mostly users are unaware about how many file types are created and what their usages are. This Article is fully dedicated…
Notes Document Link used by IBM Notes is a link file which aids in the sharing of links to documents in email and webpages. The posts describe the importance and steps to create a Lotus Notes NDL file in brief.
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now