Re: ERROR: missing FROM-clause entry for table - Mailing list pgsql-general

From bigkev
Subject Re: ERROR: missing FROM-clause entry for table
Date
Msg-id 1455185735548-5886990.post@n5.nabble.com
Whole thread Raw
In response to Re: ERROR: missing FROM-clause entry for table  (Roxanne Reid-Bennett <rox@tara-lu.com>)
Responses Re: ERROR: missing FROM-clause entry for table  (Roxanne Reid-Bennett <rox@tara-lu.com>)
List pgsql-general
The call_schedule table looks like this
 id                | integer                     | not null default
nextval('call_schedule_id_seq'::regclass)
 account_id        | integer                     | not null
 user_id           | integer                     | not null
 call_type_id      | integer                     | not null
 call_frequency_id | integer                     | not null
 start_time        | timestamp without time zone | not null
 duration          | integer                     | not null
 end_time          | timestamp without time zone | not null
Indexes:
    "call_schedule_pkey" PRIMARY KEY, btree (id)
Foreign-key constraints:
    "call_schedule_account_id_fkey" FOREIGN KEY (account_id) REFERENCES
accounts(id)
    "call_schedule_call_frequency_id_fkey" FOREIGN KEY (call_frequency_id)
REFERENCES call_frequency(id)
    "call_schedule_call_type_id_fkey" FOREIGN KEY (call_type_id) REFERENCES
call_types(id)
    "call_schedule_user_id_fkey" FOREIGN KEY (user_id) REFERENCES users(id)

This stores the start_time, which is the date and time a series of calls
begins. The duration defines how long this event(call) will go for, and the
end_time defines when the schedule will stop.
I need to generate a calendar eg: 1 year with intervals of 1 day, and
include fortnightly calls at the appropriate dates.
the call_frequency_id would be 5 for a fortnightly call.

I an post schema if you need.




--
View this message in context:
http://postgresql.nabble.com/ERROR-missing-FROM-clause-entry-for-table-tp5886750p5886990.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


pgsql-general by date:

Previous
From: Achilleas Mantzios
Date:
Subject: Re: pg_multixact issues
Next
From: Martín Marqués
Date:
Subject: Re: Transaction ID not logged if no explicit transaction used