SQLite help
#1

FIXED thanks to Larsey123
Reply
#2

pawn Код:
db_free_result(db_query(Database,"CREATE TABLE IF NOT EXISTS `A` (`1`,`2`,`3`)"));
Reply
#3

Okay, now that problem is solved. Now I am getting other errors.
Код:
C:\Users\Preston\Desktop\SA-MP Servers\Lsrcr\filterscripts\SQLite.pwn(82) : error 075: input line too long (after substitutions)
C:\Users\Preston\Desktop\SA-MP Servers\Lsrcr\filterscripts\SQLite.pwn(83) : error 037: invalid string (possibly non-terminated string)
C:\Users\Preston\Desktop\SA-MP Servers\Lsrcr\filterscripts\SQLite.pwn(83) : error 017: undefined symbol "CREATE"
C:\Users\Preston\Desktop\SA-MP Servers\Lsrcr\filterscripts\SQLite.pwn(83) : error 017: undefined symbol "TABLE"
C:\Users\Preston\Desktop\SA-MP Servers\Lsrcr\filterscripts\SQLite.pwn(83) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


5 Errors.
Reply
#4

Are you sure you put " in your script?
Show me the line.
Reply
#5

pawn Код:
db_free_result(db_query(Database, "CREATE TABLE IF NOT EXISTS `Users` (`IP`,`Name`,`Password`,`Money`,`Score`,`AdminLevel`,`RegularPlayer`,`SavedWantedLevel`,`SavedJailTime`,`RobRank`,`RapeRank`,`DrugDealerRank`,`GunDealerRank`,`HitmanRank`,`MedicRank`,`BountyHunterRank`,`KidnapperRank`,`TerroristRank`,`HasBriefcase`,`BriefcaseMoney`,`BriefcaseC4`,`BriefcaseWeaponSlot1`,`BriefcaseWeaponAmmoSlot1`,`BriefcaseWeaponSlot2`,`BriefcaseWeaponAmmoSlot2`,`BriefcaseWeaponSlot3`,`BriefcaseWeaponAmmoSlot3`,`CanUseSWAT`,`CanUseFBI`,`CanUseArmy`,`CopRank`,`Tazes`,`Cuffs`,`Arrests`,`SWATRank`,`FBIRank`,`ArmyRank`,`BanTime`,`BanReason`,`AdminWhoBanned`,`GrottiOwner`,`WangCarsOwner`,`OttosAutosOwner`,`AutobahnOwner`,`LSDrugHouseOwner`,`SFDrugHouseOwner`,`LVDrugHouseOwner`,`LSAirportOwner`,`SFAirportOwner`,`LVAirportOwner`,`YugoAirportOwner`)"));
Reply
#6

Код:
This forum requires that you wait 120 seconds between posts. Please try again in 59 seconds.
pawn Код:
db_free_result(db_query(Database,"CREATE TABLE IF NOT EXISTS `Users` (`IP`,`Name`,`Password`,`Money`,`Score`,`AdminLevel`,`RegularPlayer`,`SavedWantedLevel`,`SavedJailTime`,`RobRank`,`RapeRank`,`DrugDealerRank`,`GunDealerRank`,`HitmanRank`,`MedicRank`,`BountyHunterRank`,`KidnapperRank`,`TerroristRank`,`HasBriefcase`,`BriefcaseMoney`,`BriefcaseC4`,`BriefcaseWeaponSlot1`,`BriefcaseWeaponAmmoSlot1`,`BriefcaseWeaponSlot2`,`BriefcaseWeaponAmmoSlot2`,`BriefcaseWeaponSlot3`,`BriefcaseWeaponAmmoSlot3`,`CanUseSWAT`,`CanUseFBI`,`CanUseArmy`,`CopRank`,`Tazes`,`Cuffs`,`Arrests`,`SWATRank`,`FBIRank`,`ArmyRank`,`BanTime`,`BanReason`,`AdminWhoBanned`,`GrottiOwner`,`WangCarsOwner`,`OttosAutosOwner`,`AutobahnOwner`,`LSDrugHouseOwner`,`SFDrugHouseOwner`,`LVDrugHouseOwner`,`LSAirportOwner`,`SFAirportOwner`,`LVAirportOwner`,`YugoAirportOwner`)"));
It looks nearly identical to the example that you posted earlier.
Reply
#7

Sorry, i didnt notice
Reply
#8

I'm trying out something that my friend showed me.
pawn Код:
public OnFilterScriptInit( )
{
    new Query[1024];
    Database = db_open("SArcr.db");
    format(Query, sizeof(Query),"CREATE TABLE IF NOT EXISTS `Users` (`IP`,`Name`,`Password`,`Money`,`Score`,`AdminLevel`,`RegularPlayer`,`SavedWantedLevel`,`SavedJailTime`,`RobRank`,`RapeRank`,`DrugDealerRank`,`GunDealerRank`,`HitmanRank`,`MedicRank`,`BountyHunterRank`,`KidnapperRank`,`TerroristRank`,`HasBriefcase`,`BriefcaseMoney`,`BriefcaseC4`,`BriefcaseWeaponSlot1`,`BriefcaseWeaponAmmoSlot1`,`BriefcaseWeaponSlot2`,`BriefcaseWeaponAmmoSlot2`,`BriefcaseWeaponSlot3`,`BriefcaseWeaponAmmoSlot3`,`CanUseSWAT`,`CanUseFBI`,`CanUseArmy`,`CopRank`,`Tazes`,`Cuffs`,`Arrests`,`SWATRank`,`FBIRank`,`ArmyRank`,`BanTime`,`BanReason`,`AdminWhoBanned`,`GrottiOwner`,`WangCarsOwner`,`OttosAutosOwner`,`AutobahnOwner`,`LSDrugHouseOwner`,`SFDrugHouseOwner`,`LVDrugHouseOwner`,`LSAirportOwner`,`SFAirportOwner`,`LVAirportOwner`,`YugoAirportOwner`)");
    db_free_result(db_query(Database, Query));
    return 1;
}
Still getting same errors though :/
Reply
#9

Example of mine
pawn Код:
new DB:USERDB,DBResult:Result;

USERDB = db_open("123.db");
db_free_result(db_query(USERDB,"CREATE TABLE IF NOT EXISTS `A` (`q`,`w`,`e`)"));
db_free_result(Result);
Reply
#10

same errors no matter what i do lol
Reply


Forum Jump:


Users browsing this thread: 4 Guest(s)