Duplicate error

Experienced Elementalist
Joined
May 8, 2009
Messages
262
Reaction score
63
Hi,

So at this moment i'm converting my database from Phoenix to BCstorm and i used a converter that was released somewhere on this forum (but the thread doesn't exist anymore) and I ran the converted SQL code for items_base in navicat and phpmyadmin. Both gave me the following error:

'Duplicate entry '65535' for key 'PRIMARY''

You can check the SQL query here:

I immediately checked if there was an ID called '65535' but there wasn't. So, i remade the whole table and converted all of the items myself, and i still got that same error.

What could be causing this?
 
Hi,

So at this moment i'm converting my database from Phoenix to BCstorm and i used a converter that was released somewhere on this forum (but the thread doesn't exist anymore) and I ran the converted SQL code for items_base in navicat and phpmyadmin. Both gave me the following error:

'Duplicate entry '65535' for key 'PRIMARY''

You can check the SQL query here:

I immediately checked if there was an ID called '65535' but there wasn't. So, i remade the whole table and converted all of the items myself, and i still got that same error.

What could be causing this?

go to HabboHotel > Items > ItemManager and find
Code:
uint id = Convert.ToUInt16(row[0]);
and change it to
Code:
uint id = Convert.ToUInt32(row[0]);

Also Edit

Go to butterfly/habbohotel/items/catalogs/catalogitems.cs
Edit from:
this.Items.Add((uint) int.Parse(this.ItemIdString));
To:
this.Items.Add((uint) uint.Parse(this.ItemIdString));

Credits to Giles121
 
Upvote 0
go to HabboHotel > Items > ItemManager and find
Code:
uint id = Convert.ToUInt16(row[0]);
and change it to
Code:
uint id = Convert.ToUInt32(row[0]);

Also Edit

Go to butterfly/habbohotel/items/catalogs/catalogitems.cs
Edit from:
this.Items.Add((uint) int.Parse(this.ItemIdString));
To:
this.Items.Add((uint) uint.Parse(this.ItemIdString));

Credits to Giles121


I can't realy see what that changes for my MySQL code error. I re-ran the code and it still gave me the exact same error.
 
Upvote 0
I can't realy see what that changes for my MySQL code error. I re-ran the code and it still gave me the exact same error.

You need to edit the Source of BCstorm so it can work, the int from phoenix is to long for bcstorm to read, i think it was like that. I did the change in my source and it worked perfectly.
 
Upvote 0
You need to edit the Source of BCstorm so it can work, the int from phoenix is to long for bcstorm to read, i think it was like that. I did the change in my source and it worked perfectly.

This is an error that came up when i ran the code in PHPmyadmin, so there is no link with BCstorm until BCstorm is running, but it isn't.
 
Upvote 0
This is an error that came up when i ran the code in PHPmyadmin, so there is no link with BCstorm until BCstorm is running, but it isn't.

Change that in the source and then try and you will see that it will work perfect, the int is to long for BCstorm to read thats why it do like that.
 
Upvote 0
That's weird. Are you sure you got the same error like i did?


Yes, many pepole got that error, then i did edit the source and tried again and it worked. Send me the php in pastebin in PM and i will look at it fast

EDIT!

Change item_id type to int
 
Upvote 0
Yes, many pepole got that error, then i did edit the source and tried again and it worked. Send me the php in pastebin in PM and i will look at it fast

EDIT!

Change item_id type to int

Great! SQL works now, but my emulator stops loading at 'Navigator -> READY!' :(
 
Upvote 0
You need to debug it in VB before you can run it like that, download visual basic C# and edit the source from there and debug the emulator
 
Upvote 0
Back