Re: Wired behaviour from SELECT
От | Arbol One |
---|---|
Тема | Re: Wired behaviour from SELECT |
Дата | |
Msg-id | BYAPR12MB2808B1C3833C91B68FEF9D8ABA2C2@BYAPR12MB2808.namprd12.prod.outlook.com обсуждение исходный текст |
Ответ на | Re: Wired behaviour from SELECT ("David G. Johnston" <david.g.johnston@gmail.com>) |
Список | pgsql-general |
Oops!
I am putting too many hours in front of the computer, better take a break 😳
On 2024-11-22 3:12 p.m., David G. Johnston wrote:
On Fri, Nov 22, 2024 at 1:07 PM Arbol One <arbolone@hotmail.ca> wrote:The below sql statement produces the right outputSELECT nickname, password FROM password WHERE id='0938105618107N1';
nickname | password
-------------+----------
Piccard@@21 | Arbol
(1 row)However, if this sql statement produces the wrong output
SELECT nickname, password FROM password WHERE nickname='Arbol';
nickname | password
----------+----------
(0 rows)What am I doing wrong?Naming a column in your table the same name as the table is problematic generally. As for the query, if they are both intended to return the same row the value Arbol is in the password column, not the nickname column. You seem to have reversed the data for the two columns.David J.
--
ArbolOne ™
Using Fire Fox and Thunderbird.
ArbolOne is composed of students and volunteers dedicated to providing free services to charitable organizations.
ArbolOne's development on Java, PostgreSQL, HTML and Jakarta EE is in progress [ í ]
ArbolOne ™
Using Fire Fox and Thunderbird.
ArbolOne is composed of students and volunteers dedicated to providing free services to charitable organizations.
ArbolOne's development on Java, PostgreSQL, HTML and Jakarta EE is in progress [ í ]
В списке pgsql-general по дате отправления: