From 8158c57a8e3a40338045e0b809bca42f1e703ca5 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Wed, 7 Sep 2005 14:31:21 +0100 Subject: update schema, more mysql work --- functions.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'functions.php') diff --git a/functions.php b/functions.php index bea443c27..742e026f5 100644 --- a/functions.php +++ b/functions.php @@ -171,10 +171,14 @@ $entry_guid = db_escape_string($entry_guid); + if (DB_TYPE == "pgsql") { + $extract_ts_qpart = ",EXTRACT(EPOCH FROM updated) as updated_timestamp"; + } + $result = db_query($link, " SELECT - id,last_read,no_orig_date,title,feed_id,content_hash, - EXTRACT(EPOCH FROM updated) as updated_timestamp + id,last_read,no_orig_date,title,feed_id,content_hash + $extract_ts_qpart FROM ttrss_entries WHERE -- cgit v1.2.3