ERROR: relation "userroles" does not exist
------=_Part_130355_4313784.1223659831206
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
*Hello All,
*I keep receiving the following when trying to select from a table in my
database. the Tables are there i see them in pgAdmin...
*Warning*: pg_query_params()
[function.pg-query-params<http://localhost:8888/HH/function.pg-query-params>]:
Query failed: ERROR: relation "userroles" does not exist
The query I'm running is
SELECT userPassword, salt, roleName
FROM User u, UserRoles ur, Roles r
where u.id = ur.user_id
and r.id = ur.role_id
and u.username = $1
and u.active = true
------=_Part_130355_4313784.1223659831206
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
<div dir="ltr"><b>Hello All,<br><br></b>I keep receiving the following when trying to select from a table in my database. the Tables are there i see them in pgAdmin...<br><br><br><b>Warning</b>: pg_query_params() [function.pg-query-params]: Query failed: ERROR: relation "userroles" does not exist<br>
<br>The query I'm running is<br><br>SELECT userPassword, salt, roleName<br> FROM User u, UserRoles ur, Roles r<br> where u.id = ur.user_id<br> and r.id = ur.role_id<br>
and u.username = $1<br> and u.active = true<br><br><br><br></div>
------=_Part_130355_4313784.1223659831206--
Re: ERROR: relation "userroles" does not exist
On 10/10/2008 18:30, Sean wrote:
> *I keep receiving the following when trying to select from a table in my
> database. the Tables are there i see them in pgAdmin...
>
> *Warning*: pg_query_params() [function.pg-query-params
> <http://localhost:8888/HH/function.pg-query-params>]: Query failed:
> ERROR: relation "userroles" does not exist
Would you have defined the table using quoted upper-case? PG folds names
to lower-case unless you double quote them, so:
test=# create table test();
CREATE TABLE
test=# create table "Test"();
CREATE TABLE
test=# \dt
List of relations
Schema | Name | Type | Owner
--------+------+-------+----------
public | Test | table | postgres
public | test | table | postgres
(2 rows)
Ray.
------------------------------------------------------------ ------
Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland
rod [at] iol.ie
Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals
------------------------------------------------------------ ------
--
Sent via pgsql-php mailing list (pgsql-php [at] postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-php
Re: ERROR: relation "userroles" does not exist
------=_Part_133012_18133933.1223669024736
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
That's it. thank you.. I created it using PgAdmin.
On Fri, Oct 10, 2008 at 2:17 PM, Raymond O'Donnell <rod [at] iol.ie> wrote:
> On 10/10/2008 18:30, Sean wrote:
> > *I keep receiving the following when trying to select from a table in my
> > database. the Tables are there i see them in pgAdmin...
> >
> > *Warning*: pg_query_params() [function.pg-query-params
> > <http://localhost:8888/HH/function.pg-query-params>]: Query failed:
> > ERROR: relation "userroles" does not exist
>
> Would you have defined the table using quoted upper-case? PG folds names
> to lower-case unless you double quote them, so:
>
> test=# create table test();
> CREATE TABLE
> test=# create table "Test"();
> CREATE TABLE
> test=# \dt
> List of relations
> Schema | Name | Type | Owner
> --------+------+-------+----------
> public | Test | table | postgres
> public | test | table | postgres
> (2 rows)
>
>
> Ray.
>
> ------------------------------------------------------------ ------
> Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland
> rod [at] iol.ie
> Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals
> ------------------------------------------------------------ ------
>
------=_Part_133012_18133933.1223669024736
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
<div dir="ltr">That's it. thank you.. I created it using PgAdmin. <br><br><div class="gmail_quote">On Fri, Oct 10, 2008 at 2:17 PM, Raymond O'Donnell <span dir="ltr"><rod [at] iol.ie></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">On 10/10/2008 18:30, Sean wrote:<br>
> *I keep receiving the following when trying to select from a table in my<br>
<div class="Ih2E3d">> database. the Tables are there i see them in pgAdmin...<br>
><br>
> *Warning*: pg_query_params() [function.pg-query-params<br>
</div>> <http://localhost:8888/HH/function.pg-query-params>]: Query failed:<br>
<div class="Ih2E3d">> ERROR: relation "userroles" does not exist<br>
<br>
</div>Would you have defined the table using quoted upper-case? PG folds names<br>
to lower-case unless you double quote them, so:<br>
<br>
test=# create table test();<br>
CREATE TABLE<br>
test=# create table "Test"();<br>
CREATE TABLE<br>
test=# \dt<br>
List of relations<br>
Schema | Name | Type | Owner<br>
--------+------+-------+----------<br>
public | Test | table | postgres<br>
public | test | table | postgres<br>
(2 rows)<br>
<br>
<br>
Ray.<br>
<br>
------------------------------------------------------------ ------<br>
<font color="#888888">Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland<br>
rod [at] iol.ie<br>
Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals<br>
------------------------------------------------------------ ------<br>
</font></blockquote></div><br></div>
------=_Part_133012_18133933.1223669024736--