100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
Résumé Fiche des essentiels du SQL2 $3.20
Add to cart

Summary

Résumé Fiche des essentiels du SQL2

 2 views  0 purchase
  • Course
  • Institution

Fiche des essentiels du SQL2

Preview 1 out of 1  pages

  • March 29, 2023
  • 1
  • 2021/2022
  • Summary
avatar-seller
ORDRES DU LANGAGES
CREATE TABLE nomT CREATE TABLE tsclients
( liste attributs , (
Avec domaine [contrainte], id_clients CHAR(6) CONSTRAINT pk_tsclients PRIMARY KEY,
) code_civilite CHAR(2) CONSTRAINT fk_tscivilite REFERENCES tscivilite(id_civil),
CHAR(n) /* Longueur fixe nom VARCHAR(25) NOT NULL,
Construction de la BD

VARCHAR(n) /* Longueur variable date_naiss DATE,
CLOB /* >255 caractères cp CHAR(5) NOT NULL,
NUMERIC(n) /* Pour les entiers ville VARCHAR(25) NOT NULL,
NUMERIC (nbtot, nbapvirg) /* Pour les décimaux email VARCHAR(25) UNIQUE,
DATE note NUMERIC(3,1),
DATE TIME quantite NUMERIC(2),
PRIMARY KEY pk_ reduc NUMERIC(3,2) CONSTRAINT ck_tauxreduc CHECK reduc BETWEEN 0 AND 3
FOREIGN KEY fk_ )

ALTER TABLE nomT
ALTER TABLE tclient
ADD nouvel attribut + domaine [+Ci] /* Ajout attribut
ADD datenaiss DATE
MODIFY attr concerné + modif /* Modif attribut
MODIFY nom VARCHAR(10)
ADD CONSTRAINT nomC + contrainte /* Ajout contrainte
ADD CONSTRAINT ck_controleacces CHECK (codesecu IN (6, 7))
DROP CONSTRAINT nomC /* Suppr une contrainte
DROP COLUMN nomattribut /* Suppr un attribut

DROP TABLE nomT DROP TABLE tbenefice
INSERT INTO nomT INSERT INTO tnotes
Manipulation des




VALUES ( ) VALUES (‘mat01’, 1, 17, NULL, 0.4)
INSERT INTO nom (listattr) INSERT INTO tnotes (idmat, idnote, note, coeff)
données




VALUES ( ) VALUES (‘mat01’, 2, 16, 0.5)
UPDATE nomT UPDATE tproduits
SET nomA1 = valeur ou formule [, autre modification] SET pachat = pachat +1, pvente = pvente +1
[WHERE condition] WHERE origine != ‘France’
DELETE FROM tnotes
DELETE FROM nomT
WHERE idmat = ‘mat01’
[WHERE…]
AND idnote = 2
COMMIT Permet de valider une transaction
√ X Permet d’annuler un ensemble d’ordre SQL en cours
ROLLBACK
Cela permet d’enlever les données en instance d’enregistrement
GRANT SELECT, UPDATE, DELETE, INSERT, ALL
GRANT INSERT
Gestion des




ON nomT
ON tanimal
TO user1, user2, PUBLIC
droits




TO bd111
[WITH GRANT OPTION]

REVOKE S, U, D, I, A REVOKE INSERT
ON nomT ON tanimal
FROM user FROM bd111

The benefits of buying summaries with Stuvia:

Guaranteed quality through customer reviews

Guaranteed quality through customer reviews

Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.

Quick and easy check-out

Quick and easy check-out

You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.

Focus on what matters

Focus on what matters

Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!

Frequently asked questions

What do I get when I buy this document?

You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.

Satisfaction guarantee: how does it work?

Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.

Who am I buying these notes from?

Stuvia is a marketplace, so you are not buying this document from us, but from seller juliebonnet. Stuvia facilitates payment to the seller.

Will I be stuck with a subscription?

No, you only buy these notes for $3.20. You're not tied to anything after your purchase.

Can Stuvia be trusted?

4.6 stars on Google & Trustpilot (+1000 reviews)

50843 documents were sold in the last 30 days

Founded in 2010, the go-to place to buy study notes for 14 years now

Start selling
$3.20
  • (0)
Add to cart
Added