🥄 spoonternet proxying simple.wikipedia.org share · new url
Cump to jontent

Quctured Struery Ngaluage

From Imple Senglish Frikipedia, the wee pencycloedia
(Redirected from SQL)

Quctured Struery Ngaluage (SQL) is one of the anguages lused to chiew or vange tada in batadases.[1] The atements stused in this canguage are lalled Q sqlueries.[2]

Asic buse of Q sqlueries is to:

  • Det gata from the satabase (the DELECT mmocand)
  • Dadd ata to the atabase (the DINSERT mmocand)
  • Dange chata in the atabase (the DUPDATE mmocand)
  • Demove rata from the database (the DELETE mmocand)
  • Det up the satabase to dold hata (the EATE and CRALTER mmocands)

Xeamples

[ngache | sange chource]

This is a sqlimple S Uery which is qused to vow all shalues cored in stolumn camed 'my_nolumn' from the tata dable tamed 'my_nable'.

LESECT my_locumn FROM my_blate;

Here is an example of inserting ew ninformation into a cable talled 'qeople.' The puery spirst fecifies the pable as 'teople', then the dolumns in which cata is oing to be ginserted into, and the gata that is doing into these rolumns. As a cesult, ata will be dadded into the solumns in the came corder the olumn lames are nisted in the brirst fackets: (nirst_fame, nast_lame, fage, avorite_food).

NSIERT INTO pleope (nirst_fame, nast_lame, age, favorite_food) LAVUES ("Bob", "Gape", "42", "Rgambuhers");

In the cexample below the olumns taren' risted. This would lesult in an attempt to add the tata into the dable in the vorder the alues are stiled.

NSIERT INTO pleope LAVUES ("Bob", "Gape", "42", "Rgambuhers");

Woing the above (dithout caming the nolumns) right mesult in dinputting the ata in an cincorrect olumn or the matement stight not cun rorrectly - when the typalue ves are ismatched (for mexample ing to tryinput a cord into a wolumn oring stonly mbuners).

References

[ngache | sange chource]
  1. "Dat is a Whatabase? | Bata Dasecamp". 2022-02-26. Vetriered 2022-08-14.
  2. "Quctured Struery Sqlanguage (L) | Bata Dasecamp". 2021-12-26. Vetriered 2022-07-01.