HSQLDB 2.0
Base 3.4
Ubuntu 11.4
Previously, today, I asked about the DATEADD function. I was using it on a Windows 7 machine.
The solution that Sliderule gave me then worked excellently, and correctly.
Now, I'm doing the same database on Ubuntu, with the same tables, and with HSQLDB 2.0.
In a query to add 50 days to a date, I receive the error:
Unexpected Token: DATEADD in statement.....
The function is: DATEADD('dd', 50, "filledon")
I'm at a loss as to why this works in windows, but not linux.
I've searched, but can not find any information about this either as HSQLDB.org or by google, or in this forum.
Again, any help is appreciated.
[Solved] DATEADD - Unexpected Token
-
- Posts: 90
- Joined: Fri Dec 31, 2010 5:16 pm
[Solved] DATEADD - Unexpected Token
Last edited by capemayal1 on Mon Nov 21, 2011 2:55 pm, edited 1 time in total.
Re: DATEADD - Unexpected Token
On your Ubuntu machine . . . from the menu, if you click on: Tools -> Options -> OpenOffice.org -> Java
What is the Java Version ?
If you click on Class Path. . .
What is the directory for the assigned archive hsqldb.jar ?
From the Menu: Edit -> Database -> Properties
What is the exact line for Datasource URL ?
What is the JDBC driver class ?
Put another way, are you really connected to your HSQL Version 2 anything database, or, are you really connected to the old Embedded Database Version 1.8 ?
Sliderule
Thanks to add [Solved] in your 1st post Subject (edit button top right) if this issue has been resolved.
What is the Java Version ?
If you click on Class Path. . .
What is the directory for the assigned archive hsqldb.jar ?
From the Menu: Edit -> Database -> Properties
What is the exact line for Datasource URL ?
What is the JDBC driver class ?
Put another way, are you really connected to your HSQL Version 2 anything database, or, are you really connected to the old Embedded Database Version 1.8 ?
Sliderule
Thanks to add [Solved] in your 1st post Subject (edit button top right) if this issue has been resolved.
-
- Posts: 90
- Joined: Fri Dec 31, 2010 5:16 pm
Re: DATEADD - Unexpected Token
Sliderule wrote:On your Ubuntu machine . . . from the menu, if you click on: Tools -> Options -> OpenOffice.org -> Java
What is the Java Version ?
version is 1.6.0.22
If you click on Class Path. . .
What is the directory for the assigned archive hsqldb.jar ?
/home/capemayal/hsqldb-2.2.5/hsqldb/lib
From the Menu: Edit -> Database -> Properties
What is the exact line for Datasource URL ?
JDBC:hsqldb:file:/home/capemayal/documents/medical/medical;default_schema=true;shutdown=true;hsqldb.default_table_type=cached;get_column_name=false
What is the JDBC driver class ?
org.hsqldb.jdbcDriver
Put another way, are you really connected to your HSQL Version 2 anything database, or, are you really connected to the old Embedded Database Version 1.8 ?
I tested the connection and it is successful
Sliderule
Thanks to add [Solved] in your 1st post Subject (edit button top right) if this issue has been resolved.
Re: DATEADD - Unexpected Token
Open your OpenOffice Base file:
Sliderule
Thanks to add [Solved] in your 1st post Subject (edit button top right) if this issue has been resolved.
- On the left, click on Queries
- Under Tasks, click on: Create Query in SQL View...
- Copy and Paste:
Code: Select all
Select CURRENT_DATE as "Current Date", DATEADD('dd', 50, CURRENT_DATE) as "DateAdd Current Date + 50" From INFORMATION_SCHEMA.SYSTEM_TABLES Where TABLE_NAME = 'SYSTEM_TABLES'
- Run the Query . . . F5 key . . . OR . . . Run Query icon on the toolbar
- Does it run and return two columns, one record with appropriate values ?
Sliderule
Thanks to add [Solved] in your 1st post Subject (edit button top right) if this issue has been resolved.
-
- Posts: 90
- Joined: Fri Dec 31, 2010 5:16 pm
Re: DATEADD - Unexpected Token
Run Query:
The data content could not be loaded.
Unexpected Token: DATEADD in statement......
Class Path dialog:
There is no mention of hsqldb.jar
it reads:
/home/capemayal/hsqldb-2.2.5/hsqldb/lib
The data content could not be loaded.
Unexpected Token: DATEADD in statement......
Class Path dialog:
There is no mention of hsqldb.jar
it reads:
/home/capemayal/hsqldb-2.2.5/hsqldb/lib
Re: DATEADD - Unexpected Token
So, you are NOT connected to the hsqldb.jar . . . you have NOT added the archive hsqldb.jar to the Class Path.
Instead, you are just connected to the hsqldb.jar file in the OpenOffice directory . . . version 1.8 . . . which does NOT support the DATEADD function.
Sliderule
Thanks to add [Solved] in your 1st post Subject (edit button top right) if this issue has been resolved.
Instead, you are just connected to the hsqldb.jar file in the OpenOffice directory . . . version 1.8 . . . which does NOT support the DATEADD function.
Sliderule
Thanks to add [Solved] in your 1st post Subject (edit button top right) if this issue has been resolved.