blob_id
stringlengths
40
40
language
stringclasses
1 value
repo_name
stringlengths
5
133
path
stringlengths
3
276
src_encoding
stringclasses
33 values
length_bytes
int64
23
9.61M
score
float64
2.52
5.28
int_score
int64
3
5
detected_licenses
listlengths
0
44
license_type
stringclasses
2 values
text
stringlengths
23
9.43M
download_success
bool
1 class
849e0c8e80759d359f70949588478029ec17016b
SQL
krisztianKollar/northwindqueries
/task5.sql
UTF-8
274
3.71875
4
[]
no_license
select s.companyname, p.productname, p.unitprice from products as p join suppliers as s on s.supplierid = p.supplierid left join products as pp on p.supplierid = pp.supplierid and p.unitprice > pp.unitprice where pp.productid is null order by p.supplierid, p.unitprice
true
51de2dfad4692d7c1287af3d00728ca6204c419e
SQL
tortoise4race/SQL
/labs/tn1/workshops/wksh_PGA_3.sql
UTF-8
661
3.203125
3
[]
no_license
set termout off set verify off set feedback off spool &1 replace select PROD_ID, AVG(unit_cost) from costs GROUP BY prod_id; COMMIT; select s.prod_id, sum(s.amount_sold) - sum(c.unit_cost) from costs c, sales s where c.prod_id = s.prod_id and s.prod_id = 142 group by s.prod_id / COMMIT; select PROD_ID,...
true
c49dfbda83b020873cef93d90a2b24e3f454262a
SQL
AgustinJimenez/learn_libs
/ORACLE/TRIG_02.sql
UTF-8
2,120
3.8125
4
[]
no_license
CREATE OR REPLACE TRIGGER T_ACTUALIZA_STOCK AFTER INSERT OR UPDATE OF CANTIDAD ON B_DETALLE_VENTAS FOR EACH ROW DECLARE V_STOCK B_ARTICULOS.STOCK_ACTUAL%TYPE; V_NS B_ARTICULOS.STOCK_ACTUAL%TYPE; V_CANT NUMBER; V_ERROR EXCEPTION; BEGIN SELECT STOCK_ACTUAL INTO V_STOCK FROM B_ARTICULOS WHE...
true
81db59b89d59f2877c0d7c5a3c1e5d5b4ee62156
SQL
dbacorp/aspen
/Scripts/BI_MDM/MDTR_MNSL/TB_STG_FT_MDTR_MNSL.sql
UTF-8
1,438
3.21875
3
[]
no_license
DROP TABLE BI.TB_STG_FT_MDTR_MNSL; TRUNCATE TABLE BI.TB_STG_FT_MDTR_MNSL; CREATE TABLE BI.TB_STG_FT_MDTR_MNSL ( SK_OUTL VARCHAR2(10), SK_PFLGS VARCHAR2(10), SK_PRV VARCHAR2(10), SK_RGN VARCHAR2(3), SK_TRR VARCHAR2(9), SK_TMP_APRC INT, SK_TMP_PRD INT, FLG_CL_LT VARCHAR2(1), VL_QT_VND INT, VL_QT_TOT_VND INT, DT_ULT_AT...
true
a8a81db9a81ba4a7b04e51fdf073b712c496f0fd
SQL
jihye0325/June-Code2
/SQL03_SELECT(Option)1~7.sql
UHC
1,712
3.796875
4
[]
no_license
-- 1 SELECT STUDENT_NAME "л ̸" , STUDENT_ADDRESS "ּ" FROM TB_STUDENT ORDER BY 1; -- 2 SELECT STUDENT_NAME , STUDENT_SSN FROM TB_STUDENT WHERE ABSENCE_YN = 'Y' ORDER BY 2 DESC; -- 3 SELECT STUDENT_NAME "л̸" , STUDENT_NO "й" , STUDENT_ADDRESS " ּ" FROM TB_STUDENT...
true
2eacaa2c968e735ed8d5deda1c8e5f1aaff9831d
SQL
shoter/ylperJ
/Ylperj-database/schedule.sql
UTF-8
397
3.125
3
[ "MIT" ]
permissive
USE YlperJ; CREATE TABLE Schedules ( Id BIGINT NOT NULL AUTO_INCREMENT, UserId BIGINT NOT NULL, CarId BIGINT NOT NULL, DesiredStartDateTime DATETIME NOT NULL, DesiredPickupPosition POINT NOT NULL, DesiredEndDateTime DATETIME, DesiredDropPosition POINT, PRIMARY KEY(Id), FOREIGN K...
true
115a99e221f2dd216a8b889d41323f1f9beb8eb9
SQL
fuck2ky/hlbSale
/tools/excel_convertor/test_data/create_sql/Item_Combine.sql
UTF-8
409
2.75
3
[]
no_license
-- -- Table structure for table `Item_Combine` -- DROP TABLE IF EXISTS `Item_Combine`; CREATE TABLE IF NOT EXISTS `Item_Combine` ( `id` int(11) NOT NULL COMMENT '目标道具ID', `consume` text COMMENT '作者: 所需材料', `target_equip` int(11) COMMENT '作者: 目标装备ID', `count` int(11) COMMENT '作者: 数量', PRIMARY KEY (`id`) ) ENGINE=InnoDB...
true
a798f986ba030ea380b869f73d40d4889d4aab79
SQL
TAJWAR99/Petshop
/db/petshop.sql
UTF-8
4,918
3.015625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Jul 29, 2019 at 04:58 PM -- Server version: 5.7.26 -- PHP Version: 7.3.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHA...
true
26d03888db855bc206c243e4786acc6317036bdb
SQL
cpainterwakefield/fs-team-assembler
/backend/db_scripts/statistic_queries.sql
UTF-8
1,670
3.71875
4
[ "Apache-2.0" ]
permissive
-- query to receive total numbe of students SELECT COUNT(*) FROM students; --query to receive total number of students who preferred team SELECT COUNT(*) FROM students WHERE selection_preference = true; --query to receive total number of students who preferred project SELECT COUNT(*) FROM students WHERE selection_pr...
true
193ec04937870394583d30c6d8223158989f430c
SQL
AAranda10/database-exercises
/where_exercises.sql
UTF-8
1,123
3.625
4
[]
no_license
use employees; #2 select first_name, last_name from employees where first_name in ('Irena', 'Vidya' ,'Maya'); #2-2 select first_name, last_name from employees where first_name = 'Irena' or first_name = 'Vidya' or first_name = 'Maya'; #2-3 select first_name, last_name from employees where first_name in ('Irena', 'Vidy...
true
1f2a3403512d63a253d0586fc38ea27be2955f5f
SQL
fromdeno/registry
/migrations/2021-06-11-064300_user/up.sql
UTF-8
412
2.546875
3
[]
no_license
CREATE TABLE user ( id VARCHAR NOT NULL PRIMARY KEY, username VARCHAR(36) NOT NULL UNIQUE, email VARCHAR(72) NOT NULL UNIQUE, password VARCHAR(36) NOT NULL, token VARCHAR(36) NOT NULL, verification_code VARCHAR(36) UNIQUE DEFAULT NULL, is_verified BOOLEAN NOT NULL DEFAULT 0, is_admin BOOLEAN NOT NULL DEFAULT 0,...
true
f02a3a066d60f377a472abbc3a4da55290a853c8
SQL
silentbalanceyh/vertx-zero
/vertx-pin/zero-ambient/src/main/resources/plugin/sql/ambient/X_ACTIVITY_CHANGE.sql
UTF-8
1,836
3.546875
4
[ "LicenseRef-scancode-unknown-license-reference", "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
-- liquibase formatted sql -- changeset Lang:ox-activity-change-1 -- 变更记录表:X_ACTIVITY_CHANGE DROP TABLE IF EXISTS X_ACTIVITY_CHANGE; CREATE TABLE IF NOT EXISTS X_ACTIVITY_CHANGE ( `KEY` VARCHAR(36) COMMENT '「key」- 操作行为主键', `ACTIVITY_ID` VARCHAR(36) COMMENT '「activityId」- 关联的操作ID', -- 是否变更记录 `T...
true
35efb4f770c2cf42dae2ade28b0a2638c430bde5
SQL
sd6364152/Wb_da_script
/Quinn/killer/躲猫猫流失用户分析/新用户模式占比.sql
UTF-8
926
3.765625
4
[]
no_license
SELECT t2.date, t2.game_dnu, t1.gameSubType, t1.subtype_num FROM (SELECT date,gameSubType, count(DISTINCT distinct_id)AS subtype_num FROM events WHERE event = 'gameStart' AND gameTypeId = 1800 AND game_played = 0 AND date BETWEEN '2020-10-20' AND current_date(...
true
7d2a5e026cf5a4c4516383f7a4636b8a06594ac9
SQL
Praveenramkannan/SQL_Assignments
/Assingment 3/assingment-3-master/Solution for grading set/line_items_per_invoice.sql
UTF-8
264
2.859375
3
[]
no_license
/*Submission by praveen.ram.kannan@accenture.com */ /* 11.line_items_per_invoice.sql: Looking at the InvoiceLine table, provide a query that COUNTs the number of line items for each Invoice. HINT: GROUP BY*/ select invoiceid,count(quantity) from invoiceline group by(invoiceid);
true
5928c2120ac01cfd007e6cb2ded10cb3f2ffe91b
SQL
AnimeshInc/WEB
/ЛР №10/SQL18.sql
UTF-8
678
3.296875
3
[]
no_license
SELECT dautov_user.firstname, dautov_user.lastname, dautov_user.patronomic, dautov_gruppa.name AS gruppa, dautov_special.name AS special, dautov_course.hours FROM dautov_course INNER JOIN dautov_special ON dautov_course.special_id = dautov_special.special_id AND dautov_course.hours > "...
true
f8e42fc0410c9fa75014bbebe2e3a26c42c94443
SQL
paridhijha/thesis
/mysql_script.sql
UTF-8
12,659
3.140625
3
[]
no_license
mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('Pass1234'); mysql> create database yelp_all; Query OK, 1 row affected (0.21 sec) mysql> use yelp_all; Database changed Execute json_to_csv_dataset.convert_split_user() Execute json_to_csv_dataset.convert_busnss() Execute json_to_csv_dataset.filter_rests() mysql>...
true
fb31ac80a74d748768b8a20730c4c9b356a4b6fe
SQL
Judenpech/BeginningAlgorithmContests
/LeetCode/620. 有趣的电影.sql
UTF-8
184
3.03125
3
[]
no_license
# Write your MySQL query statement below SELECT c.id,c.movie,c.description,c.rating FROM cinema c WHERE MOD(c.id,2)=1 AND c.description!="boring" ORDER BY c.rating DESC;
true
7c2eab339acc9523de6440e759645e0db4ab5851
SQL
chaves/dfih_sources
/_output/table_sources.sql
UTF-8
727
2.734375
3
[]
no_license
# # SQL Export # Created by Querious (201054) # Created: 13 January 2019 at 13:26:30 CET # Encoding: Unicode (UTF-8) # SET @PREVIOUS_FOREIGN_KEY_CHECKS = @@FOREIGN_KEY_CHECKS; SET FOREIGN_KEY_CHECKS = 0; DROP TABLE IF EXISTS `sources`; CREATE TABLE `sources` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `c...
true
f3af6c8cf339efd5237beafcc3bc419a49a6e519
SQL
rbailen/Music
/MySQL/2.- Creación de las tablas/13.- cancion_letrista.sql
UTF-8
632
3.421875
3
[]
no_license
CREATE TABLE `music`.`cancion_letrista` ( `idcancion_letrista` INT NOT NULL AUTO_INCREMENT, `idcancion` INT NULL, `idletrista` INT NULL, PRIMARY KEY (`idcancion_letrista`), INDEX `cancion_letrista_cancion_idx` (`idcancion` ASC), INDEX `cancion_letrista_letrista_idx` (`idletrista` ASC), CONSTRAINT `cancion...
true
5e857dcb7f4ab87970d60523b6e7c6c81a2afd30
SQL
ainar/observatoire-covoiturage
/etl/src/database/sql/perimeters/create_table_regions.sql
UTF-8
256
2.921875
3
[ "Apache-2.0" ]
permissive
DROP TABLE IF EXISTS perimeters.regions; CREATE TABLE IF NOT EXISTS perimeters.regions ( id SERIAL PRIMARY KEY, reg varchar(3), l_reg varchar, geom geometry(MULTIPOLYGON,4326) ); CREATE INDEX regions_id_index ON perimeters.regions USING btree (id);
true
eefe7ddc3d1390423529a3fbfd769c199d4ced36
SQL
stevblag/sql-challenge
/EmployeeSQL/DB-diagram_Table-schema.sql
UTF-8
654
2.765625
3
[]
no_license
# https://app.quickdatabasediagrams.com/#/d/IVG5iX # To modify this code in order to update the DB schema diagram, please vist the link above and paste the revised code below: departments - dept_no VARCHAR PK dept_name VARCHAR dept_emp - emp_no INT FK >- employees.emp_no dept_no VARCHAR FK >- departments.dept_no ...
true
d53aab6ff79c9bd27fc1691e75df5a111ebd3caa
SQL
ParsianInsuranceGIT/sanam
/queries/[1393-06-30] Update vahedSodor_id for Bimename & Elhaghie.sql
UTF-8
787
3.03125
3
[]
no_license
------------------------Elhaghie_VahedSodor_Update------------------------------ update tbl_elhaghiye el set el.vahedsodor_id=( select n.id from tbl_namayande n join tbl_users u on u.vahed_sodoor_id=n.id where u.user_id=el...
true
1c5980f810a2d18144fa43fc3476646629773b58
SQL
2018hsridhar/Leetcode_Solutions
/leetcode_2356.sql
UTF-8
418
3.65625
4
[]
no_license
#2356. Number of Unique Subjects Taught by Each Teacher # URL = https://leetcode.com/problems/number-of-unique-subjects-taught-by-each-teacher/ # Write your MySQL query statement below # Can we even use the DISTINCT keyword here? # Introduce use of alias here # Notice usage of count and then group_by later ( to partiti...
true
4508068b32fe854b62828d884a8e4ecccff84b14
SQL
anannyac/Datawarehouse5610_1st-sem
/Assignment 2/Anannya-Chatterjee-Assign2/Tpt_DimMod_Exported_Tables/tpt_dim_seller_anannyac.sql
UTF-8
3,127
2.71875
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.21, for Win64 (x86_64) -- -- Host: localhost Database: tpt_dim -- ------------------------------------------------------ -- Server version 5.7.31-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESU...
true
94f10588e20020e8c5988f6fcd41139ee2f999b7
SQL
JorgeDuenasLerin/desarrollo-web
/IAW/02_DB/db.sql
UTF-8
487
2.875
3
[]
no_license
USE gestionaplus; DROP TABLE IF EXISTS Frutas; CREATE TABLE Frutas ( id MEDIUMINT NOT NULL AUTO_INCREMENT, nombre varchar(255), precio DECIMAL(10,2), PRIMARY KEY (id) ); INSERT INTO Frutas (nombre, precio) VALUES ('Naranja', 1.99); INSERT INTO Frutas (nombre, precio) VALUES ('Manzana', 2.19); INSERT INTO Fru...
true
0fbf028aeb7983879431495cd6c21a493dab766c
SQL
Zhengzhibo1/SQL-practice
/41_构造一个触发器audit_log/solution.sql
UTF-8
848
4.0625
4
[]
no_license
/* 构造一个触发器audit_log,在向employees_test表中插入一条数据的时候,触发插入相关的数据到audit中。 CREATE TABLE employees_test( ID INT PRIMARY KEY NOT NULL, NAME TEXT NOT NULL, AGE INT NOT NULL, ADDRESS CHAR(50), SALARY REAL ); CREATE TABLE audit( EMP_no INT NOT NULL, NAME TEXT NOT NULL ); */ /* 1、用 CREATE TRIGGER 语句构造触发器,用 BEFORE或AFTER 来指定在执行后面的SQL语...
true
d90c2ce9b9bdfda075c02e0466eaaeefc211ae63
SQL
0415wangyibo/learningDemo
/AuthenticationDemo/redis/AuthenticationDemo/src/main/resources/init.sql
UTF-8
9,209
3.4375
3
[]
no_license
CREATE TABLE organization ( id INT AUTO_INCREMENT PRIMARY KEY, organization_name VARCHAR(255) NULL COMMENT '组织的名字', max_number INT NULL COMMENT '同一组织最多能创建的管理员个数' ) ENGINE = InnoDB; CREATE TABLE sys_permission ( id INT AUTO_INCREMENT PRIMARY KEY, permi...
true
4ef8720027fbf73401b8144163e489bfaab8dde8
SQL
Baft/BaftFeedback
/bin/insertGroup.sql
UTF-8
450
2.59375
3
[ "MIT" ]
permissive
set @feedbackParentGroup:=124; set @gorder:=-1; set @groupLabel:=''; -- ---------------------------------------------- select @gname:=concat('G',max( if(left(`name`,1)="G",cast( substring(`name` FROM 2)+1 as unsigned ) , 0 ) ) )as gname , from insp_v2.baftfeedback_question_group; INSERT INTO `insp_v2`.`baftfeedb...
true
a73dfcd5f884adbd8bdf64e2c75fa087a69752ed
SQL
endura-sys/erp-sys
/database/sakedb.sql
UTF-8
28,071
3.296875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.5 -- https://www.phpmyadmin.net/ -- -- Host: localhost:3306 -- Generation Time: Aug 05, 2021 at 07:49 AM -- Server version: 5.7.24 -- PHP Version: 7.4.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHA...
true
5b0c4748d3d2046f9c43b2d40fc8d90503019ec9
SQL
popebob/collegefiles
/CSC384/1st Try/CRProduct/CRProduct.sql
UTF-8
1,994
2.8125
3
[]
no_license
CREATE TABLE Product ( ProdNo CHAR(8), ProdName VARCHAR2(50) CONSTRAINT ProdNameRequired NOT NULL, ProdMfg VARCHAR2(20) CONSTRAINT ProdMfgRequired NOT NULL, ProdQOH INTEGER, ProdPrice DECIMAL(12,2), ProdNextShipDate DATE, CONSTRAINT PKProduct PRIMARY KEY (ProdNo) ); ...
true
f2eda3d35c93632a9ce794b2552603b9674ad210
SQL
LvianaDev/SQL-Server-University
/Script - 10 para insercao de dados na tabela GRADE-01.sql
UTF-8
69,752
2.6875
3
[]
no_license
-- OBJETIVO do SCRIPT:POPULAR TABELAS -- INSERÇÃO DE DADOS NA TABELA GRADE - 01 -- use FmuAds_Segunda INSERT INTO grp01.GRADE (turcur, turma, codcurso, coddisciplina, codprof, diasemana, horarioaula, turno) VALUES ('TUSCNMA660','TUSCNMA','124','660','100067','Quinta','18:00:00','NM'), ('TUSCNMA671','TUSCNMA','124','671...
true
3a9a818fedf8df8b90d30008617753bec56a9bc9
SQL
jewelazo/ed_team
/query4.sql
UTF-8
593
4.0625
4
[]
no_license
/* QUERY DE CLIENTES QUE HAN COMPRADO POR LO MENOS 1 PRODUCTO OJO:EL CAMPO VALOR_TOTAL ES EL VALOR ACUMULADO DE TODOS LOS PRODUCTOS COMPRADOS POR CADA CLIENTE*/ SELECT CL.CLIENTE,CL.TELEFONO,CL.CORREO,CL.COUNTRY,CL.DIREC DIRECCION,SUM(CL.TOTAL)VALOR_TOTAL FROM (SELECT C.NOMCLI CLIENTE,C.CORREO,C.COUNTRY,C.DIREC,C.TEL...
true
f9e000642db8151a11f4fb28c38e1b37b9185bb1
SQL
muhammedazman/ReCapProject
/users_customers_rentals.sql
UTF-8
877
3.78125
4
[]
no_license
/*CREATE TABLE Users ( USERID int IDENTITY (1,1) PRIMARY KEY , FIRSTNAME varchar(255) NOT NULL, LASTNAME varchar(255) NOT NULL, EMAIL varchar(255) NOT NULL, PASSWORD varchar(255) NOT NULL, CONSTRAINT UC_USERNAME UNIQUE(FIRSTNAME, LASTNAME), CONSTRAINT UC_USERID UNIQUE(USERID) );*/ /* CREATE TABLE Customers ( C...
true
9efa52e5e97e3fb53a18b79d3932114b928e872d
SQL
tringuyen22095/UserManager
/doc/query.sql
UTF-8
6,826
3.28125
3
[]
no_license
DROP TABLE IF EXISTS PUBLIC."common"; CREATE TABLE PUBLIC."common" ( "id" SERIAL PRIMARY KEY, "type" VARCHAR(64), "value" VARCHAR(64), "text" VARCHAR(128), "description" VARCHAR(256), "sequence" INT4, "parent_id" INT4, "is_deleted" BOOLEAN NOT NU...
true
17f0e2086a6627eb71aca3a24a0a78aa69ffd89d
SQL
CuVees/SQL
/MF/练习1.1.sql
UTF-8
1,854
4.625
5
[]
no_license
select * from ( ( select dt 放款日期, product_id 产品描述, miaoshu 描述, sum(fangkuan) 放款金额, sum(yingshou) 应收金额, sum(shishou) 实收金额, sum(yuqi) 逾期, group_concat(concat(manager_name,cnt) separator ',') 放款人 from ( select DATE_FORMAT(cr.arrive_time,'%Y%m%d') dt, product_id, ...
true
9b9809c4be5384fcb663a85125c2a6f4288d4d97
SQL
Sebastianamayag/back-proyecto1
/database/database.sql
UTF-8
240
2.796875
3
[]
no_license
CREATE DATABASE AcademiaLaVictoria; CREATE TABLE Users( id SERIAL PRIMARY KEY, name VARCHAR(40), role TEXT, canAccess BOOLEAN ); INSERT INTO users(name,role,canAccess) VALUES ('camilo','admon',true), ('sebastian','estudent',false);
true
b479412783af5acc6d1d48610c4b7b123df79e2d
SQL
arraisi/auth-server-blud
/src/main/resources/db/migration/oracle11/V2019_07_20_19_00_14__schema-users.sql
UTF-8
2,812
3.65625
4
[ "Apache-2.0" ]
permissive
-- create table AUTH_USERS -- ( -- id varchar2(64) not null primary key, -- username varchar2(100) not null unique, -- password varchar2(255) not null, -- email varchar2(50), -- ...
true
b306b94795b79491fdd72d9f1b23464c2fd84fee
SQL
jampaniuday/sql_source
/sql/pivot/example_1.sql
UTF-8
240
3.1875
3
[]
no_license
SELECT * FROM (SELECT product, channel, amount_sold FROM sales_view_2 ) S PIVOT (SUM(amount_sold) FOR CHANNEL IN (3 AS DIRECT_SALES, 4 AS INTERNET_SALES, 5 AS CATALOG_SALES, 9 AS TELESALES)) ORDER BY product;
true
1936e7c04e8825366f01e50c4e6228cd1099cc3a
SQL
ujjwal1212/koolguruweb
/DBscript/28122015_anu.sql
UTF-8
1,332
3.359375
3
[]
no_license
-- -- Table structure for table `student_status` -- CREATE TABLE IF NOT EXISTS `student_status` ( `id` bigint(10) NOT NULL AUTO_INCREMENT, `student_id` bigint(10) NOT NULL, `registration_status` tinyint(10) NOT NULL, `verbal_reg_status` tinyint(10) NOT NULL, `marks_obtain_verbal` int(100) NOT NULL, ...
true
74e33c9bc6fa3a045dca71146af8f9fc650c59a1
SQL
OgnjenArsenijevic/LeetCode-solutions
/586. Customer Placing the Largest Number of Orders.sql
UTF-8
250
3.328125
3
[]
no_license
/* 586. Customer Placing the Largest Number of Orders Author: Ognjen Arsenijevic username: ognjen1998 */ SELECT customer_number FROM orders GROUP BY customer_number HAVING COUNT(order_number)>=ALL(SELECT COUNT(order_number) FROM orders GROUP BY customer_number)
true
53847ed8c89a4b963f990f9a601e6c059cfc40b0
SQL
jkavalek/term-work
/docs/databaze_pro_web.sql
UTF-8
8,090
3.15625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Počítač: 127.0.0.1 -- Vytvořeno: Ned 10. pro 2017, 23:17 -- Verze serveru: 10.1.26-MariaDB -- Verze PHP: 7.1.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARAC...
true
169c97426ac36a523016d100be80533d6ebd668c
SQL
Luancyhuang/SQL-Server-2008R2
/SQLQuery3.sql
GB18030
469
2.796875
3
[]
no_license
create database DB1 on primary ( name='f4', filename='C:\Users\huangxinwu\SQL\f4.mdf', size=3mb, maxsize=unlimited, filegrowth=3% ), ( name='f5', filename='C:\Users\huangxinwu\SQL\f5.ndf', size=10mb, maxsize=500mb, filegrowth=3% ) log on ( name='f6', filename='C:\Users\huangxinwu\SQL\f6.ldf', size=1mb, maxsize=unlimite...
true
033050e6e755d0259d07452479c1442425fc77d4
SQL
fabiosoft/Volare-Airline-website
/res/volare.sql
UTF-8
2,401
3.3125
3
[ "MIT" ]
permissive
DROP DATABASE IF EXISTS `volare`; CREATE DATABASE `volare` DEFAULT CHARACTER SET latin1 COLLATE latin1_general_cs; USE `volare`; # # table structure for table 'usr' # DROP TABLE IF EXISTS `usr`; CREATE TABLE `usr` ( `uname` VARCHAR(6) NOT NULL, `upwd` VARCHAR(16) NOT NULL, `umoney` SMALLINT UNSIGNED N...
true
46674a0a4429a6e21fa718f97f4f2554df51e95e
SQL
malums2013/traumacare
/medical.sql
UTF-8
17,561
2.9375
3
[ "CC-BY-3.0" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.1.12 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Oct 14, 2018 at 10:26 AM -- Server version: 5.6.16 -- PHP Version: 5.5.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;...
true
946365386b38f3320d6e368686f0bcc71b41b5ec
SQL
AnetaKopera/OnlineClinicBackend
/onlineClinic.sql
UTF-8
2,537
3.5625
4
[]
no_license
create database OnlineClinic; use OnlineClinic; create table Users ( id int(5) auto_increment primary key, surname varchar(50) not null, name varchar(50) not null, email varchar(50) not null, password varchar(50) not null, accountType varchar(50) not null ); create table Clinics ( id int(5) auto_incremen...
true
a496a3f211931362fc7351b2140cc4f3d5dbb41e
SQL
manecocomph/art
/resource/create_table.sql
UTF-8
437
3.09375
3
[]
no_license
drop table news_info; create table news_info ( id int primary key AUTO_INCREMENT, news_day date not null, news_title varchar(200) ); drop table daily_area_price; create table daily_area_price( id int primary key AUTO_INCREMENT, news_date_id int references news_info(id), provence_id int references promary(proID), pric...
true
9e6a4c8783441d1b69620a5d16d2406954d7c07a
SQL
saraarmiida/php-piscine
/d05/ex18/ex18.sql
UTF-8
143
2.9375
3
[]
no_license
SELECT `name` FROM `distrib` WHERE `id_distrib` BETWEEN 62 AND 69 OR `id_distrib` IN (42,71,88,89,90) OR LOWER(`name`) LIKE '%y%y%' LIMIT 2, 5;
true
7b6a567da7600df701b251fac4eb2d4805b4e451
SQL
TeamFuchsia/BoeteAPI
/BoeteAPI-backend/src/sql/create-boeteapi-it.sql
UTF-8
1,158
3.1875
3
[]
no_license
CREATE DATABASE Boeteapi_IT; /* switch naar database Boeteapi-IT in intelliJ */ CREATE TABLE PERSOON ( persoonNr SERIAL, voornaam VARCHAR(30) NOT NULL, achternaam VARCHAR(30) NOT NULL, straat VARCHAR(25) NOT NULL, huisnummer VARCHAR(10) NOT NULL, postcode VARCHAR(7) ...
true
c4039cc53e9023c4ca359b886b3b0b018d2bbc41
SQL
utcuj/assignment-1-tourism-agency-VictorAlmasan
/db.sql
UTF-8
6,131
4.03125
4
[]
no_license
DROP DATABASE IF EXISTS assignment1; CREATE DATABASE assignment1; USE assignment1; CREATE TABLE IF NOT EXISTS user_types ( user_type_code VARCHAR(1) PRIMARY KEY NOT NULL, user_type_description VARCHAR(20) NOT NULL ); CREATE TABLE IF NOT EXISTS operation_types ( operation_type_code VARCHAR(2) PRIMARY KEY N...
true
5a33cae480d866f785eab0ada83da1fae2e1acd7
SQL
superuser5/cslogwatch
/sql/system.sql
UTF-8
233
2.921875
3
[]
no_license
CREATE TABLE `system` ( `id` integer NOT NULL PRIMARY KEY AUTOINCREMENT, `name` varchar ( 200 ) NOT NULL UNIQUE, `project_id` integer NOT NULL, FOREIGN KEY(`project_id`) REFERENCES `project`(`id`) DEFERRABLE INITIALLY DEFERRED );
true
c7e5ca7a11684e57b531ece754520e871e709eea
SQL
priyakamesh/sqlite3-chinook-queries
/chinook-queries.sql
UTF-8
7,326
4.46875
4
[ "MIT" ]
permissive
/*1.Provide a query showing Customers (just their full names, customer ID and country) who are not in the US.*/ SELECT FirstName||" "|| LastName AS 'Full Name', CustomerId,Country FROM Customer WHERE Country <> "USA" /*2.Provide a query only showing the Customers from Brazil.*/ SELECT * FROM Customer WHERE Country =...
true
6a513b03c327f0c71819d0304a505f0495b6c9af
SQL
zhangdongcq/compactEShop
/src/main/java/dong/compactEShop/MySQL_Stucture/compactEshop.sql
UTF-8
4,051
3.078125
3
[]
no_license
/* Navicat Premium Data Transfer Source Server : MacOSX Source Server Type : MySQL Source Server Version : 80011 Source Host : localhost:3306 Source Schema : compactEshop Target Server Type : MySQL Target Server Version : 80011 File Encoding : 65001 Date: 02/01/2019 ...
true
fd30feaceda8202b0ce4d2f905b810a760dc427d
SQL
MikkelOlsen/slipseknuden
/slipseknuden.sql
UTF-8
16,519
3.109375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.3.11 -- http://www.phpmyadmin.net -- -- Vært: 127.0.0.1 -- Genereringstid: 28. 03 2017 kl. 14:53:23 -- Serverversion: 5.6.24 -- PHP-version: 5.6.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*...
true
1b1ebc04940da117717b221f056329a8e6db61d8
SQL
kavyajeetbora/my_sql_course
/Section 14 - Instagram data clone/schema.sql
UTF-8
2,613
4.15625
4
[]
no_license
DROP DATABASE instagram_clone; CREATE DATABASE instagram_clone; use instagram_clone; CREATE TABLE users( id INT AUTO_INCREMENT PRIMARY KEY, username VARCHAR(255) NOT NULL UNIQUE, date_created TIMESTAMP DEFAULT NOW() ); CREATE TABLE photos( id INT AUTO_INCREMENT PRIMARY KEY, image_url VARCHAR(255) NOT NU...
true
cb6b56cc2fb6c1fc96e6d2fe92c8eec91cdb5668
SQL
alessandrojean/order-by-installer
/bd.sql
UTF-8
20,168
3.3125
3
[ "Apache-2.0" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: 19-Nov-2015 às 14:45 -- Versão do servidor: 5.6.27 -- PHP Version: 5.5.30 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; ...
true
0ea22a35a6604b92d76bbdc030fdc9eb52868f29
SQL
eliasjosevoltolini/crm-consultoria
/Sql/Table/Cliente/Table_Cliente.sql
UTF-8
777
2.609375
3
[]
no_license
CREATE TABLE `cliente` ( `id` int(11) NOT NULL AUTO_INCREMENT, `nome` varchar(60) NOT NULL, `cpf` varchar(30) NOT NULL, `rg` varchar(30) NOT NULL, `data_nascimento` date NOT NULL, `residencial` varchar(20) DEFAULT NULL, `comercial` varchar(20) DEFAULT NULL, `celular` varchar(60) DEFAULT NULL, `recado...
true
34e752314e890fe9891c1291472df55d8c0cf70a
SQL
rickyzhu/sql
/security_time.sql
UTF-8
1,143
2.859375
3
[]
no_license
set line 132 set pagesize 20000 col timestamp for a20 col username for a20 col userhost for a27 col priv_used for a20 col action_name for a20 col returncode for a15 spool audit_time.out select to_char(timestamp, 'DD/MM/YYYY HH24:MI:SS') timestamp, rpad(nvl(username,'N/A'),20,' ') username, ...
true
6a698309da5eafa6c799ef6f87669887105af3e2
SQL
mwalters-workmarket/setting-service-reactive
/src/main/resources/db/migration/V0.0003__add_dimensions.sql
UTF-8
517
3.015625
3
[]
no_license
-- -- Copyright 2019, WorkMarket, Inc. All Rights Reserved. -- USE wm_setting; SET FOREIGN_KEY_CHECKS = 0; TRUNCATE TABLE dimension_type; INSERT INTO dimension_type (id, name) VALUES (0, 'default'), (10, 'base'), (20, 'business'), (30, 'company'), (40, 'department'), (50, 'user'), (60, 'special'), (70, 'override');...
true
d1f891ca68ae00d8334c0cf835ee1b26af511516
SQL
laura-lancie/UniworkTeam-Project-Section
/SQL/tbl_contact.sql
UTF-8
2,010
2.8125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.2.10 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Apr 20, 2019 at 03:29 PM -- Server version: 5.5.58-0+deb7u1-log -- PHP Version: 5.6.31-1~dotdeb+7.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=...
true
2d3b68e8858c6efc6a051531f2363b125c3fad76
SQL
RichDBA/SQLAdmin
/DB_Inventory.sql
UTF-8
432
2.890625
3
[]
no_license
SELECT @@serverNAME AS server_instance Select ServerProperty('ComputerNamePhysicalNetBIOS') AS physical_node SELECT @@VERSION AS 'SQL Server Version' SELECT 'IsClustered', SERVERPROPERTY('IsClustered') SELECT * FROM fn_virtualservernodes() AS nodes SELECT COUNT(*) AS NumberofDatabases FROM master..sysdatab...
true
078780df145cda57f53507e690b7ede83640d618
SQL
2724869229/Ticket-management-System
/Ticketing_Management_System/share/ceshi.sql
UTF-8
1,331
3.5
4
[]
no_license
select e.route_id,e.route_distance from route_cl e join airport_cl a on e.from_airport_id =a.airport_id where e.from_airport_id in (select k.airport_id from airport_cl k join city_cl f on k.city_id = f.city_id where city_name = '北京') and e.to_airport_id in (select i.airport_id from airport_cl i join city_cl o ...
true
f606fa37f0832201ea97a1b93d5fca90f882971d
SQL
LYliuyao/easyconf
/demo.sql
GB18030
54,823
2.96875
3
[]
no_license
drop table if exists province; create table province ( id char(2), name varchar(32), primary key(id) ); drop table if exists city; create table city ( province_id char(2), id char(2), name varchar(32), primary key(province_id, id) ); drop table if exists demo; create table demo ( ip varchar(15), ...
true
7d82cf4379d4e09a1abbdbd4cfb82342abab1613
SQL
jonathanchu/fpo
/website/schema.sql
UTF-8
415
2.515625
3
[ "MIT" ]
permissive
DROP TABLE if EXISTS user; CREATE TABLE user ( user_id integer PRIMARY KEY autoincrement, username string NOT NULL, email string NOT NULL, pw_hash string NOT NULL ); DROP TABLE if EXISTS group; CREATE TABLE group ( group_id integer PRIMARY KEY autoincrement, image_Id integer, ); DROP TABLE if EXISTS image...
true
c92b9f243f745120c852622659b08ab89aba608e
SQL
radtek/abs3
/sql/mmfo/bars/ForeignKey/meta_regentry.sql
UTF-8
980
2.734375
3
[]
no_license
PROMPT ===================================================================================== PROMPT *** Run *** ========== Scripts /Sql/Bars/ForeignKey/META_REGENTRY.sql =========*** Ru PROMPT ===================================================================================== PROMPT *** Create constrain...
true
809d97fcbeb7adc6d5be3d5a3fa8b32e19ac1f72
SQL
gitdodo/Contacts-Import-SQL
/regions emailepiq.sql
UTF-8
435
3.3125
3
[]
no_license
select * From region ALTER table region add FCRMethod varchar(5) ALTER table region drop column FCRMethod create table region_continent (regionid varchar(2), continent varchar(2)) select * From region join region_continent on ID = regionid update r set r.FCRMethod = 'EMAIL' from Region as r inner join region_con...
true
56d7c055282dd26930b8ea4ec19de9d269575369
SQL
Popitalk/popitalk-server-api
/src/queries/addMembers.sql
UTF-8
269
2.734375
3
[]
no_license
INSERT INTO members ( channel_id, user_id, admin ) SELECT $1 AS "channel_id", mem.id AS "user_id", $3 AS admin FROM unnest($2::UUID[]) AS mem(id) RETURNING channel_id AS "channelId", user_id AS "userId", admin, created_at AS "createdAt"
true
00c54793f55bf301bdf7b36982a3d4d0118c9db1
SQL
carmenbonciog/springbatch-example
/src/main/resources/sample-all.sql
UTF-8
996
2.921875
3
[]
no_license
DROP TABLE BookingExtract IF EXISTS; CREATE TABLE BookingExtract ( id int(11) AUTO_INCREMENT, street varchar(150), city varchar(100), zip int(10), state varchar(10), beds int(10), baths int(10), sqft int(10), accomodationType varchar(10), holidayDate date, price dec(10,2), latitude dec(9,6), longitude d...
true
500ad0e2f0d2ec3551c9b484eb8f1b2a6437a1ca
SQL
devin-sh-kim/social-integration
/src/main/resources/schema.sql
UTF-8
770
3.5
4
[]
no_license
CREATE SEQUENCE SEQ; CREATE TABLE user ( id bigint NOT NULL, email varchar(320) NOT NULL, password varchar(2000), name varchar(200) NOT NULL, gender varchar(1), age varchar(2), mobile varchar(20), created_at timestamp, created_by bigint, updated_at timestamp, updated_by bigi...
true
4443c36e0b1d869dfa7bcd33bc9b751db7844477
SQL
magotts/midtermproject
/db/schema/food_table.sql
UTF-8
1,223
3.953125
4
[]
no_license
DROP TABLE IF EXISTS users CASCADE; DROP TABLE IF EXISTS orders CASCADE; DROP TABLE IF EXISTS foods CASCADE; DROP TABLE IF EXISTS order_details CASCADE; DROP TYPE IF EXISTS ord_status CASCADE; CREATE TYPE ord_status AS ENUM ('new', 'accepted', 'declined', 'completed'); CREATE TABLE users ( id SERIAL PRIMARY KEY NOT...
true
a77b4d986fda58abadd02628e590bc22bf4609f8
SQL
synchrophasotron28/DB_ERwin_MSSQL
/Семестр 1/к заданию 5 выбор данных/SQLQuery14.sql
WINDOWS-1251
301
3.296875
3
[]
no_license
SELECT ._, ._, . FROM 1 AS INNER JOIN 1 AS ON ._ = ._ AND . = .
true
62b27b783d3abe9755f5e335c08cbd51beb16392
SQL
sebasalazar/juank
/SQL/modelo.sql
UTF-8
1,459
3.796875
4
[]
no_license
START TRANSACTION WITH CONSISTENT SNAPSHOT; DROP TABLE IF EXISTS personas CASCADE; DROP TABLE IF EXISTS comunas CASCADE; DROP TABLE IF EXISTS provincias CASCADE; DROP TABLE IF EXISTS regiones CASCADE; -- -- Name: regiones -- CREATE TABLE regiones ( id int NOT NULL AUTO_INCREMENT, nombre varchar(255) NOT NULL...
true
6a459947486b200154389e6f853c9cc7993ea1f9
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day19/select1519.sql
UTF-8
177
2.625
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-18T15:19:00Z' AND timestamp<'2017-11-19T15:19:00Z' AND temperature>=9 AND temperature<=35
true
5c8529d6f93ae0aa85133bc1e541389e7f7bdb7a
SQL
4iwi33/Traning
/SQL/forTable/INSERT.sql
UTF-8
1,872
3.453125
3
[]
no_license
--Оператор "INSERT" вставляет новые строки в существующую таблицу INSERT INTO test (name, bio, birth, email) --VALUES (значение) VALUES('Alex', 'Programmer', '2050-04-04', 'test@mail.ru'); --Сдесь задали значение каждому столбцу --добавим не все данные INSERT INTO test (id, name, email) VALUES('3', 'Gosha...
true
f39bd0d83b11f96e8c852bc5eb374451a18b266d
SQL
BSwaND/maya.u.org.ua
/administrator/components/com_osproperty/sql/csv.osproperty.sql
UTF-8
1,769
2.703125
3
[]
no_license
CREATE TABLE IF NOT EXISTS `#__osrs_csv_forms` ( `id` int(11) NOT NULL AUTO_INCREMENT, `form_name` varchar(255) DEFAULT NULL, `max_file_size` decimal(3,1) NOT NULL, `created_on` datetime DEFAULT NULL, `last_import` datetime DEFAULT NULL, `yes_value` varchar(50) NOT NULL, `no_value` varchar(50) NOT NULL, ...
true
34acd3c79e6294fb49b942718b5e943a6b5de851
SQL
Ammad-cloud/XP
/src/main/resources/sql/xp_db_script.sql
UTF-8
5,436
3.484375
3
[]
no_license
DROP DATABASE IF EXISTS `xp-adventure-group-one` ; CREATE DATABASE `xp-adventure-group-one` DEFAULT CHARACTER SET utf8 ; USE `xp-adventure-group-one` ; DROP TABLE IF EXISTS Activity; create table Activity ( id int auto_increment, name varchar(40) not null, description varchar(255) not null, ageLimit int not null, ...
true
a5fdfda5c784bd83617ee0273d3c32e7b67bae28
SQL
tanyta78/MSSQL-DatabaseBasic
/exam190217Bakery/Bakery/Bakery/09NegativeFeedback.sql
UTF-8
184
3.5
4
[]
no_license
SELECT F.ProductId, F.Rate, F.Description, F.CustomerId, C.Age, C.Gender FROM Feedbacks AS F JOIN Customers AS C ON C.Id=F.CustomerId WHERE F.Rate<5.0 ORDER BY F.ProductId DESC,F.Rate
true
e081c44d2018c62d96eb5a424247c264a53c3389
SQL
gauravkdeshmukh/WeTrade
/build/classes/wetrade/21.sql
UTF-8
455
3.3125
3
[]
no_license
create or replace view v21 as (select ITEM_NO_REVITEM, ITEM_EMAIL_REVITEM, AVG(RATING) AS Avg_Rating from CLASSCUST_REVIEW_ITEM GROUP BY ITEM_NO_REVITEM, ITEM_EMAIL_REVITEM); create or replace view v21a as select ITEM_NO_REVITEM, ITEM_EMAIL_REVITEM from v21 where Avg_Rating in (select MIN(Avg_Rating) from v21); selec...
true
0683af3d9a76194cff434d5377a5c9e62e9ce8b5
SQL
AntonioJuniorD3v/simpei
/BD/simpei_ordem_servico.sql
UTF-8
3,075
2.625
3
[]
no_license
-- MariaDB dump 10.17 Distrib 10.4.8-MariaDB, for Win64 (AMD64) -- -- Host: localhost Database: simpei -- ------------------------------------------------------ -- Server version 10.4.8-MariaDB /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET...
true
7351656ebad83b413380c5a56e62f2e7d5c89bea
SQL
zgdkik/aili
/ows/ows-common/src/main/resources/sql/CREATE.sql
UTF-8
1,076
2.90625
3
[]
no_license
--短信模板 create table T_SMS_TEMPLATE ( id NUMBER(20) PRIMARY KEY, SMS_CODE VARCHAR2(50), SMS_NAME VARCHAR2(50), sms_content VARCHAR2(600), sms_params VARCHAR2(300), sms_type VARCHAR2(2), service_type_CODE VARCHAR2(2), sms_mode ...
true
64db2216fc21b8bf9a700db245db1083f60d42de
SQL
code-and-code/controle_equipamentos
/equipamentos_modelo.sql
UTF-8
15,248
3.328125
3
[]
no_license
# ************************************************************ # Sequel Pro SQL dump # Version 4096 # # http://www.sequelpro.com/ # http://code.google.com/p/sequel-pro/ # # Host: 127.0.0.1 (MySQL 5.7.16) # Database: equipamento # Generation Time: 2017-07-21 17:35:12 +0000 # *********************************************...
true
301920de2043aac902683ee96a2b3796cc6e7727
SQL
chu3sao/SQL
/zszq_SQL/嘉扬/03 人事管理/10 部门/OA_Employee_Info.sql
UTF-8
639
3.53125
4
[]
no_license
select a.Name as 姓名,b.Title as 公司,c.DepAbbr as 一级部门,d.DepAbbr as 二级部门,e.DepAbbr as 三级部门,f.JobAbbr as 岗位,g.CertNo as 身份证编号,f.xorder as 排序 from zszq.dbo.eEmployee as a inner join zszq.dbo.oCompany as b on a.CompID=b.CompID left join zszq.dbo.oDepartment as c on zszq.dbo.eFN_getdepid1st(a.DepID)=c.DepID left join zszq.dbo...
true
af858a6e18c2e0cdb37b48f61d39847d7278cf83
SQL
damianborycki/pmsystem
/db/schema_update.sql
UTF-8
2,412
3.515625
4
[]
no_license
# modyfikacja obecnej tabeli Field ALTER TABLE `FIELD` DROP FOREIGN KEY `FK_FIELD_FIELDFORMAT`, DROP FOREIGN KEY `FK_FIELD_FIELDCONTEXT`; ALTER TABLE `FIELD` DROP COLUMN `FIELDFORMATID`, DROP COLUMN `FIELDCONTEXTID`, ADD COLUMN `MINVALUE` INT UNSIGNED NULL DEFAULT NULL AFTER `ID`, ADD COLUMN `MAXVALUE` INT UNSIGNED N...
true
cab339aaee12941ed17df36ca0e87bb657292876
SQL
java-akademie/_javaStuff
/sql/sql/a45.sql
UTF-8
801
3.484375
3
[]
no_license
select 'a45.sql (ON DELETE/ON UPDATE)' as uebung; drop table person; drop table adresse; create table adresse ( id int primary key, ort varchar(20) ); create table person ( id int primary key, name varchar(20), adressId int, CONSTRAINT fk_adresse FOREIGN KEY (adressId) REFERENCES adresse(id) ...
true
8b68a188c58dc2e341a60f58a96c372dfcbb13dd
SQL
cankunli/SQL
/Assignment Two.sql
IBM852
6,588
4.40625
4
[]
no_license
--Answer following questions --1. What is a result set? --output of a query --2. What is the difference between Union and Union All? --Union combines the result set from multiple tables and returns distinct records into a single result set. --Union all combines the result set from multiple tables and returns all...
true
8524a557ca1f11a75b75e34ed4bd4b20a3c429e0
SQL
zrino/DWA
/seminar2/seminar2.sql
UTF-8
8,104
3.15625
3
[]
no_license
/* SQLyog Ultimate v12.09 (64 bit) MySQL - 5.7.8-rc : Database - Seminar2 ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHE...
true
53aee3b96a2a15a98af3f7df4feb8685081e8ada
SQL
MagdaSzade/mysql
/Zadanie 22.5.sql
UTF-8
779
3.65625
4
[]
no_license
CREATE TABLE STATS ( STAT_ID INT(11) NOT NULL AUTO_INCREMENT, STAT_DATE DATETIME NOT NULL, STAT VARCHAR(20) NOT NULL, VALUE INT(11) NOT NULL, PRIMARY KEY (STAT_ID) ); CREATE VIEW BESTSELLERS_COUNT AS SELECT COUNT(*) AS BESTSELLERS_COUNTER FROM books WHERE BESTSELERS = 1; DELIMITER $$ C...
true
77385619f0fe2494edac283befc2965d4eee03f0
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day22/select0032.sql
UTF-8
178
2.671875
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-21T00:32:00Z' AND timestamp<'2017-11-22T00:32:00Z' AND temperature>=44 AND temperature<=94
true
8119990e9cf4fa07e132e8a31a6b89fe655aa710
SQL
mashaod/books_shop
/books-shop.sql
UTF-8
13,374
3.53125
4
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.3 -- https://www.phpmyadmin.net/ -- -- Хост: 127.0.0.1:3306 -- Время создания: Окт 18 2017 г., 12:53 -- Версия сервера: 5.6.37 -- Версия PHP: 5.5.38 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACT...
true
974a38ccb92f008f0ddfa6a82c0e3d5acb11d33a
SQL
john0xff/SQL
/relationsExercise/companyOffices/queries.sql
UTF-8
2,867
3.59375
4
[]
no_license
SELECT `company`.`name` AS `CompanyName`, `office`.`city`, `office`.`zipCode`, `office`.`street` FROM `companyoffices` INNER JOIN `company` ON `companyoffices`.`companyID` = `company`.`companyID` INNER JOIN `office` ON `companyoffices`.`officeID` = `office`.`officeID` /*-------------GROUP BY works like the DIST...
true
08720d58ce781435c5f46df522f1de3d2612f3be
SQL
nimishbhandari/snowden-lite
/snowden .sql
UTF-8
4,062
3.171875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Sep 12, 2020 at 11:34 AM -- Server version: 10.4.13-MariaDB -- PHP Version: 7.4.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIEN...
true
ce11b7a5bae3301077f460786ed8eea5ecb03bad
SQL
CristianPalmaAste/BT5_web
/modelo_base/scripts/p.sql
UTF-8
3,542
3.3125
3
[]
no_license
delete from empresas where id in (998, 999) ; insert into empresas (id -- numeric(20,0) not null ,idgrem -- numeric(20,0) not null ,idpais -- numeric(20,0) not null ,idesre ...
true
37742505c49eb71d868ab4b062b2a665e7ed2fe7
SQL
github-ek/e-connect-data
/ttcwmsprd/dbo/Views/inv_snap_rimlin_rcvlin_view.sql
UTF-8
1,604
2.984375
3
[]
no_license
create view dbo.inv_snap_rimlin_rcvlin_view as select rm.wh_id wh_id, rm.prtnum prtnum, rm.prt_client_id prt_client_id, sum(rm.expqty) rimlin_expqty, sum(rm.idnqty) rimlin_idnqty, 0 rcvlin_rcvqty from rimlin rm group by rm.wh_i...
true
814eda104ca46acb7b65431615bc2519cfe43b93
SQL
2017398956/StockHelper
/src/user.sql
UTF-8
840
2.75
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : localhost_3306 Source Server Version : 50520 Source Host : localhost:3306 Source Database : mybatis Target Server Type : MYSQL Target Server Version : 50520 File Encoding : 65001 Date: 2017-09-21 23:57:46 */ SET FOREIGN_KEY_CHECKS=0; ...
true
9945547e4a3c915955529bd29d5096d41d49b3e7
SQL
ratnaabrol/nd004_LogsAnalysis
/sql/mostPopularThreeArticles.sql
UTF-8
310
3.484375
3
[]
no_license
-- NOTE: accessed_articles_ext view must be created *before* this query can be run. select articles.title, count(aae.derived_slug) as access_count from accessed_articles_ext aae right join articles on aae.article = articles.id group by aae.article, articles.title order by access_count desc limit 3;
true
5df1fcf7e67b2ffa1f48d1e2b4d19b1c59965351
SQL
Will-McCarthy/Bookmarque
/sql/project_card.sql
UTF-8
2,712
2.859375
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.23, for macos10.15 (x86_64) -- -- Host: localhost Database: project -- ------------------------------------------------------ -- Server version 8.0.23 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */...
true
53869ac97324d624631c77231b85ca1a6a40fe9b
SQL
evidencebp/e2ese
/src/queries/python/prepare_source_extraction.sql
UTF-8
934
3.546875
4
[]
no_license
# Python/prepare_source_extraction.sql drop view if exists general.relevant_content; create view general.relevant_content as select * from # Note - set proper content version general.contents_1_december_2022 ; drop table if exists general.relevant_repos; create table general.relevant_repos as select repo_name fro...
true
b3d45ef95ef4ed9eb543b27ab90fd2ce6b6ec22c
SQL
AnushaAnagani/DB-scripts
/direct_sales.sql
UTF-8
910
3.71875
4
[]
no_license
/*************** NAME: ANUSHA ANAGANI DATE:02/20/2020 *************/ /************************* QUERY TO GET THE TOTAL MONTHLY DIRECT SALES *********************/ /***********************************************************************************...
true
bbe52cb3b72d8727a152c4104d915b09dae254f6
SQL
aczeszejko-sochacki/DB-lecture
/Lista_1/1.sql
UTF-8
634
3.625
4
[]
no_license
SELECT DISTINCT uzytkownik.kod_uz, imie, nazwisko FROM uzytkownik JOIN wybor w1 ON(uzytkownik.kod_uz = w1.kod_uz) JOIN grupa g1 ON(g1.kod_grupy = w1.kod_grupy) JOIN przedmiot_semestr ps1 ON(ps1.kod_przed_sem = g1.kod_przed_sem) JOIN przedmiot p1 ON(p1.kod_przed = ps1.kod_przed) JOIN wybor w2 ON(uzytkownik.kod_uz =...
true
65cd3383e7a7fcf1e2625b2d6314faf8dd7aada5
SQL
Hyidol/u-learning
/文档/生产发布/1.0.0/新增表结构/u_log_history.sql
UTF-8
1,307
3.296875
3
[]
no_license
DROP TABLE IF EXISTS `u_log_history`; CREATE TABLE `u_log_history` ( `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '历史日志ID', `log_history_date` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '历史日志日期', `log_history_name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NU...
true
78f52ba84c06f25720322578427692641fadf6b5
SQL
lllauma/heterogeneous-data-integration
/db structure/create_table_structure.sql
UTF-8
10,808
3.09375
3
[]
no_license
CREATE TABLE author ( au_id NUMBER(10) NOT NULL, au_username VARCHAR2(100) NOT NULL, au_user_id NUMBER(10) ); ALTER TABLE author ADD CONSTRAINT author_pk PRIMARY KEY ( au_id ); CREATE TABLE change ( ch_id NUMBER(10) NOT NULL, ch_changetype_id VARCHAR2(10) N...
true