WebsiteBaker Support (2.8.x) > Bakery Shop
Fatal error: Call to a member function numRows() on a non-object in
dbs:
The same problem here.
--- Code: ---Fatal error: Call to a member function numRows() on a non-object in .../modules/bakery/modify.php on line 52
--- End code ---
New install of Bakery in Portable 2.8.3 (PHP 5.4.)
No table mod_bakery_general_ settings was created.
After changing in install.php line 173 from '9999999' to '999' and installing again (Add-Ons > Modules > Advanced) it works.
jacobi22:
bei mir in der selben Konstellation ohne Probleme :roll:
vielleicht ist es geschickter, diesen Wert (99999,99) erst in der add.php hinzuzufügen(?)
oh, english thread, sorry :-o
work for me on the same situation (actual wb-portable-version with the sme php- and mysql, and bakery version) without problems
maybe its better, to set the default value not in the installer, set the value "99999.99" as a INSERT in the add.php
marmot:
Hi,
--- Quote from: daydreamer on November 13, 2013, 10:38:07 PM ---
--- Code: ---. "`free_shipping` DECIMAL(7,2) NOT NULL DEFAULT '9999999' ,"
--- End code ---
--- End quote ---
--- Quote from: dbs on December 13, 2013, 12:36:17 PM ---No table mod_bakery_general_ settings was created.
After changing in install.php line 173 from '9999999' to '999' and installing again (Add-Ons > Modules > Advanced) it works.
--- End quote ---
at this point I can use my unique ability to use google and to read a manual. "DECIMAL(7,2)" means 7 digits including decimals, which means the intger part can have 5 digits maximum = 99999. Fine if it works with a 7 digit integer soemtimes but it's not according to the field definition.
regards
jacobi22:
in the scool i learning this: a decimal has three parts: 1. integer part 2. decimal point like comma or point, 3. fractional part
in the manual i found this: A packed “exact” fixed-point number. M is the total number of digits (the precision) and D is the number of digits after the decimal point (the scale).
so i unterstand: M is the precision (for mathematic operations), and D is the output, but not: m is the total sum of all digits on the left and the rights side from the decimal point
i found more informations on the next page in the manual
--- Quote ---For example, a DECIMAL(18,9) column has nine digits on either side of the decimal point, so the integer part and the fractional part each require 4 bytes. A DECIMAL(20,6) column has fourteen integer digits and six fractional digits. The integer digits require four bytes for nine of the digits and 3 bytes for the remaining five digits. The six fractional digits require 3 bytes.
--- End quote ---
its exactly this, was marmot write
but i dont unterstand, why it's work for me and not for dbs with the same configuration (same wb-portable with same php- and mysql version)
german translation....
wohl ein "Verständnisproblem" mit mathematischen Bezeichnungen. Ich hatte das noch so gelernt, das vor dem Trenner eine Ganzzahl steht, hinter dem Trenner die Dezimalzahl.
lt Definition MySQL: DECIMAL[(M[,D])] - Gepackte „exakte“ Festkommazahl. M ist die Gesamtzahl von Dezimalstellen (Genauigkeit), D die Anzahl der Stellen hinter dem Dezimalpunkt.
heißt bei mir, es wird auf 7 Nachkommastellen berechnet, auf 2 gerundet bzw 2 ausgegeben
liest man an anderer Stelle weiter, heißt es aber: Da beispielsweise die Spalte DECIMAL(18,9) auf jeder Seite des Dezimalpunkts 9 Stellen hat, belegen ihr ganzzahliger und ihr Dezimalteil jeweils 4 Byte. Eine DECIMAL(20,10)-Spalte hat dagegen auf jeder Seite des Dezimalpunkts 10 Stellen. Jeder Teil belegt also 4 Byte für die ersten 9 Stellen und 1 Byte für die Reststelle
entspricht also genau dem, was marmot sagte
aber auch in diesem Text, die mal von mir gelernte Trennung von Ganz- und Dezimalzahl vor bzw nach dem Komma
trotzdem verstehe ich nicht, warum es mit der gleichen PHP- und MySQL, und WB- und BakeryVersion (alles auf der gleichen WB-Portable) bei einem der berechtigte Fehler kommt und beim anderem ein Wert von 99999.99 eingetragen wird
dbs:
There is no comma or point in 9999999
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version