Hello everyone.. I post here too in Eng Section for people who dont understand Gr and maybe can help
I get an error while creating character in my server and i get this
Could not insert char data: Parameter index out of range (38 > number of paramet
ers, which is 37).
java.sql.SQLException: Parameter index out of range (38 > number of parameters,
which is 37).
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1073)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:987)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:982)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:927)
at com.mysql.jdbc.PreparedStatement.checkBounds(PreparedStatement.java:3
729)
at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3
713)
at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3
755)
at com.mysql.jdbc.PreparedStatement.setDate(PreparedStatement.java:3631)
at com.mysql.jdbc.PreparedStatement.setDate(PreparedStatement.java:3600)
at com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.setDate(NewProxyPr
eparedStatement.java:937)
at com.l2jserver.gameserver.model.actor.instance.L2PcInstance.createDb(L
2PcInstance.java:7545)
at com.l2jserver.gameserver.model.actor.instance.L2PcInstance.create(L2P
cInstance.java:1207)
at com.l2jserver.gameserver.network.clientpackets.CharacterCreate.runImp
l(CharacterCreate.java:184)
at com.l2jserver.gameserver.network.clientpackets.L2GameClientPacket.run
(L2GameClientPacket.java:62)
at com.l2jserver.gameserver.network.L2GameClient.run(L2GameClient.java:1
095)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source
So i go to: java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java
and i add 1 " ? " in values INSERT_CHARACTER and i get the same error again cause i didnt update the other 2 ones UPDATE_CHARACTER and RESTORE_CHARACTER ....And here is where i need help cause i dont know what to "change" in those 2....Here is my PcInstance.java
//Character Character SQL String Definitions:
private static final String INSERT_CHARACTER = "INSERT INTO characters (account_name,charId,char_name,level,maxHp,curHp,maxCp,curCp,maxMp,curMp,face,hairStyle,hairColor,sex,exp,sp,karma,fame,pvpkills,pkkills,clanid,race,classid,deletetime,cancraft,title,title_color,accesslevel,online,isin7sdungeon,clan_privs,wantspeace,base_class,newbie,nobless,power_grade,createDate) values (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)";
private static final String UPDATE_CHARACTER = "UPDATE characters SET level=?,maxHp=?,curHp=?,maxCp=?,curCp=?,maxMp=?,curMp=?,face=?,hairStyle=?,hairColor=?,sex=?,heading=?,x=?,y=?,z=?,exp=?,expBeforeDeath=?,sp=?,karma=?,fame=?,pvpkills=?,pkkills=?,clanid=?,race=?,classid=?,deletetime=?,title=?,title_color=?,accesslevel=?,online=?,isin7sdungeon=?,clan_privs=?,wantspeace=?,base_class=?,onlinetime=?,punish_level=?,punish_timer=?,newbie=?,nobless=?,power_grade=?,subpledge=?,lvl_joined_academy=?,apprentice=?,sponsor=?,clan_join_expiry_time=?,clan_create_expiry_time=?,char_name=?,death_penalty_level=?,bookmarkslot=?,vitality_points=?,language=? WHERE charId=?";
private static final String RESTORE_CHARACTER = "SELECT account_name, charId, char_name, level, maxHp, curHp, maxCp, curCp, maxMp, curMp, face, hairStyle, hairColor, sex, heading, x, y, z, exp, expBeforeDeath, sp, karma, fame, pvpkills, pkkills, clanid, race, classid, deletetime, cancraft, title, title_color, accesslevel, online, char_slot, lastAccess, clan_privs, wantspeace, base_class, onlinetime, isin7sdungeon, punish_level, punish_timer, newbie, nobless, power_grade, subpledge, lvl_joined_academy, apprentice, sponsor, clan_join_expiry_time,clan_create_expiry_time,death_penalty_level,bookmarkslot,vitality_points,createDate,language FROM characters WHERE charId=?";
Thanks in Regards!!!! I would appreciate and help/discuss :D
New update!
A gift coupon system has been added.
Now you can activate gift coupons directly in the bot:
Open "My Profile"
Tap "Activate gift coupon"
Enter the coupon code
The balance will be topped up automatically.
Received a coupon? Activate it and top up your balance.
Buy Telegram Stars with maximum benefit in our bot
New update!
A gift coupon system has been added.
Now you can activate gift coupons directly in the bot:
Open "My Profile"
Tap "Activate gift coupon"
Enter the coupon code
The balance will be topped up automatically.
Received a coupon? Activate it and top up your balance.
Buy Telegram Stars with maximum benefit in our bot
New update!
A gift coupon system has been added.
Now you can activate gift coupons directly in the bot:
Open "My Profile"
Tap "Activate gift coupon"
Enter the coupon code
The balance will be topped up automatically.
Received a coupon? Activate it and top up your balance.
Buy Telegram Stars with maximum benefit in our bot
Dear users! We are happy to announce a major update of our bot!
What’s new:
Long-term number rental
You can now rent virtual numbers for a long period (hours, days, or months)! This is perfect for those who need constant access to a number to receive SMS from various services.
Number history
A new feature allows you to view all your rented numbers in one place! You can:
• See the full history of all numbers (instant and long-term)
• View all received SMS codes
• Return to active numbers to receive additional SMS
• See the status of each number
Gift coupon system
You can now activate gift coupons directly in the bot! Just go to your profile and click “Activate gift coupon” — your balance will be topped up automatically!
Chinese language
Full support for the Chinese language has been added! The bot is now available in three languages: Russian, English, and Chinese. Switching languages has become even more convenient.
Improved rental process
Before purchasing a number, detailed service information is now displayed:
• Service name
• Ability to receive repeated SMS
• Rental duration
• Cost
This will help you make a more informed decision before renting.
Quick rental
The “Virtual numbers (SMS)” button has now been renamed to “Quick rental” for greater clarity and convenience.
Go to the SMS service
Question
kryptic
Hello everyone.. I post here too in Eng Section for people who dont understand Gr and maybe can help
I get an error while creating character in my server and i get this
So i go to: java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java
and i add 1 " ? " in values INSERT_CHARACTER and i get the same error again cause i didnt update the other 2 ones UPDATE_CHARACTER and RESTORE_CHARACTER ....And here is where i need help cause i dont know what to "change" in those 2....Here is my PcInstance.java
//Character Character SQL String Definitions:
Thanks in Regards!!!! I would appreciate and help/discuss :D
Edited by kryptic2 answers to this question
Recommended Posts