Another question

Post here your questions about Actionscript and Java server side extensions development.

Moderators: Lapo, Bax

User avatar
goodguy20k
Posts: 71
Joined: 10 Jan 2006, 23:58
Location: Texas, USA
Contact:

Another question

Postby goodguy20k » 24 Jan 2006, 01:50

I'm doing a db insert into my MySQL db. When I perform the command, it actually works, but I receive this error message in the log:

Code: Select all

2006/01/23 19:47:21.159 - [ SEVERE ] [id: 11] (DbManager.executeCommand): DbManager error during command execution: INSERT INTO userid (id, usr, pwd, email, ip, power) VALUES ('', 'test', 'test', 'test', '0.0.0.0', '1')


Any ideas? Also:

Code: Select all

var success = dbase.executeCommand(sql);
trace(success);

Returns false. Huh? If it actually places things in the db, why does it return false.

I think I'll ignore this for now so I can keep programming, but if you figure this out, let me know so I can get rid of this error and keep going.

Thanks!
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 24 Jan 2006, 16:55

Humm... I am just guessing...

try using this SQL instead:
INSERT INTO userid (usr, pwd, email, ip, power) VALUES ('test', 'test', 'test', '0.0.0.0', '1')


Let me know if it works
Lapo
--
gotoAndPlay()
...addicted to flash games
User avatar
goodguy20k
Posts: 71
Joined: 10 Jan 2006, 23:58
Location: Texas, USA
Contact:

Postby goodguy20k » 25 Jan 2006, 15:12

That worked great, thanks! Is that a bug, or just something I missed?
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 25 Jan 2006, 15:35

No it's not a bug. I think the problem is that you pass the id as an empty string. Since the id is an autoincrement number it is better not to include it in the INSERT command and just let the database create its value.

:)
Lapo

--

gotoAndPlay()

...addicted to flash games

Return to “Server Side Extension Development”

Who is online

Users browsing this forum: No registered users and 28 guests