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
1e0b3d2f2fe9394a13cda91e040862357df5c6d4
SQL
dariansk/my_music_db
/select_music_db.sql
UTF-8
1,476
3.28125
3
[]
no_license
--Задание 2 -- --Написать SELECT-запросы, которые выведут информацию согласно инструкциям ниже. --Внимание! Результаты запросов не должны быть пустыми (учтите при заполнении таблиц). -- --название и год выхода альбомов, вышедших в 2018 году; --название и продолжительность самого длительного трека; --название треков, пр...
true
cff3f3a211d8937177a0115959a6b99062c70dd2
SQL
radtek/abs3
/sql/mmfo/bars/Table/tmp_adm_resource_act_back_2402.sql
UTF-8
5,626
3.1875
3
[]
no_license
PROMPT ===================================================================================== PROMPT *** Run *** ========== Scripts /Sql/BARS/Table/TMP_ADM_RESOURCE_ACT_BACK_2402.sql === PROMPT ===================================================================================== PROMPT *** ALTER_POLICY_INFO...
true
4f0daccfef219b47a8483855b32f8f50a681781d
SQL
dtseiler/sql
/postgresql/total_table_size.sql
UTF-8
604
3.984375
4
[]
no_license
-- From https://wiki.postgresql.org/wiki/Disk_Usage -- This version of the query uses pg_total_relation_size, which sums total disk space used by -- the table including indexes and toasted data rather than breaking out the individual pieces: SELECT nspname || '.' || relname AS "relation", pg_size_pretty(pg_total_r...
true
d2f046d5b6ccc3073e067c39eb99014f0563edda
SQL
hitcsxmli/timematch
/timematching.sql
UTF-8
10,377
2.921875
3
[ "Apache-2.0" ]
permissive
/* Navicat MySQL Data Transfer Source Server : localhost_3306 Source Server Version : 50611 Source Host : localhost:3306 Source Database : timematching Target Server Type : MYSQL Target Server Version : 50611 File Encoding : 65001 Date: 2016-01-20 20:12:52 */ SET FOREIGN_KEY_CHECK...
true
913a920b1d2446bde4a4c6b4b73fae2f8fb696c8
SQL
msotiroff/Softuni-learning
/C# DB Module/DB Basics PL-SQL/ExamPreparations/Exam - 19 February 2017/Exam - 19 February 2017/Exam - 19 February 2017/15. Country Representative.sql
UTF-8
482
4.5625
5
[ "MIT" ]
permissive
WITH CTE_RankingByCountry AS (SELECT c.Name AS CountryName, d.Name AS DistributorName, COUNT(i.Id) AS IngredientsCount, DENSE_RANK() OVER (PARTITION BY c.Name ORDER BY COUNT(i.Id) DESC) AS DistrRank FROM Countries AS c JOIN Distributors AS d ON d.CountryId = c.Id JOIN Ingredients AS i ON i.Distributor...
true
649d4404c1a3b54640e2898d8db58c0fe8ef12db
SQL
zacharyhu/personal_work_scripts
/ngx_lua/云币/gp_pay_currency.sql
UTF-8
2,530
3.28125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.5.2.2 -- http://www.phpmyadmin.net -- -- 主机: localhost:3306 -- 生成日期: 2013 年 08 月 09 日 16:11 -- 服务器版本: 5.5.27-log -- PHP 版本: 5.4.7 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHA...
true
ada342b390700987acf3d7f048dd2d96e6eae906
SQL
arnolgarcia/ETLPrismas
/MetodosSQL/Alarmas/Tablas Existentes Utilizadas/TABLE poligono.sql
UTF-8
498
3.828125
4
[]
no_license
-- Table: poligono -- DROP TABLE poligono; CREATE TABLE poligono ( id bigint NOT NULL, nombre character varying, zona_id bigint, CONSTRAINT poligono_pkey PRIMARY KEY (id), CONSTRAINT zona_fkey FOREIGN KEY (zona_id) REFERENCES zona (id) MATCH SIMPLE ON UPDATE CASCADE ON DELETE CASCADE ) WITH ( ...
true
4ad1fb8fc901a51260848ce65a839154ef6b422f
SQL
CeON/dataverse
/dataverse-persistence/src/main/resources/db/migration/V11__addedMissingTablesForTABFiles.sql
UTF-8
2,471
3.5
4
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
create table variablemetadata ( id serial not null, interviewinstruction text, isweightvar boolean, label text, literalquestion text, notes text, universe varchar(255), weighted boolean, datavariabl...
true
2d55ebb0bf5321ad11176a85dac22f8a9a2c64f3
SQL
GabrielsNN-98/Atividades-Senai
/Sistema IANES/database/Script.sql
WINDOWS-1250
3,522
3.90625
4
[]
no_license
CREATE DATABASE Ianes; USE Ianes; CREATE TABLE funcionario( id INT NOT NULL IDENTITY(1,1) PRIMARY KEY, nome VARCHAR(100) NOT NULL, cpf VARCHAR(11) NOT NULL UNIQUE, email VARCHAR(100) NOT NULL, telefone VARCHAR(11) NOT NULL, tipo VARCHAR(30) NOT NULL, login VARCHAR(10) NOT NU...
true
124854f863c6396be1624987be8489b9791ed008
SQL
dengqi7/spring-boots-learning-example
/spring-boots-mybatis-extra/src/main/resources/sql脚本练习/partitition/range.sql
UTF-8
763
3.65625
4
[]
no_license
CREATE TABLE `sales` ( `money` int(10) unsigned NOT NULL, `date` datetime DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci PARTITION BY RANGE (YEAR(date))( PARTITION p2008 VALUES LESS THAN (2009), PARTITION p2009 VALUES LESS THAN (2010), PARTITION p2010 VALUES LESS THAN (2011) ); insert i...
true
10cee2af64a73f7095ed091cb04218bb95324786
SQL
luckylijg/HDPolice
/workspace/hd/hddc2013/doc/police20130329.sql
UTF-8
13,732
3.609375
4
[]
no_license
-- 创建用户并为所有的远程用户授权 root/ -- create user police identified by 'police'; -- grant insert,delete,update,select,create,drop,alter on *.* to 'police'@'%' identified by 'police'; -- flush privileges; drop database if exists police; create database police character set utf8; use police; -- show variables like 'char...
true
cbaeb83aa62f003abf18350117ba9526ddd60305
SQL
jkcso/SQL-Tutorial
/L9_subqueries.sql
UTF-8
3,897
4.53125
5
[ "MIT" ]
permissive
# LESSON 9. # Please DO try the following queries yourselves but most importantly try different variations and always ask yourself: "Why am I getting this back?". # SUBQUERIES # One of the most powerful features of SELECT is that they can be used as subqueries in expressions by enclosing them in parentheses i.e. (subq...
true
65621272afe4a551979b23d1256b4670114ac176
SQL
HyoilBae/TSQL
/Lab Module13_Ex_1.sql
UTF-8
793
3.90625
4
[]
no_license
SELECT orderid, orderdate, val, ROW_NUMBER() OVER (ORDER BY orderdate) AS rowno FROM Sales.OrderValues SELECT orderid, orderdate, val, ROW_NUMBER() OVER (ORDER BY orderdate) AS rowno, RANK() OVER (ORDER BY orderdate) AS rankno FROM Sales.OrderValues; SELECT orderid, orderdate, custid, val, RANK() OVER (PARTITION BY c...
true
8ca2a2b6000c7349dd7090f25c076b7fc0975071
SQL
mika-koivusaari/mqtt_db_gateway
/db.sql
UTF-8
1,185
3.328125
3
[ "MIT" ]
permissive
CREATE TABLE `data` ( `sensorid` bigint(20) unsigned NOT NULL, `time` datetime NOT NULL, `value` decimal(15,5) NOT NULL, KEY `sensordata` (`sensorid`,`time`), KEY `data_timeid` (`time`,`sensorid`), KEY `sensordata2` (`sensorid`,`time`,`value`), ) ENGINE=InnoDB DEFAULT CHARSET=latin1; CREATE TABLE `datatext...
true
919eaba805a5e1b743c56b782be6e2952d4620e0
SQL
theotheruser2/dbcourse
/sql/bd3insertalt.sql
UTF-8
2,881
3.078125
3
[]
no_license
INSERT INTO LOCATION(LOC_NAME, POPULATION) VALUES('Hole', 20000), ('Mage Realm', 100000), ('Hell', 1000000); SELECT count_residents(1); SELECT count_residents(2); SELECT count_residents(3); INSERT INTO DRUG(NAME, DESCRIPTION, POWER_MULT, SIDE_EFFECT_CHANCE, COST) VALUES('Black Powder', 'Effective but known fo...
true
c489957e1c30bc0ea6aa6bac30aae59ac4488cb9
SQL
kylefinter/old_programs
/CSC335/HW3/q2.sql
UTF-8
1,552
2.65625
3
[]
no_license
REM Kyle Finter REM Trace: Finter179 insert into employee values('Kyle Finter','Harrison','Springfield'); insert into employee values('Jamil Saquer','Rock','Springfield'); insert into employee values('Noah Baird','Holland','Raymore'); insert into employee values('Miranda Wade','Elm','Springfield'); insert into employe...
true
ba09ae9ea4c43b1db70cb6e4f9e92dd86923e9be
SQL
gandhiabhishek7007/Stage1
/SQL Programming/Mandatory Hands-on/885123/Student and their Department Based on City/joins3.sql
UTF-8
180
3.65625
4
[]
no_license
select Student.student_name,Department.department_name from Department JOIN Student ON Department.department_id=Student.department_id where city='Coimbatore' ORDER BY student_name;
true
2172caaa0850bc65d629a14d79249296313fabbe
SQL
testhklee/test
/Soup/target/classes/dbFile/soupMember.sql
UTF-8
3,764
3.875
4
[]
no_license
/* 스터디 / 프로젝트 멤버 */ DROP TABLE SOUP_MEMBER PURGE; /* 스터디 / 프로젝트 멤버 */ CREATE TABLE SOUP_MEMBER ( SOUP_NO NUMBER, /* 스터디 / 프로젝트 번호 */ MEMBER_NO NUMBER NOT NULL, /* 회원 번호 */ SOUP_MEMBER_GUBUN VARCHAR2(10) NOT NULL, /* 역할 구분 (리더 : L, 팀원 : M */ SOUP_MEMBER_STATUS VARCHAR2(30) NOT NULL, /* 상태 (소속 : BELONG, 나감 :...
true
c55ac6d80a773a8295c5158cb249866b3e101f28
SQL
wsx180808/yaoqishan
/database.sql
UTF-8
24,173
2.875
3
[ "Apache-2.0" ]
permissive
/* Navicat Premium Data Transfer Source Server : 本地 Source Server Type : MySQL Source Server Version : 50638 Source Host : localhost:3306 Source Schema : sq_173cms Target Server Type : MySQL Target Server Version : 50638 File Encoding : 65001 Date: 31/08/2018 10:5...
true
b38bb27475d61d2ab4ff1508238c0456ae39c61d
SQL
zaylinhtike17/test
/crud.sql
UTF-8
2,825
3.1875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 09, 2020 at 11:08 AM -- Server version: 10.4.11-MariaDB -- PHP Version: 7.3.18 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
73f0b4082f39be7c7cf11ba9bbe14514146be619
SQL
tak7iji/todo
/with-db-auth/src/main/resources/sql/create.sql
UTF-8
271
2.515625
3
[]
no_license
create table if not exists todo(todo_id varchar(36) primary key, todo_title varchar(30), finished boolean, created_at timestamp); CREATE TABLE if not exists operation_date(diff bigint NOT NULL); DELETE FROM operation_date; INSERT INTO operation_date(diff) VALUES (1440);
true
20ff3d6bbd54a71e66f9ca542490abef0e112d77
SQL
HTTPArchive/almanac.httparchive.org
/sql/2019/caching/16_07.sql
UTF-8
983
3.8125
4
[ "Apache-2.0" ]
permissive
#standardSQL # 16_07: Set-Cookie on cacheable responses SELECT client, uses_cookies, SUM(COUNT(0)) OVER (PARTITION BY client) AS all_requests, SUM(COUNT(DISTINCT pageid)) OVER (PARTITION BY client) AS all_pages, type, SUM(COUNT(0)) OVER (PARTITION BY client, type) AS total_of_type, COUNT(0) AS total, C...
true
dc5cd8c71639edd26f036d31fd021bae1b6a0687
SQL
gxlioper/ecology
/data/Oracle/sql201501230601.sql
GB18030
184,641
2.765625
3
[]
no_license
delete from HtmlLabelIndex where id=81939 / delete from HtmlLabelInfo where indexid=81939 / INSERT INTO HtmlLabelIndex values(81939,'browseridΪգ') / INSERT INTO HtmlLabelInfo VALUES(81939,'browseridΪգ',7) / INSERT INTO HtmlLabelInfo VALUES(81939,'browser frame id can not be empty!',8) / INSERT INTO HtmlLabelInfo V...
true
9d5d5d5e64119a07b46d1ca8d814c47b374d4161
SQL
rianmfir/bwastartup
/db.sql
UTF-8
2,202
3.484375
3
[]
no_license
CREATE DATABASE db_bwastartup; CREATE USER `falcon`@`localhost` IDENTIFIED BY '1234567890'; USE db_bwastartup; GRANT ALL PRIVILEGES ON db_bwastartup.* TO `falcon`@`localhost`; FLUSH PRIVILEGES; CREATE TABLE `users` ( `id` INT AUTO_INCREMENT NOT NULL PRIMARY KEY, `name` VARCHAR(255) NOT NULL, `occupation` V...
true
91ecaf5f6fa03da5ea7479d1bfc1bb5f03c21b37
SQL
SonimaOrg/data-analyst
/olap_sale_reports.sql
UTF-8
1,144
4
4
[]
no_license
-- 1. Get total sales by product category -- --------------------------------------- select p.product_type ,sum(f.price) from dim_product p ,fact_sale f where p.product_id = f.product_id group by p.product_type; -- 2. Get total sales of all food product category -- ---------------------------------------...
true
17ca01657f440c47bdd598f20346c59aacdf8339
SQL
krsmll/kn-order-management-system-api
/src/main/resources/db/changelog/changes/app_init.sql
UTF-8
1,131
3.78125
4
[]
no_license
CREATE TABLE "customer" ( id BIGSERIAL PRIMARY KEY, full_name VARCHAR(128) NOT NULL, email VARCHAR(128) NOT NULL, telephone VARCHAR(32) NOT NULL, registration_code VARCHAR(64) NOT NULL ); CREATE TABLE "customer_order" ( id BIGSERIAL PRIM...
true
fd021a3614e0f2d731934ccb9e4ef05d43d3b552
SQL
ondicho/OrganisationalNewsPortal
/src/main/resources/db/create.sql
UTF-8
637
2.859375
3
[]
no_license
SET MODE PostgreSQL; CREATE DATABASE organisational_news_portal; \c organisational_news_portal; CREATE TABLE IF NOT EXISTS departments ( id SERIAL PRIMARY KEY, departmentName VARCHAR, departmentDescription VARCHAR ); CREATE TABLE IF NOT EXISTS users ( id SERIAL PRIMARY KEY, userName VARCHAR, userPosit...
true
228cefd046f12d6b58da82cdc9ce75fdb754f844
SQL
JSON033/CSE-111
/Jason-Feng-lab6/10.sql
UTF-8
304
3.390625
3
[]
no_license
select r_name from region, supplier, nation, customer, lineitem, orders where c_nationkey = s_nationkey and s_nationkey = n_nationkey and n_regionkey = r_regionkey and s_suppkey = l_suppkey and c_custkey = o_custkey and l_orderkey = o_orderkey group by r_name order by sum(l_extendedprice) desc limit 1;
true
94c3b31261fec843525b8d443755ad77f26073fa
SQL
CL17-I04-002/CRUD_Empleados_Empresas
/directenglish/directenglish.sql
UTF-8
661
3.265625
3
[]
no_license
create database if not exists directenglish; use directenglish; create table if not exists empresa( id_empresa int primary key auto_increment, nombre_empresa varchar(50) not null, direccion_empresa varchar(100) not null, telefono_empresa varchar(50) not null )engine=InnoDB; create table if not exists emp...
true
baebb1be55412693fa976e3b3fd288d7fec2cfb4
SQL
ricardocerto16/BD-SQL
/Modelo Físico/transação.sql
UTF-8
553
3.234375
3
[]
no_license
USE `leiExpress` DELIMITER $$ CREATE PROCEDURE inserirLugar ( IN Id_Comb INT, IN Cap INT, IN NrLugar INT, IN Carr INT, IN Tip INT) BEGIN DECLARE Erro BOOL DEFAULT 0; DECLARE CONTINUE HANDLER FOR SQLEXCEPTION SET Erro = 1; START TRANSACTION; INSERT INTO Comboio (Id_Comboio,...
true
84bac8743906ac60278e5aa5e8d2f7f8b5ac3cb2
SQL
evgenytihonov/Study_MySQL
/Topic4/comman_topic4.sql
UTF-8
939
3.578125
4
[]
no_license
SHOW TABLES; SELECT * FROM friendship_statuses LIMIT 10; INSERT INTO friendship_statuses (name) VALUES ('Requested'), ('Confirmed'), ('Rejected'); DELETE FROM friendship_statuses WHERE id BETWEEN 1 AND 3; UPDATE friendship_statuses SET id = id - 3; UPDATE friendship SET friend_id = FLOOR(1 + RAND() * 100...
true
4eb2dbd40830569ddef89c7f8c2f5ac0c92d3473
SQL
Guto2K/Vendas-Repository
/src/main/resources/db/migration/V05__criar_tabela_pedidos_e_carrinhos.sql
UTF-8
1,578
3.375
3
[]
no_license
CREATE TABLE carrinho ( codigo BIGINT(20) PRIMARY KEY AUTO_INCREMENT, valor_total_produtos DECIMAL(10,2) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; ALTER TABLE produto ADD COLUMN codigo_carrinho BIGINT(20) ; ALTER TABLE produto ADD CONSTRAINT FK_carrinho_produto FOREIGN KEY (codigo_carrinho) REFERENCES carrinho(cod...
true
b19b896c392c1d5a2faf1b252935ba7aef66bd40
SQL
flowable/flowable-engine
/modules/flowable-entitylink-service/src/main/resources/org/flowable/entitylink/service/db/create/flowable.db2.create.entitylink.sql
UTF-8
1,036
2.75
3
[ "Apache-2.0" ]
permissive
create table ACT_RU_ENTITYLINK ( ID_ varchar(64) not null, REV_ integer, CREATE_TIME_ timestamp, LINK_TYPE_ varchar(255), SCOPE_ID_ varchar(255), SUB_SCOPE_ID_ varchar(255), SCOPE_TYPE_ varchar(255), SCOPE_DEFINITION_ID_ varchar(255), PARENT_ELEMENT_ID_ varchar(255), REF_SCOPE_ID...
true
aedcb4e61345a41a612f032e00d3f4bbdcbb39c4
SQL
bng5/cms2
/mysql/atributos_tipos.sql
UTF-8
1,489
3.265625
3
[]
no_license
DROP TABLE IF EXISTS `atributos_tipos`; CREATE TABLE `atributos_tipos` ( `id` tinyint(3) unsigned NOT NULL auto_increment, `tipo` enum('string','date','text','int','num') character set ascii NOT NULL default 'string', `subtipo` tinyint(3) unsigned default NULL, `op_listado` tinyint(1) NOT NULL default '0', ...
true
94c57ea1b953dd1ba0708a0480a952aa404bd55c
SQL
mikelitzow/bold-new-pollock
/data/survey data/poll_cpue_by_sex_cm.sql
UTF-8
14,076
3.390625
3
[]
no_license
REM SCRIPT MODIFIED 03/04/2020 NICHOL REM THIS SCRIPT CALCULATES THE BOTH CPUE_NOHA & CPUE_KGHA BY HAUL BY SEX CM-LENGTH FOR ONE SPECIES REM ***NEED TO REPLACE SPECIES_CODE AND SPECIES TEXT NAME (E.G, POLL) IF YOU WANT TO DO A NEW SPECIES*** REM ***NEED TO REPLACE LENGTH-WEIGHT REGRESSION PARAMETER VALUES SPECIFIC T...
true
223add5b5bd4f899c1272a3f084c17b906db4813
SQL
ericgellis/Perfobus-backend
/src/main/resources/sql/create.sql
UTF-8
2,979
3.4375
3
[]
no_license
-- Create sequences -- CREATE SEQUENCE public.mobithink_uid INCREMENT 1 START 1 MINVALUE 1 MAXVALUE 9223372036854775807 CACHE 1; -- drop tables of link -- DROP TABLE IF EXISTS public."line_station_link"; -- drop entities tables -- DROP TABLE IF EXISTS public."bus_line"; DROP TABLE IF EXISTS public...
true
cdf0312930fce5a4c7720d7af7dfb5e61c36ea7a
SQL
Fantasmy/SQL_Scripts
/bluewinds/Revenue2013.sql
ISO-8859-1
305
3.5
4
[]
no_license
-- Calcular la suma del valor de todas las ordenes del ao 2013 select sum(o.TotalAmount) as 'Billing in 2013' from Orders o where year(o.OrderDate) = '2013' --OTRO MTODO: select sum(o.TotalAmount) as 'Billing in 2013' from Orders o where o.OrderDate >= '2013-01-01' AND O.OrderDate < '2014-01-01'
true
072d6b57bad689899dd17b681bf671b8c1428ae3
SQL
erinaldo/diprolim
/Scripts/Procedimientos/sp_entradaProductoDeProduccion.sql
UTF-8
889
2.9375
3
[]
no_license
CREATE PROCEDURE `sp_entradaProductoDeProduccion` (codigoProducto int, dCantidad double) BEGIN DECLARE iCodigoAGranel int DEFAULT 0; DECLARE dValorMedida double DEFAULT 0; DECLARE dCantidadGranel double DEFAULT 0; -- Se obtiene el producto a granel y valor de medida de codigo de producto para saber cu...
true
e42324ce62ad2d3c69f7e93400c10952fa36410d
SQL
Zielzor/BiqQuery
/3rd Wave/Marzec/--- regionalne zestawienie.sql
UTF-8
1,383
3.4375
3
[]
no_license
#Łukasz, mam prośbę... Potrzebuję do całej aktywnej oferty DE dodać #DE #1) cenę zakupu #2) ilość zakupu #3) cenę sprzedaży netto #4) zysk #11:00 #całej aktynwej oferty de ? #o kurwa #Sebastian, 11:00 #5) Marżę ---PL #6) cenę sprzedaży PL netto #7)zysk pl #8) marżę #jeśli jest cena PL to oczywiście znacz...
true
6275477cc3fd0a370a4c8e10b39af2c887c6fe20
SQL
aicasas/Northwind-SQL-Queries-
/Alexis_Casas_MultiTable.sql
UTF-8
1,531
4.4375
4
[]
no_license
-- Query 1: Number of orders for each customer? SELECT customer.CompanyName, Count(orders.OrderID) AS NumOrders FROM orders INNER JOIN customer USING (CustomerID) Group By CompanyName Order By NumOrders DESC; -- Query 2: What were the total sales for each product? SELECT product.ProductName, sum(orderDetail.Quantity* ...
true
6269090ce020e6723d33dcfee53d52ae8d1692c6
SQL
Ulysses-WJL/python_database_test
/sql/exercise/exercise5.sql
UTF-8
533
3.78125
4
[]
no_license
USE myemployees; SELECT job_id, MAX(salary), MIN(salary), AVG(salary), SUM(salary) FROM employees GROUP BY job_id ORDER BY job_id; SELECT MAX(salary) - MIN(salary) DIFFERENCE FROM employees; SELECT MIN(salary), manager_id FROM employees WHERE manager_id IS NOT NULL GROUP BY manager_id ...
true
4c1ae7cc280eb97129ff0dc700eb00c24a006bb9
SQL
anymaniax/cds
/contrib/uservices/badge/migrations/2019-04-09-192144_create_runs/up.sql
UTF-8
323
2.703125
3
[ "BSD-3-Clause" ]
permissive
-- Your SQL goes here CREATE TABLE IF NOT EXISTS "run" ( id BIGSERIAL PRIMARY KEY, run_id BIGINT NOT NULL, num BIGINT NOT NULL, project_key TEXT NOT NULL, workflow_name TEXT NOT NULL, branch TEXT DEFAULT '', status TEXT NOT NULL, updated TIMESTAMP WITH TIME ZONE DEFAULT current_timestamp...
true
fec5c9dc104cc903b02ec4252391b7b27999746e
SQL
Spumersen/Labs
/register-bd.sql
UTF-8
1,675
3.03125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Хост: 127.0.0.1 -- Время создания: Окт 21 2020 г., 17:11 -- Версия сервера: 10.4.14-MariaDB -- Версия PHP: 7.2.33 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@...
true
5a0670b12b6702216d753da12ba95a006d02d056
SQL
StoyanYanev/Database-FMI-2019
/12.SummaryTasks/Ships.sql
UTF-8
1,521
4.125
4
[]
no_license
/*8*/ CREATE VIEW bigger_battles AS SELECT BATTLE FROM OUTCOMES JOIN SHIPS ON SHIP = NAME JOIN CLASSES ON SHIPS.CLASS = CLASSES.CLASS WHERE BATTLE NOT LIKE 'Guadalcanal' GROUP BY BATTLE HAVING COUNT(SHIP) >= ALL(SELECT COUNT(SHIP) FROM OUTCOMES JOIN SHIPS ON SHIP = NAME WHERE BAT...
true
be762ad10f2912329a969fdfce6e227fec6f872d
SQL
myarist/Progate
/Languages/SQL/sql_study_2/page3/exercise2.sql
UTF-8
162
2.765625
3
[ "MIT" ]
permissive
/* dapatkan jumlah total dari kolom price dimana nilai character_name adalah "Ninja Ken" */ SELECT SUM(price) FROM purchases WHERE character_name = "Ninja Ken" ;
true
c89b6efc516c84431163acc3df5b2636431a1227
SQL
dustii94/VGCollection
/inc/games.sql
UTF-8
2,501
3.15625
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.8.1 -- https://www.phpmyadmin.net/ -- -- Host: localhost:3306 -- Generation Time: Jun 18, 2018 at 05:32 PM -- Server version: 5.6.34-log -- PHP Version: 7.2.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
3e5fa7ca12127c8076d53368123d76acd386817f
SQL
AvishekaviD/PRM
/CoreBriefs/257_.sql
UTF-8
1,691
3.609375
4
[]
no_license
select distinct 'IN' as market , 'KKT' as provider , a.best_mobile_number_hash as mobileno , '1' as optin_hierarchy_level , 'Unilever' as optin_hierarchy_value from PRM.kkt_cdr_contest_trans_ST a join PRM.ref_mobile_lookup b on a.region_lookup_number = b.lookup_prefix5 where contest_file_id = 9 and ...
true
3ab8c17fc43c058259b7f1baca2a551539520561
SQL
java-course-ee/java-course-ee
/Security/WebSecurityExample-N03/src/main/resources/script.sql
UTF-8
717
3.125
3
[ "MIT" ]
permissive
create database securityrealm; use securityrealm; create table users ( user_name varchar(15) not null primary key, user_pass varchar(15) not null ); create table user_roles ( user_name varchar(15) not null, role_name varchar(15) not null, primary key(user_name, r...
true
63684aadfef935817d4d7f6a19ac5c3df2535726
SQL
praglis/cinema-club
/rest-service/src/main/resources/db/migration/postgresql/V2020_04_30_15_00_00__CC_124_USER_BADGES.sql
UTF-8
1,470
2.71875
3
[]
no_license
create table USR_BADGE ( BAD_ID int primary key, BAD_NAME varchar(255) not null, BAD_FROM int not null, BAD_TO int not null ); insert into USR_BADGE (BAD_ID, BAD_NAME, BAD_FROM, BAD_TO) values (1,'Alus glutinosa', 0, 10); insert into USR_BADGE (BAD_ID, BAD_NAME, BAD_FROM, BAD_TO) values (2,'Alus incana', 11, 3...
true
4e21d62380535262c344be7926ba8760715ee730
SQL
CharlieDev85/Planilla
/Includes/Beans/sp.sql
UTF-8
1,365
3.484375
3
[]
no_license
delimiter // CREATE PROCEDURE generar_planilla5(IN mes varchar(2), IN my_year varchar(4)) BEGIN DECLARE ultimo_dia DATE; SET ultimo_dia = LAST_DAY(CONCAT(my_year, '-', mes, '-', '30')); SELECT e.empleado_id, e.nombre, e.apellido, e.fecha_inicio_labores, b.bonificacion_num, i.isr_num, (s...
true
0dacdc283a2d0c8c6a9f43bc847d6eda50795ffd
SQL
gurpreet19/ec198392_wht
/Database/configuration/03_02_headless_tool/Delta_WST/SourceViewDefinitions/V_DYNAMIC_TYPES.sql
UTF-8
2,151
3.09375
3
[]
no_license
CREATE OR REPLACE FORCE EDITIONABLE VIEW "V_DYNAMIC_TYPES" ("LABEL", "NAME", "TYPE", "RECORD_STATUS", "CREATED_BY", "CREATED_DATE", "LAST_UPDATED_BY", "LAST_UPDATED_DATE", "REV_NO", "REV_TEXT") AS ( ---------------------------------------------------------------------------------------------------- -- File name:v_dy...
true
b37b82d816a55e002774d6a0d212a32ac3a44025
SQL
NarutoWu11/EECS-495-Database
/P3/f1.sql
UTF-8
232
2.90625
3
[]
no_license
drop procedure if exists ChangeAddress; DELIMITER // CREATE PROCEDURE ChangeAddress(in student_ID INT, in new_Address CHAR(50)) BEGIN update student set Address = new_Address where Id = student_ID; END // DELIMITER ;
true
983182f0828a6f643452ded6719706450dd91ddf
SQL
Tomasho1/EsportsDb
/Base.sql
UTF-8
1,542
3.578125
4
[]
no_license
-- Created by Vertabelo (http://vertabelo.com) -- Last modification date: 2021-02-08 18:35:01.395 -- tables -- Table: Person CREATE TABLE Person ( idPerson int NOT NULL IDENTITY(1, 1), nickname nvarchar(30) NOT NULL, firstName nvarchar(30) NOT NULL, lastName nvarchar(30) NOT NULL, country nvarc...
true
ff71a0454c4f978432190fc0862d79c3d87a4d2b
SQL
babamba/sql
/날짜포맷.sql
UHC
405
2.578125
3
[]
no_license
-- date -> ڿ select employee_id, hire_date from EMPLOYEES; select employee_id, to_char(hire_date,'YYYY""MM""dd""pmhh12""mi""ss""') from EMPLOYEES; select employee_id, to_char(hire_date,'YYYY""MM""dd""hh24""mi""ss"" day d ddd"°"') from EMPLOYEES; select employee_id, to_cha...
true
c0b90a5c934cd96cbcae11e65cdb96d60d94b1ab
SQL
handharbeni/sistem-koperasi
/database/v5.sql
UTF-8
19,686
3.40625
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Versi server: 10.1.13-MariaDB - mariadb.org binary distribution -- OS Server: Win32 -- HeidiSQL Versi: 9.3.0.5119 -- ------------------------------------------------...
true
a01d5581adc0e2b4980a64c7151d8ab6e92681b1
SQL
rekysda/gisci
/database_mysql/gisci.sql
UTF-8
8,887
3.015625
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.2.7.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Jan 18, 2020 at 06:43 AM -- Server version: 5.6.20 -- PHP Version: 5.5.15 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */...
true
916485c0da783fb81565e258d242a92d3a39249b
SQL
mtejas88/esh
/Projects/Form_477_Analysis/src/sql/old/form477s-fiber-bg.sql
UTF-8
171
2.765625
3
[]
no_license
select substring(f."BlockCode" from 1 for 12) as blockgroup, count(distinct f."HoldingCompanyName") as nproviders from public.form477s f where f."TechCode"='50' group by 1
true
dccb92759d3254f1fe5c7c8f5d23f6e1251707f7
SQL
Rufian55/MoonBuyers
/SQL_Routines/MoonBuyers-queries.sql
UTF-8
5,855
4.03125
4
[ "MIT" ]
permissive
-- Moonbuyers Queries file MoonBuyers-queries.sql -- ******DO NOT IMPORT THIS FILE. FOR REFERENCE ONLY.******** -- Cut and paste queries to phpMyAdmin or CL as needed for testing purposes. -- These are general queries - refactoring may be needed to achieve desired results. -- Select accoount details and balance for al...
true
88230b4c9198802a1a101d6d8c4b990565fab865
SQL
thiagotw10/projetoAudax
/pasta-banco-dados-sql/projetoaudax.sql
UTF-8
3,638
3.09375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.1.0 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Tempo de geração: 06-Nov-2021 às 06:36 -- Versão do servidor: 10.4.19-MariaDB -- versão do PHP: 7.3.28 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_C...
true
417d47eb9523808ff2c9b46834b583b02ee03ff5
SQL
goiaba/sisen
/documentation/queries/student_total_value_by_study_option.sql
UTF-8
1,190
4.21875
4
[]
no_license
-- Pontuaçao do estudante select so.id, so.description, sum(a.value) from survey_studentanswer sa, survey_question q, survey_answer a, survey_studyoption so where sa.question_id = q.id and sa.answer_id = a.id and q.study_option_id = so.id group by so.code; --print(models.Stu...
true
4b4491db6666ec94e9f26b6d72809226398c8f85
SQL
Technoguyfication/Lexi
/src/Lexi/data/initdb.sql
UTF-8
1,283
3.5625
4
[ "MIT" ]
permissive
/* init script for the bot runs every startup, and ensures the database is up to spec other database operations can be managed independently by plugins however, some basic statistics and information are logged by the base code */ SET sql_notes = 0; -- disable table already exists warnings -- guilddata table CRE...
true
aca475aa503b735e73980ad13ed97f53f46f6d82
SQL
is-m/wecode
/wecode-sign/src/main/resources/database/init.sql
UTF-8
713
3
3
[]
no_license
DROP TABLE IF EXISTS sn_sign; CREATE TABLE sn_sign ( id VARCHAR(36) COMMENT 'ID', user_id VARCHAR(50) COMMENT 'USER ID', sign_date DATE COMMENT '签到日期', begin_time VARCHAR(10) COMMENT '开始时间,08:30', begin_point VARCHAR(20) COMMENT '开始位置,GPS定位参数', end_time VARCHAR(10) COMMENT '开始时间,18:00', e...
true
b19d595dfbbaca539860c20ab759706ea6ee5865
SQL
hardyimages/wikipedia-vgi-spatialtemporal
/src/ingest.sql
UTF-8
2,134
4.28125
4
[]
no_license
\c hardy_db set role to hardy; -- create all unique locations DROP TABLE IF EXISTS contrib_nodes; CREATE TABLE contrib_nodes AS SELECT x, y, dir::char(1), count(*) FROM ( SELECT article_x AS x, article_y AS y, 'I' as dir FROM contrib_by_month UNION SELECT contrib_x AS x, contr...
true
0c14a8d8bc41ca2a9f8047670246148b1f6efd8f
SQL
dreamingcrazy/-
/shop_web/shanghui.sql
UTF-8
1,309
3.546875
4
[]
no_license
create database tor_db charset=utf8; use tor_db; CREATE TABLE user_info( user_id int not null PRIMARY KEY auto_increment comment '用户ID', user_name VARCHAR(10) not null comment '用户名', password VARCHAR(16) not null comment '密码', phone VARCHAR(11) UNIQUE not NULL comment '手机号码', e_mail VARCHAR(50) n...
true
d0d48476071721583f6df3c5dcfca6a709dbbfe4
SQL
EricRasolofoarijaona/javaMySQL
/etude.sql
UTF-8
1,809
3.328125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.4.5 -- http://www.phpmyadmin.net -- -- Client: localhost -- Généré le : Ven 07 Septembre 2018 à 09:40 -- Version du serveur: 5.5.16 -- Version de PHP: 5.3.8 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIEN...
true
d45aff8c82166bb326e6f3af220b7c6707aa0c43
SQL
GustavoFrez/League-Of-Legends
/pergunta.sql
UTF-8
323
2.703125
3
[]
no_license
select Jogadores, count(Jogadores) as Assistências from (SELECT Assist_1 as Jogadores FROM kills UNION all SELECT Assist_2 FROM kills UNION all SELECT Assist_3 FROM kills union all SELECT Assist_4 FROM kills) as Jogadores group by Jogadores order by Assistências desc, not null; -- Qual pessoa que mais deu assistência?
true
8ff23364c1f4fb33d5328e5237a230aa07ceb08e
SQL
hittecd/csci-5622-project
/sql/inventory_measure.sql
UTF-8
705
3.171875
3
[]
no_license
# drop tables DROP TABLE IF EXISTS inventory_measure; DROP TABLE IF EXISTS inventory_measure_ssa; # create inventory_measure table CREATE TABLE inventory_measure ( id INT NOT NULL AUTO_INCREMENT, zip_id INT NOT NULL, date_time DATE NOT NULL, inventory INT NULL, PRIMARY KEY(id), FOREIGN KEY (...
true
b834c72bb1dc463a1c5ff6fa5fcb229d673d3c96
SQL
seannguyen/coin-tracker
/db/migrations/20180408164624_create_balances.sql
UTF-8
807
3.875
4
[]
no_license
-- +goose Up -- SQL in section 'Up' is executed when this migration is applied CREATE SEQUENCE balances_id_seq START WITH 1 INCREMENT BY 1 NO MINVALUE NO MAXVALUE CACHE 1; CREATE TABLE balances ( id INT NOT NULL PRIMARY KEY DEFAULT nextval('balances_id_seq'), created_at TIMESTAMP NOT NULL, u...
true
585332ae6fc454b11a4fafc98b6db9805f44d3e0
SQL
abdulahad2307/JudgeSite-Practice-Codes
/SQL/Basic Select.sql
UTF-8
4,913
4.78125
5
[]
no_license
## Revising the Select Query I: Query all columns for all American cities in the CITY table with populations larger than 100000. The CountryCode for America is USA. SELECT * FROM CITY WHERE POPULATION > 100000 AND COUNTRYCODE = 'USA'; ## Revising the Select Query II: Query the NAME field for all American cities in ...
true
b1633a3692411f9af8e755a0d467f5f3cd0e2f6c
SQL
sailakshmiyadlapati/TEDxSNIST
/contactform.sql
UTF-8
1,361
2.78125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.1.14 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Jun 18, 2017 at 03:36 PM -- Server version: 5.6.17 -- PHP Version: 5.5.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;...
true
d3f3bf9822da4c08786003fc777e5ec23fc9e6ba
SQL
kimminkyeng/CodingStudy
/0831_Sample/CourierService/courier.sql
UTF-8
4,882
3.8125
4
[]
no_license
show tables; /* 택백 목록 */ create table courier ( idx int not null auto_increment, /* 고유번호 */ part varchar(20) not null, /* 분류 */ arrival datetime not null default now(), /* 도착일자 */ product varchar(50) not null, /* 택배물품명 */ receive varchar(20) not nu...
true
c4da5ceb77eabdb1c62a5ccc66f41ac0a1c1d028
SQL
ViacheslavChernyshov/baxicar-be
/src/main/resources/script.sql
UTF-8
476
2.8125
3
[]
no_license
SET NAMES 'utf8'; CREATE DATABASE test CHARACTER SET utf8 COLLATE utf8_general_ci; CREATE TABLE user ( id bigint NOT NULL AUTO_INCREMENT, age integer, first_name varchar(255), last_name varchar(255), password varchar(255), salary bigint, username varchar(255), PRIMARY KEY (id) ) ENGINE = MYISA...
true
0b6f691bb22be6456c574fd5b358fbf641dda875
SQL
ramabit/TPGestionDeDatos
/Scripts/Creacion tabla de publicacion.sql
UTF-8
1,007
3.0625
3
[]
no_license
IF OBJECT_ID('Publicacion', 'U') IS NOT NULL DROP TABLE Publicacion create table Publicacion ( id numeric(18,0), descripcion nvarchar(255), stock numeric(18,0), fecha_inicio datetime, fecha_vencimiento datetime, precio numeric(18,0), rubro nvarchar(255), id_visibilidad numeric(18,0), username nvarchar(45), estado nvar...
true
3694672c26201c86418b4618d2b64388229d4828
SQL
dowlingmi01/sayso
/scripts/sql/2011-11-14-01-ad_metrics_tables.sql
UTF-8
3,397
3.84375
4
[]
no_license
DROP TABLE IF EXISTS metrics_tag_click_thru; DROP TABLE IF EXISTS metrics_tag_view; DROP TABLE IF EXISTS metrics_creative_click_thru; DROP TABLE IF EXISTS metrics_creative_view; CREATE TABLE metrics_tag_view ( id int(10) NOT NULL auto_increment, user_id int(10) DEFAULT NULL, starbar_id int(10) DEFAULT NUL...
true
6b0555398f18cc9f6ea9a00c5557ffd5a81183b5
SQL
dmarcanor/ddd_in_php_from_zero
/databases/francisco.sql
UTF-8
1,433
3.46875
3
[]
no_license
CREATE TABLE `courses` ( `id` CHAR(36) NOT NULL, `name` VARCHAR(255) NOT NULL, `duration` VARCHAR(255) NOT NULL, PRIMARY KEY (`id`) ) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci; CREATE TABLE `courses_counter` ( `id` CHAR(36) NOT NULL, ...
true
f891e9a5d10199bd17ba5b9eefbcb0882d30b920
SQL
cloudtestsoftware/biderp
/src/com/biderp/sql/oracle/Project/Update_Project.sql
UTF-8
2,399
3.15625
3
[]
no_license
CREATE OR REPLACE PROCEDURE Update_Project(pnObjid NUMBER) IS --Constants for status STATUS_OPEN varchar2(20):='1'; STATUS_ACCEPTED varchar2(20):='2'; BEGIN Begin Update Table_Project set Name=Name, Title=Title, ProjectNo=ProjectNo, ProjectCode=ProjectCode, Scope=Scope, LeadSourceCode=LeadSourceCode, ...
true
26ae2d2a89f61d66d3fc31af1f2c45e2e5a5d7db
SQL
MrBingCn/footarch
/src/system/install/Oracel/system_create.sql
UTF-8
524
3
3
[]
no_license
DROP TABLE IF EXISTS SYSTEM_DICT; CREATE TABLE SYSTEM_DICT ( dict_id NUMBER(12,0) NOT NULL, pro_dict_id NUMBER(12,0), domain_ varchar(50) default NULL, code_ varchar(50) default NULL, name_ varchar(250) default NULL, desc_ varchar(2500) default NULL, flag_ varchar(1) default NULL, status_ varchar(1) de...
true
aa491bb36a788d0505ef847cad0a5dc5eca74117
SQL
solanav/ecaf
/priv/repo/structure.sql
UTF-8
2,809
3.0625
3
[]
no_license
-- -- PostgreSQL database dump -- -- Dumped from database version 12.5 (Ubuntu 12.5-0ubuntu0.20.04.1) -- Dumped by pg_dump version 13.1 (Debian 13.1-1+b1) SET statement_timeout = 0; SET lock_timeout = 0; SET idle_in_transaction_session_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; S...
true
3ee4a94de4b6220909790211bc4f660fb66163e2
SQL
sierra073/gsheet-service-layer
/scripts/2019/id2050_consortium_affiliation_168_not_meeting_2018sots.sql
UTF-8
787
3.5
4
[]
no_license
select d.district_id, d.name, d.state_code, d.size, d.locale, d.num_students, d.consortium_affiliation is not null as consortium_affiliation_boolean, d.consortium_affiliation, ss.procurement as state_procurement, ss.org_structure as state_org_structure from ps.districts_fit_for_analysis fit inner join p...
true
dd4249a388f3f1cbc0c644ba1288a1111aec194b
SQL
f0y/dbintro
/src/ex_sql_mov_chal/1.sql
UTF-8
214
3.734375
4
[]
no_license
select distinct m.title, (select max(stars) from Rating where mID = m.mid) - (select min(stars) from Rating where mid = m.mid) as spread from Movie m join Rating using (mid) order by spread desc, m.title
true
d04ed723e3c6f4d58b9f5e65ef50a5bb235d02ac
SQL
lasseschmitt/orm
/angel_orm_generator/test/models/order.up.g.sql
UTF-8
210
2.671875
3
[ "MIT" ]
permissive
CREATE TEMPORARY TABLE "orders" ( "id" serial, "customer_id" int, "employee_id" int, "order_date" timestamp, "shipper_id" int, "created_at" timestamp, "updated_at" timestamp, PRIMARY KEY(id) );
true
0b82bd6a5885925bc6563cb0a102645ad8c6c6b8
SQL
tsilvab/Employee-Tracker
/assets/seed.sql
UTF-8
1,638
3.09375
3
[]
no_license
USE employee_DB; /* insert data for department */ INSERT INTO department (name) VALUES ("Sales"); INSERT INTO department (name) VALUES ("Engineering"); INSERT INTO department (name) VALUES ("Adminstration"); INSERT INTO department (name) VALUES ("Finance"); /* insert data for role */ INSERT INTO role (title, salar...
true
1a1955c72d535bb450a472a827dd8e05b6398508
SQL
adrianwalker/sctbrowser
/src/main/resources/sql/postgresql/index/create_content_refset_active_refset_id_referenced_component_id.sql
UTF-8
146
2.734375
3
[]
no_license
CREATE INDEX content_refset_active_refset_id_referenced_component_id ON content_refset USING btree (active, refset_id, referenced_component_id);
true
676275c7e7ced8f8d95ce798b42847b0ce9cfbce
SQL
Ltre/Ltre.php
/biz/RichTextResourceMigrate/struct.sql
UTF-8
3,745
3.15625
3
[]
no_license
CREATE TABLE `resource_migrate_log` ( `log_id` bigint(20) NOT NULL AUTO_INCREMENT, `raw_url` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL, `new_url` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL, `field_name` varchar(16) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '' COMMENT '例如:content, picurl', `tpl_...
true
c39dccbaa97f3c287a4ef41063b574e15a2cf54a
SQL
TheSharkReadabook/info_collector
/info_collector/mysql-query.sql
UTF-8
3,086
3.140625
3
[]
no_license
CREATE TABLE `news` ( `id` INT(22) NOT NULL AUTO_INCREMENT PRIMARY KEY, `title` VARCHAR(256) NOT NULL, `description` TEXT, `url` VARCHAR(256) NOT NULL, `urlToImage` VARCHAR(256), `content` TEXT NOT NULL, `date` DATE ); CREATE TABLE `corona19` ( `id` INT(22) NOT NULL AUTO_INCREMENT PRIM...
true
bf1520ad8f5d37fcbbcfca46c427f1003e2cd04a
SQL
fosskers/playground
/sql/sql.sql
UTF-8
630
3.890625
4
[]
no_license
-- Choose your DB use products; -- Inserting insert into products (maker, model, p_type) values ("c", "1100", "pc"); -- PC(model,maker) -- Laptop(model,maker) -- Printer(model,maker) -- Delete laptops made by Makers who don't make printers. delete from laptops where maker not in ( -- Makers of printers. s...
true
336e2790494c384ebb9c942517a787c9113dd8bc
SQL
Giugurtah/db-university
/quesries.sql
UTF-8
1,612
4.21875
4
[]
no_license
--* USANDO SELECT -- Selezionare tutti gli studenti nati nel 1990 SELECT * FROM `students` WHERE YEAR(`date_of_birth`) = 1990; -- Selezionare tutti i corsi che valgono più di 10 crediti SELECT * FROM `courses` WHERE `cfu` > 10; -- Selezionare tutti gli studenti che hanno più di 30 anni SELECT * FROM `students` ...
true
d8047bdf99691c751dbdde0bb8a87ae03877c216
SQL
Matt23/summa
/summa.sql
UTF-8
4,630
3.140625
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Versión del servidor: 10.1.37-MariaDB - mariadb.org binary distribution -- SO del servidor: Win32 -- HeidiSQL Versión: 9.5.0.5196 -- ------------------------------------------------...
true
39281fde942b2534b56cf89a2cebb101377b05be
SQL
LakshmiBulusu/exercise.sql_join-and-group
/PART 6.SQL
UTF-8
169
3.109375
3
[]
no_license
SELECT MONTHNAME(paymentdate) AS 'MONTH', year(paymentDate) AS 'YEAR', SUM(amount) AS 'Payments Received' FROM payments GROUP BY MONTH(paymentdate), year(paymentDate);
true
989d6cd250c06edbfdeecd71af59686fe6626315
SQL
samdedy/api
/db_react-app.sql
UTF-8
1,751
3.078125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 01 Okt 2020 pada 01.14 -- Versi server: 10.1.38-MariaDB -- Versi PHP: 7.2.22 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHAR...
true
c71c4cf31f65466297e5383cfa2242ec9e0997cc
SQL
patjan/erp
/sql/Pieces.sql
UTF-8
6,539
3.296875
3
[]
no_license
DROP TABLE IF EXISTS Pieces; CREATE TABLE IF NOT EXISTS Pieces ( id BIGINT NOT NULL AUTO_INCREMENT , updated_by BIGINT DEFAULT NULL , updated_at DATETIME DEFAULT NULL , status VARCHAR(32) DEFAULT 'Active' # Active > Check In # Check In > Check Out # Check Out > Recei...
true
030bf4f641597aa14c21279a8d5e5b0889b90759
SQL
leebuyer/remains_new_20210526_scrolling
/sql.sql
UTF-8
2,299
3.0625
3
[]
no_license
CREATE TABLE `tree` ( `tree_sn` mediumint(8) unsigned NOT NULL AUTO_INCREMENT COMMENT '遺址發掘原因編號', `reason_content` text NOT NULL COMMENT '遺址發掘原因', `action_content` text NOT NULL COMMENT '一起考古去', `appearance_introduction` varchar(255) NOT NULL COMMENT '史前人介紹', `appearance_title` varchar(255) NOT NULL COMMENT '...
true
1a691b7638f397e1f4b360738d334c6320e6d93d
SQL
acpappas/php-bootcamp
/Day05/ex10/ex10.sql
UTF-8
206
3.640625
4
[]
no_license
USE student_base; select film.title as "Title", film.summary as "Summary", `prod_year` from film inner join genre on film.id_genre = genre.id_genre where genre.name like "erotic" ORDER BY `prod_year` DESC;
true
65a5d623e75c0be1edf16c2e32251783c64b082d
SQL
DaMSL/K3-Mosaic
/tests/queries/mddb/query2.sql
UTF-8
1,082
3.40625
3
[]
no_license
INCLUDE 'examples/queries/mddb/schemas.sql'; select P1.trj_id, P1.t, dihedral_angle(P1.x,P1.y,P1.z, P2.x,P2.y,P2.z, P3.x,P3.y,P3.z, P4.x,P4.y,P4.z) as phi_psi, DM.dim_id from Dihedrals D, Dimensions DM, AtomPositions P1, AtomPositions P2, AtomPositions P3, AtomPositio...
true
a325537996ae4e415524a64581c8cd75228f3569
SQL
richiMarchi/E-cantoun-dla-pida
/Web/sql/bibita.sql
UTF-8
2,171
3.15625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Creato il: Feb 18, 2018 alle 13:26 -- Versione del server: 10.1.26-MariaDB -- Versione 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_...
true
9f7e5fd8b27922a2a04d62d92b671e26677d4f0f
SQL
tectronics/cupang-elementary-school-dental-record
/src/sql/CESDentalRecord-schema.sql
UTF-8
4,581
3.125
3
[]
no_license
# ----------------------------------------------------------------------- # student # ----------------------------------------------------------------------- drop table if exists student; CREATE TABLE student ( studentID INTEGER NOT NULL AUTO_INCREMENT, surname VARCHAR (30) NOT NULL, ...
true
517bdb3e0fa920cf3eae3c3c6be7484ea909cc49
SQL
cspark777/jobtool
/ui/schema.sql
UTF-8
1,018
2.8125
3
[]
no_license
DROP TABLE IF EXISTS posts; CREATE TABLE extract_job ( Job_ID INTEGER PRIMARY KEY AUTOINCREMENT, Creation_Date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, WEB_CLASS_NUM INTEGER NOT NULL, ATTR_NM TEXT NOT NULL ); CREATE TABLE extractor_model ( model_id INTEGER PRIMARY KEY AUTOINCREMENT, crea...
true
1c2cba843b0ffd6b6b4a06d50a5939f67b47b8f3
SQL
novichkovv/divine_health_study
/migrations/tables.sql
UTF-8
2,645
3.5625
4
[]
no_license
CREATE TABLE study_users ( id SERIAL PRIMARY KEY, user_login VARCHAR(255) NOT NULL, user_password VARCHAR (255) NOT NULL, user_name VARCHAR (255) NOT NULL, user_surname VARCHAR(255) NOT NULL, id_study_status INT NOT NULL, create_date DATETIME NOT NULL )ENGINE=MyISAM; CREATE TABLE study_pages ( id SERIAL PRIMARY KEY, i...
true
ab4d6458272b6624ae46cc15a3d718320be039b7
SQL
Juls-mc/Groupomania
/backend/groupomania.sql
UTF-8
3,930
3.484375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.7 -- https://www.phpmyadmin.net/ -- -- Hôte : localhost:8889 -- Généré le : ven. 12 mars 2021 à 09:00 -- Version du serveur : 5.7.32 -- Version de PHP : 7.4.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Base de données : `groupomania` -- -- --------...
true
e548f0fedad5c6acb9434f45fc00684360c5f116
SQL
betacompany/pipeinpipe
/junk/ortemij/sql/count_pms.sql
UTF-8
165
3.1875
3
[]
no_license
SELECT `competition_id`, COUNT(DISTINCT (`pmid`)) FROM `p_man_cup_result` INNER JOIN `p_cup` ON `p_man_cup_result`.`cup_id`=`p_cup`.`id` GROUP BY `competition_id`
true