Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4fa25b8

Browse files
author
Thomas G. Lockhart
committed
Shorten routine names to <= 16 characters to fit in pg_proc table.
1 parentc0087c9 commit4fa25b8

File tree

1 file changed

+8
-17
lines changed

1 file changed

+8
-17
lines changed

‎src/backend/utils/adt/timestamp.c

Lines changed: 8 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -103,22 +103,13 @@ timestampge(time_t t1, time_t t2)
103103
}
104104

105105
DateTime*
106-
timestamp_datetime(time_ttimestamp)
106+
stamp_datetime(time_ttimestamp)
107107
{
108-
DateTime*result;
108+
return(abstime_datetime((AbsoluteTime)timestamp));
109+
}/* stamp_datetime() */
109110

110-
doublefsec=0;
111-
structtm*tm;
112-
113-
if (!PointerIsValid(result=PALLOCTYPE(DateTime)))
114-
elog(WARN,"Memory allocation failed, can't convert timestamp to datetime",NULL);
115-
116-
tm=localtime((time_t*)&timestamp);
117-
tm->tm_year+=1900;
118-
tm->tm_mon+=1;
119-
120-
if (tm2datetime(tm,fsec,NULL,result)!=0)
121-
elog(WARN,"Unable to convert timestamp to datetime",timestamp_out(timestamp));
122-
123-
return (result);
124-
}/* timestamp_datetime() */
111+
time_t
112+
datetime_stamp(DateTime*datetime)
113+
{
114+
return((AbsoluteTime)datetime_abstime(datetime));
115+
}/* datetime_stamp() */

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp