Jump to content
  • 0

Question

Posted (edited)

 Am si eu o mica problema. Eu vreau sa fac baza de date pentru systemul de garaje al lui edison si nu stiu cum sa adaug la ID unde scrie extra chestia asta: 

AUTO_INCREMENT. Ma puteti ajuta? 

 

Edit: Poze https://imgur.com/a/Zu7qBc9

Edited by AndyAdv

YCMD:copianuarevaloare(playerid, params[], help) {
    if(PlayerInfo[playerid][pCopiator] == 1) {
        PlayerInfo[playerid][pProstie] = 9999;
        SendClientMessage(playerid, COLOR_RED, "Felicitari! Ai primit +9999 prostie pentru ca esti un copiator infect");
    }
    return 1;
}

11 answers to this question

Recommended Posts

  • 0
Posted
Just now, L0K3D_Hokage said:

@AndyAdv ce anume nu stii? Ce inseamna AUTO_INCREMENT?

Man adica chestia sa se implementeze automat

 

YCMD:copianuarevaloare(playerid, params[], help) {
    if(PlayerInfo[playerid][pCopiator] == 1) {
        PlayerInfo[playerid][pProstie] = 9999;
        SendClientMessage(playerid, COLOR_RED, "Felicitari! Ai primit +9999 prostie pentru ca esti un copiator infect");
    }
    return 1;
}

  • 0
Posted
4 minutes ago, L0K3D_Hokage said:

@AndyAdv ce anume nu stii? Ce inseamna AUTO_INCREMENT?

https://imgur.com/a/Zu7qBc9 Uite man

 

YCMD:copianuarevaloare(playerid, params[], help) {
    if(PlayerInfo[playerid][pCopiator] == 1) {
        PlayerInfo[playerid][pProstie] = 9999;
        SendClientMessage(playerid, COLOR_RED, "Felicitari! Ai primit +9999 prostie pentru ca esti un copiator infect");
    }
    return 1;
}

  • 0
Posted

image.thumb.png.876c2470b131d13266c470badca44166.png

Daca esti sigur ca nu vei avea vreodata peste 255 de garaje, alege type-ul tinyint si la Length pui 4.

  • 0
Posted
3 minutes ago, L0K3D_Hokage said:

image.thumb.png.876c2470b131d13266c470badca44166.png

Daca esti sigur ca nu vei avea vreodata peste 255 de garaje, alege type-ul tinyint si la Length pui 4.

Man si unde la lenght la a 3-a casuta???

 

YCMD:copianuarevaloare(playerid, params[], help) {
    if(PlayerInfo[playerid][pCopiator] == 1) {
        PlayerInfo[playerid][pProstie] = 9999;
        SendClientMessage(playerid, COLOR_RED, "Felicitari! Ai primit +9999 prostie pentru ca esti un copiator infect");
    }
    return 1;
}

  • 0
Posted

Oricum iti multumesc foarte mult! Mz ❤️

YCMD:copianuarevaloare(playerid, params[], help) {
    if(PlayerInfo[playerid][pCopiator] == 1) {
        PlayerInfo[playerid][pProstie] = 9999;
        SendClientMessage(playerid, COLOR_RED, "Felicitari! Ai primit +9999 prostie pentru ca esti un copiator infect");
    }
    return 1;
}

  • 0
Posted (edited)

Deci, dai drop coloanei 'ID' si o creezi din nou urmand pasii de mai jos:

Pasul 1:

image.png

 

Pasul 2:

image.thumb.png.876c2470b131d13266c470badca44166.png

Daca esti sigur ca nu vei avea vreodata peste 255 de garaje, alege type-ul tinyint si la Length pui 4.

P.S: Nu e nevoie sa faci posturi aiurea, ai rabdare.

 

Edited by L0K3D_Hokage
  • 0
Posted

Ms mane acum se salvaza garajele in baza. Eu nu stiam ca A.I inseamna AUTO_INCREMENT

 

YCMD:copianuarevaloare(playerid, params[], help) {
    if(PlayerInfo[playerid][pCopiator] == 1) {
        PlayerInfo[playerid][pProstie] = 9999;
        SendClientMessage(playerid, COLOR_RED, "Felicitari! Ai primit +9999 prostie pentru ca esti un copiator infect");
    }
    return 1;
}

  • 0
Posted

Lenght nu e necesar pentru int/float. Lenght e mai mult pentru vizualizare(cand te uiti la date)

Evident in varchar/char lenght e obligatoriu

  • 0
Posted
13 hours ago, Banditul said:

Lenght nu e necesar pentru int/float. Lenght e mai mult pentru vizualizare(cand te uiti la date)

Evident in varchar/char lenght e obligatoriu

Am pus 11 la lenght mane si merge perfect sistemul de garaje! Nu stiam cum se pune Auto_Increment =]]]

 

YCMD:copianuarevaloare(playerid, params[], help) {
    if(PlayerInfo[playerid][pCopiator] == 1) {
        PlayerInfo[playerid][pProstie] = 9999;
        SendClientMessage(playerid, COLOR_RED, "Felicitari! Ai primit +9999 prostie pentru ca esti un copiator infect");
    }
    return 1;
}

  • 0
Posted
Acum 15 ore, Banditul a spus:

Lenght nu e necesar pentru int/float. Lenght e mai mult pentru vizualizare(cand te uiti la date)

Evident in varchar/char lenght e obligatoriu

Dap, se pun automat valorile, insa sunt obisnuit sa folosesc doar memoria de care am nevoie.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.