DG4SYBS - ORA-01866 Datetime Class Invalid When Running Sybase Stored Procedure
(Doc ID 2686794.1)
Last updated on JULY 21, 2020
Applies to:
Oracle Database Gateway for Sybase - Version 12.1.0.2 and laterInformation in this document applies to any platform.
Symptoms
Using Oracle Database Gateway for Sybase 19c and executing a Sybase stored procedure via database link is getting error. The Sybase stored procedure returns date not able to be retrieved.
Example:
Sybase sp_test procedure as below:
create procedure sp_test
@ws_id varchar(10),
@out_date datetime output
as
select @out_date = getdate()
return 200
go
Running from Oracle database via database link:
set serveroutput on;
declare
result number := 0;
out_date timestamp;
BEGIN
result := "sp_test"@<DB_LINK>('mat', out_date);
DBMS_OUTPUT.put_line('result=' || result);
DBMS_OUTPUT.put_line('out_date=' || out_date);
commit;
END;
ORA-01866: the datetime class is invalid
ORA-06512: at line 5
01866. 00000 - "the datetime class is invalid"
Changes
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Changes |
Cause |
Solution |
References |