[Info-ingres] Function '>=' is not defined for arguments of type 'date' and 'integer'. Explicitly convert its arguments to the desired type(s)

DATABASE

    Sponsored Links

Re: [Info-ingres] Function '>=' is not defined for arguments of type 'date' and 'integer'. Explicitly convert its arguments to the desired type(s)

Postby John Smedley » Wed, 18 Oct 2006 17:09:18 GMT

his is a multi-part message in MIME format.
You have not said which version of Ingres - I have done this on:
"Ingres 2006 Microsoft Windows 32-bit Version II 9.0.4 (int.w32/105)"
and it has worked for me.

Cheers

John

1> help table my_table


Name: my_table
Owner: smejo01
Created: 17-oct-2006 09:00:19
Location: ii_database
Type: user table
Version: II9.0
Page size: 8192
Cache priority: 0
Alter table version: 0
Alter table totwidth: 29
Row width: 29
Number of rows: 0
Storage structure: heap
Compression: none
Duplicate Rows: allowed
Number of pages: 3
Overflow data pages: 0
Journaling: enabled
Base table for view: no
Permissions: none
Integrities: none
Optimizer statistics: none

Column Information:
Key
Column Name Type Length Nulls Defaults Seq
the_key integer 4 no no
valid_date date no no
another_date date yes null

Secondary indexes: none

2> insert into my_table values (1, 'today', date('today') - '1 day')
(1 row)

3> Select * from my_table where valid_date >= another_date

+-------------+-------------------------+-------------------------+
|the_key |valid_date |another_date |
+-------------+-------------------------+-------------------------+
| 1|17-oct-2006 |16-oct-2006 |
+-------------+-------------------------+-------------------------+
(1 row)
End of Request
________________________________________________________________________________


Sen wrote:


<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<small><font face="Courier New">You have not said which version of
Ingres - I have done this on:<br>
"Ingres 2006 Microsoft Windows 32-bit Version II 9.0.4 (int.w32/105)</font><font
face="Courier New">"</font></small><small><font face="Courier New"><br>
and it has worked for me.<br>
<br>
Cheers<br>
<br>
John <br>
<br>
1> help table my_table<br>
     <br>
<br>
Name:                 my_table<br>
Owner:                smejo01<br>
Created:              17-oct-2006 09:00:19     <br>
Location:             ii_database<br>
Type:                 user table<br>
Version:              II9.0<br>
Page size:            8192&

Similar Threads:

1.Function '>=' is not defined for arguments of type 'date' and 'integer'. Explicitly convert its arguments to the desired type(s)

Hi all,

I'm getting the following error message while comparing dates in Ingres
database

Function '>=' is not defined for arguments of type 'date' and
'integer'. Explicitly convert its arguments to the desired type(s)

I feel that it has to do something with table definition.

Here is my query:

Select * from my_table where valid_date >= another_date;

Can any one throw light on this.

Thanks,
Sen

2.Composite Type Argument Construction to a Function

3.Re : Convert Char-->integer or Integer-->char

4.Convert Char-->integer or Integer-->char

Hello,

I am a new bee with informix and I want to convert an integer to char or a
char to integer.
Informix 7+ CSDK + PHP

My problems is the attribute type is different. toto: type char(30) and titi
type integer but the data are the same (bad conception..)
I try :

select toto,titi
from table1,table2
where table1.titi=cast (table2.toto as integer)

---> error -201

select toto,titi
from table1,table2
where table1.titi=table2.toto::integer

--> error -201

I couldn't modifiy my database. Have you got an idea ???
Thanks you very much for your help





5.pgsql-server: Allow plpgsql to pass composite-type arguments (ie,

6. Informix Serial Data type to Integer Data Type

7. [Info-Ingres] Why BOOLEAN data type not provided in Ingres

8. ERROR: JOIN/USING types 'integer' and 'character varying' not matched



Return to DATABASE

 

Who is online

Users browsing this forum: No registered users and 79 guest