| Index
» Projekty
» phpMyEdit
» Zoznam chýb
» Chyba #146 |
 |
|
Rozšírené detaily chyby |
[ Preskočiť na poznámky k chybám ]
[ História chýb ]
[ Vytlačiť ]
|
|
ID |
Kategória |
Dôležitosť |
Reprodukovateľnosť |
Dátum vloženia |
Posledná zmena |
|
0000146 |
core / general |
triviálna |
vždy |
2003-12-15 20:36 |
2004-02-20 13:12 |
|
|
|
Autor |
Feike |
Zobraziť status |
verejný |
|
|
Priradené |
nepto |
|
Priorita |
normálna |
Riešenie |
duplicitný |
Platforma |
|
|
Stav |
uzavretý |
Duplicitné ID |
0000094 |
OS |
|
|
Projection |
žiadny |
|
Verzia |
|
|
ETA |
žiadny |
|
Verzia produktu |
current from CVS |
|
|
Build produktu |
|
|
|
Hlasy |
1 |
|
|
|
Zhrnutie |
Can't use group as column name |
|
Popis |
I have a table with a column name 'group' in it. But when I want to update this table, phpMyEdit gives an error. |
|
Kroky k vyvolaniu |
1. Create a table with a column-name named 'group'
2. Try to update, or insert a field.
|
|
Dalšie informácie |
I found out that in an query the column names are not quoted. For example:
SELECT id,group FROM groups WHERE id='424';
will not work because of 'group' as in GROUP BY. It will work if the column names are quoted, as in:
SELECT 'id', 'group' FROM groups WHERE id='424';
|
|
Pripojené súbory |
backquotes.diff (1,035 bytes) 2003-12-21 12:24 |
|
|
|
Poznámky k chybe |
nepto
2003-12-16 11:18
|
Yes, we know about this issue.
This could be probably solved by quoting column/table/etc names.
Thank you for reporting! |
|
|
Feike
2003-12-16 13:04
|
Okay, sorry about that, I just saw that bug-report.
It says how to quote table names, but how do I quote field names? |
|
|
michal
2003-12-21 12:07
|
if field name is the same as column name, then should be quoted the same way (`field_name`)(the quote below esc button).
without quoting, apps will break in these cases:
column names are reserved words, like group, select, limit, and, column, ...
column names containing . (dot) and -(minus)
(and probably more cases) |
|
|
hbernard
2003-12-21 12:23
|
There is a workaround for this :
just put the field's name into backquotes.
like this : $opts['fdd']['`group`']
This needs a FAQ entry, or a comment about field definition.
BUT, this break javascript validation. (backquotes doesn't seem to be a valid javascript character)
patch backquotes.diff fix this by removing backquotes in field names wrote in javascript. |
|
|
nepto
2004-01-23 17:01
|
This is a duplicated entry. |
|
|
|
História chýb |
|
Dátum poslednej úpravy |
Používateľské meno |
Pole |
Zmeniť |
|
2003-12-15 20:36 |
Feike |
Nová chyba |
|
|
2003-12-16 11:18 |
nepto |
status |
nový => schválený |
|
2003-12-16 11:18 |
nepto |
Poznámka k chybe pridaná: 0000450 |
|
|
2003-12-16 13:04 |
Feike |
Poznámka k chybe pridaná: 0000457 |
|
|
2003-12-21 12:07 |
michal |
Poznámka k chybe pridaná: 0000478 |
|
|
2003-12-21 12:23 |
hbernard |
Poznámka k chybe pridaná: 0000479 |
|
|
2003-12-21 12:24 |
hbernard |
Chyba monitorovaná: hbernard |
|
|
2003-12-21 12:24 |
hbernard |
Pridaný súbor: : backquotes.diff |
|
|
2004-01-23 17:01 |
nepto |
Poznámka k chybe pridaná: 0000660 |
|
|
2004-01-23 17:01 |
nepto |
duplicate_id |
0 => 94 |
|
2004-01-23 17:01 |
nepto |
handler_id |
=> nepto |
|
2004-01-23 17:01 |
nepto |
resolution |
otvorený => duplicitný |
|
2004-01-23 17:01 |
nepto |
status |
schválený => vyriešený |
|
2004-02-20 13:12 |
nepto |
status |
vyriešený => uzavretý |
|
|