We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Submitted by: carolina alzate (pfalzate)
I need to find the number of months between 2 dates, using firebird-2.x, a UDF to do this, but always returns to annex as a result 0
dll code in delphi
library CAO_UDFS; uses SysUtils, Classes, Controls, DateUtils; {$R *.res}
function MesesEntreFechas(Fecha1,Fecha2: TDate): Integer; cdecl; begin Result := MonthsBetween(Fecha1,Fecha2); end;
exports MesesEntreFechas; begin end.
register udf en firebird
DECLARE EXTERNAL FUNCTION MESESENTREFECHAS DATE, DATE RETURNS INTEGER BY VALUE ENTRY_POINT 'MesesEntreFechas' MODULE_NAME 'CAO_UDFs.dll';
Always always returns zero when using MesesEntreFechas
I can help someone who is ill.
The text was updated successfully, but these errors were encountered:
Commented by: @dyemanov
Firebird's date is not compatible with Delphi's TDate. You should using other datatypes in your UDF.
What you need is available in FB 2.1: search the release notes for the DATEDIFF function.
Sorry, something went wrong.
status: Open [ 1 ] => Resolved [ 5 ]
resolution: Won't Fix [ 2 ]
status: Resolved [ 5 ] => Closed [ 6 ]
No branches or pull requests
Submitted by: carolina alzate (pfalzate)
I need to find the number of months between 2 dates, using firebird-2.x, a UDF to do this, but always returns to annex as a result 0
dll code in delphi
library CAO_UDFS;
uses
SysUtils,
Classes,
Controls,
DateUtils;
{$R *.res}
function MesesEntreFechas(Fecha1,Fecha2: TDate): Integer; cdecl;
begin
Result := MonthsBetween(Fecha1,Fecha2);
end;
exports
MesesEntreFechas;
begin
end.
register udf en firebird
DECLARE EXTERNAL FUNCTION MESESENTREFECHAS
DATE,
DATE
RETURNS INTEGER BY VALUE
ENTRY_POINT 'MesesEntreFechas' MODULE_NAME 'CAO_UDFs.dll';
Always always returns zero when using MesesEntreFechas
I can help someone who is ill.
The text was updated successfully, but these errors were encountered: