Daily Quotes

hello,

we insert new quotes and now at id 255 always comes query error.


we deleted the last entry in database and admin panel and tried new, you can insert the last one with id 255 and after it the error again.

we also tried to insert in db a new line with id 256 manuell, and the error comes, duplicate entry for id 255


is there somewhere a variable for it that it stops at 255?

ue30 Mods - http://www.boonex.com/market/posts/ue30
Quote · 22 Mar 2010

It's the way the module was designed. The quotes module sets up the database ID field as tinyint(4) That is the max it will hold.


You could try changing the db table bx_quotes_units ID field from tinyint(4) to int(10)


If you do you may want to alter the modules install and uninstall sql files to match so you won't have problems if you uninstall and reinstall this module.



I am not sure if any code changes would be needed to deal with the change from tinyint to int. I have not looked into that.


https://www.deanbassett.com
Quote · 22 Mar 2010

Depending on then number of daily quotes he wants in there, he could adjust this field a number of ways.

 

from tinyint to:     (255 Integers)

smallint  (65,535 Integers)

mediumint (16,777,215 Integers)

bigint (18,446,744,073,709,551,615)  (Does anyone even know the word for the 18,446,... parts of that.  I know the 744 is trillions)

or even as you suggested

int (4,294,967,295)

 

Isn't it interesting to see what the limits are?

Quote · 22 Mar 2010

Next after trillion is ......


quadrillion
quintillion
sextillion
septillion
octillion
nonillion
decillion
undecillion
duodecillion
tredecillion
quattuordecillion
quindecillion
sexdecillion
septendecillion
octodecillion
novemdecillion
vigintillion
centillion

https://www.deanbassett.com
Quote · 22 Mar 2010

wow:)))

i changed it now to smallint (4) and i can insert now more....

thx

ue30 Mods - http://www.boonex.com/market/posts/ue30
Quote · 22 Mar 2010

wow:)))

i changed it now to smallint (4) and i can insert now more....

thx

That should be smallint(5) or smallint(6) Other wise numbers that are larger then 9999 will get truncated most likely without warning.

https://www.deanbassett.com
Quote · 22 Mar 2010

 

 

wow:)))

i changed it now to smallint (4) and i can insert now more....

thx

That should be smallint(5) or smallint(6) Other wise numbers that are larger then 9999 will get truncated most likely without warning.

 

 

Do you really think he will add more than a thousand quotes?  Well, then again he did easily break the 255 level didn't he.  LOL

Quote · 22 Mar 2010

i also don´t think so:-)

but maby it would be better if there comes a message that the db is full and no more entries are possible,

than a query error.

ue30 Mods - http://www.boonex.com/market/posts/ue30
Quote · 23 Mar 2010

ha ha ha, error-trapping, you gotta be kidding me.

problematically written source presents programatic problems.

you are asking for logic, and if you read the way this script is written, it is anything but logical.

Regards,

DosDawg

When a GIG is not enough --> Terabyte Dolphin Technical Support - Server Management and Support
Quote · 25 Mar 2010
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.