![]() |
![]() ![]() |
![]() |
![]()
Post
#1
|
|
Grupa: Zarejestrowani Postów: 2 Pomógł: 0 Dołączył: 6.01.2013 Ostrzeżenie: (0%) ![]() ![]() |
Witam,
Po migracji z mysql4 na mysql5 wystąpił problem. Na stronie pokazuje mi się komunikat: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in ... 131 Linie 129-131: 129 | $q="select gs_hr.rin$hr as rin,gs_hr.uin$hr as uin,gs_hr.cl$hr as cl,gs_hr.out$hr as out,gs_hr.f$hr as f,gs_hr.a$hr as a,gs_hr.rin$hrl as rinhrl,gs_hr.out$hrl as outhrl,gs_hr.d as d,gs_tr.r as r,gs_tr.t as t,gs_tr.tr as tr,gs_tr.otr as otr,gs_tr.htr as htr,gs_tr.hotr as hotr,gs_tr.dowed as dowed,gs_tr.a as ca,gs_tr.drin as drin,gs_tr.dout as dout,gs_tr.etr as etr from gs_hr,gs_tr where gs_hr.d=gs_tr.d"; 130 | $r=mysql_query($q); 131 | while($row=mysql_fetch_array($r)){$d=$row["d"]; Po wykonaniu echo mam informację: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'out,gs_hr.f4 as f,gs_hr.a4 as a,gs_hr.rin3 as rinhrl,gs_hr.out3 as outhrl,gs_hr.' at line 1 Cały plik php ma 153 linie. Muszę to uruchomić pod mysql5 ... Czy ktoś może mi pomóc? Pozdrawiam, |
|
|
![]()
Post
#2
|
|
Grupa: Moderatorzy Postów: 36 557 Pomógł: 6315 Dołączył: 27.12.2004 ![]() |
gs_hr.out$hr as out
OUT jest słowem zastrzeżonym w mysqql i nie możesz tworzyć aliasu o takiej nazwie. Musisz zmienić ten alias a potem w php pamiętać o tej zmianie. |
|
|
![]()
Post
#3
|
|
Grupa: Zarejestrowani Postów: 1 421 Pomógł: 310 Dołączył: 18.04.2012 Ostrzeżenie: (0%) ![]() ![]() |
|
|
|
![]()
Post
#4
|
|
Grupa: Moderatorzy Postów: 36 557 Pomógł: 6315 Dołączył: 27.12.2004 ![]() |
Powinno pomóc (IMG:style_emoticons/default/smile.gif)
|
|
|
![]()
Post
#5
|
|
Grupa: Zarejestrowani Postów: 2 Pomógł: 0 Dołączył: 6.01.2013 Ostrzeżenie: (0%) ![]() ![]() |
|
|
|
![]() ![]() |
![]() |
Aktualny czas: 23.08.2025 - 10:50 |