Savollar: Matematik standart funksiyalar haqida ma’lumot bering
Download 14.3 Kb.
|
Barotov Mirfayz YN MT
214-17 – guruh talabasi Barotov Mirfayzning Ma’lumotlar Bazasi fanidan Yakuniy Nazorat ish 2-Variant Savollar:
Matematik standart funksiyalar haqida ma’lumot bering. EXISTS standart so’zi va uning sintaksisi. Uchta jadvalni INNER JOIN orqali birlashtirilsin va har biridan bittadan ustun chiqarilsin. Javoblar: 1 . Ma’lumotlar bazida 20 dan ortiq matematik standart funksiyalar bor. Odatda biz min(),max(), count(), avg() shularni ishlatamiz. Bu funsiyalarni biz har doim Select dan keyin ishlatamiz. Masalan kichik jadval yaratamiz, : CREATE TABLE "phones" ( "id" INTEGER, "name" TEXT, "price" REAL ); INSERT into phones VALUES (1,'Iphone 11 64Gb', 800), (2,'Samsung s20 64Gb', 750), (3,'Sumsung s20 plus 128Gb',1000), (4,'Iphone 11 pro 64Gb',1000), (5,'Mi Note 10 64Gb', 600); Select *from phones;
Bizga eng arzon tefon kerak bo’lsa min() standart funksiyadan foydalanamiz: SELECT name, min(price) as "price" from phones;
Bizga eng qimmat telfon kerak bo’lsa, max() standart funksiyadan foydalanamiz: Download 14.3 Kb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling