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
129cbb0d27b543d4b74086f579e69ff9c836d76d
SQL
DefJia/Bus-100
/SQL/init.sql
UTF-8
636
3.234375
3
[ "Apache-2.0" ]
permissive
create table `main`( `id` int(3) primary key auto_increment, `time` timestamp NOT NULL, `num` varchar(8), `stop` varchar(10), `comment` varchar(50), `latitude` decimal(10,6), `longitude` decimal(10,6) )ENGINE=InnoDB charset=utf8; create table `rule`( `id` int(3) primary key auto_increment, `time...
true
e374fa76722273801de8d15d0c38e4a3a842ea1d
SQL
maduhu/MARLO-CIAT
/marlo-ciat/marlo-ciat-web/src/main/resources/database/migrations/V1_0_0_20170314_1551__deliverableDocuments.sql
UTF-8
667
3.03125
3
[]
no_license
CREATE TABLE `deliverable_documents` ( `id` bigint(20) NOT NULL AUTO_INCREMENT , `deliverable_id` bigint(20) NOT NULL , `link` text NULL , `is_active` tinyint(1) NOT NULL , `created_by` bigint(20) NULL , `modified_by` bigint(20) NULL , `active_since` timestamp NULL , `modification_justification` text NULL , PRI...
true
d5ad5c29c205199e2d8cd8af90d5256783b4d992
SQL
Frozzeg/Pyha-Forum-Engine
/dump.sql
UTF-8
690
3.046875
3
[]
no_license
CREATE TABLE IF NOT EXISTS `users` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `role` varchar(255) NOT NULL DEFAULT 'user', `name` varchar(255) NOT NULL, `surname` varchar(255) NOT NULL, `gender` int(11) NOT NULL DEFAULT '1', `country` int(11) NOT NULL, `city` int(11) NOT NULL, `registration_date` ...
true
a672b07d677bc7211389987b5f716544f9a5ff2c
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/low/day27/select2144.sql
UTF-8
262
2.921875
3
[]
no_license
SELECT sen.name FROM SENSOR sen, SENSOR_TYPE st, COVERAGE_INFRASTRUCTURE ci WHERE sen.SENSOR_TYPE_ID=st.id AND st.name='WeMo' AND sen.id=ci.SENSOR_ID AND ci.INFRASTRUCTURE_ID=ANY(array['4209','6034','5234','4206','2052','5082','5219','3044','3089','5100_2'])
true
68097e987f2262c6b01bf0a78ed7bf7e8fa3f7e0
SQL
abhinavms/Grievance-Cell
/DB/grv.sql
UTF-8
3,168
2.6875
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 10.1.32-MariaDB - mariadb.org binary distribution -- Server OS: Win32 -- HeidiSQL Version: 9.5.0.5196 -- -------------------------------------------...
true
e4706ab77b0586358e294d284e09be12cb529496
SQL
victor1600/bad115
/ejercicios/funciones.sql
UTF-8
934
3.515625
4
[]
no_license
------------ EJECUTAR UNA FUNCION PARA CADA FILA DE UNA TABLA USANDO SELECT --------- CREATE OR REPLACE FUNCTION tax(p_value IN NUMBER) return number is begin RETURN (p_value * 0.08); end; select EMPLOYEE_ID, LAST_NAME, SALARY, tax(SALARY) from EMPLOYEES where DEPARTMENT_ID = 100; -----------------------------...
true
f77d0c44140947d9e9d93a6ab92d7ab19a3cae7d
SQL
SEANDOUGHTY/redwood-voting-app
/api/db/migrations/20210329230951_vote/migration.sql
UTF-8
854
3.21875
3
[ "MIT" ]
permissive
/* Warnings: - You are about to drop the column `email` on the `UserExample` table. All the data in the column will be lost. - You are about to drop the column `name` on the `UserExample` table. All the data in the column will be lost. - Added the required column `vote` to the `UserExample` table without a def...
true
01d1732c5281597eee8ccbc2b74af9f6710d64ea
SQL
SeojunHwang/Busan_Study
/SQL/SQL_20210521.sql
UTF-8
1,943
4.03125
4
[]
no_license
-- MYSQL ์‚ฌ์šฉ ๋ช…๋ น์–ด -- mysql ์ฝ˜์†” ์ ‘์† ๋ช…๋ น -- mysql -u ์‚ฌ์šฉ์žid -p -- ๋‹ค๋ฅธ ์„œ๋ฒ„์— ์žˆ๋Š” mysql์— ์ ‘์†ํ•  ๊ฒฝ์šฐ ์‚ฌ์šฉ -- mysql -u ์‚ฌ์šฉ์žid -p -h ์ ‘์†์ฃผ์†Œ -- ๋‹ค๋ฅธ ์„œ๋ฒ„์— ์žˆ๋Š” mysql์— ์ ‘์† ์‹œ port๊นŒ์ง€ ์„ค์ •ํ•˜์—ฌ ์ ‘์† -- mysql -u ์‚ฌ์šฉ์žid -p -h ์ ‘์†์ฃผ์†Œ -P ํฌํŠธ๋ฒˆํ˜ธ -- ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ๋Š” DB ๋ชฉ๋ก ํ™•์ธ SHOW DATABASES; -- ์‚ฌ์šฉํ•  DB ์ง€์ • -- ex) USE DB๋ช…; USE mysql; -- ํ•ด๋‹น DB์— ํฌํ•จ๋œ table ๋ชฉ๋ก ํ™•์ธ SHOW TABLES; -- ์‚ฌ...
true
95a0172573f76f6e1abd70dc36ea4d34fec0d3ea
SQL
ijw9209/Workspace_Web
/Jsp13_CalBoardpage/build/classes/com/cal/db/db.sql
UTF-8
1,172
4.28125
4
[]
no_license
DROP TABLE CALBOARD; DROP SEQUENCE CALBOARDSEQ; CREATE SEQUENCE CALBOARDSEQ; CREATE TABLE CALBOARD( SEQ NUMBER PRIMARY KEY, ID VARCHAR2(2000) NOT NULL, TITLE VARCHAR2(1000) NOT NULL, CONTENT VARCHAR2(4000) NOT NULL, MDATE VARCHAR2(12) NOT NULL, REGDATE DATE NOT NULL ); SELECT * FROM CALBOARD WHERE ID = 'kh' AN...
true
fec3870cedbb6962b3349a51dd3c99cd703489c8
SQL
beepsboops/BootcampX
/3_queries_group-by/cohort_total_assignment_submissions.sql
UTF-8
584
3.765625
4
[]
no_license
-- MY ANSWER (ALSO WORKS) -- SELECT cohorts.name as cohort, count(assignment_submissions.id) as total_submissions -- FROM cohorts -- JOIN students ON cohorts.id = students.cohort_id -- JOIN assignment_submissions ON assignment_submissions.student_id = students.id -- GROUP BY cohort -- ORDER BY total_submissions DESC -...
true
6dcc745adcaa11abf4ff879203e8977fe268c6c8
SQL
gustavobonassa/Sites
/snake-game/u90603881_lol.sql
UTF-8
2,032
2.9375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.4.15.1 -- http://www.phpmyadmin.net -- -- Host: mysql796.umbler.com -- Generation Time: 02-Jul-2017 ร s 13:57 -- Versรฃo do servidor: 5.6.34-log -- PHP Version: 5.4.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER...
true
de312763dc05984d604e10baf251595a1ea27214
SQL
clusson/DB-SQL-Postgres
/init.sql
UTF-8
519
3.78125
4
[]
no_license
CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; CREATE TABLE roles ( roleId int NOT NULL, role varchar(25) NOT NULL, PRIMARY KEY (roleId) ); CREATE TABLE users ( userId uuid DEFAULT uuid_generate_v4 (), firstname varchar(25) NOT NULL, lastname varchar(25) NOT NULL, created_at date NOT NULL DEF...
true
0725a02439e5af09d618e847ee5e55ad7daa227d
SQL
HidakaRintaro/MISSION_DMM-Go
/ddl/ddl.sql
UTF-8
663
3.65625
4
[ "MIT" ]
permissive
CREATE TABLE `account` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `username` varchar(255) NOT NULL UNIQUE, `password_hash` varchar(255) NOT NULL, `display_name` varchar(255), `avatar` text, `header` text, `note` text, `create_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`id`) ); CREA...
true
981273d3ec3da8641b64e1cf914dc7eda0a74ca3
SQL
bellmit/flexdb
/2.HOST/4.Function/fnc_get_price_plo.sql
UTF-8
1,665
3.53125
4
[]
no_license
-- Start of DDL Script for Function HOSTMSTRADE.FNC_GET_PRICE_PLO -- Generated 22/10/2018 9:41:21 AM from HOSTMSTRADE@FLEX_111 CREATE OR REPLACE FUNCTION fnc_get_price_plo( v_strSYMBOL IN Varchar2, v_strEXECTYPE IN Varchar2 ) RETURN NUMBER IS v_plobycloseprice varchar2(5); v_price number; BEGIN v_price := 0; B...
true
218b88c907fd8cb1433c35ef58c767f4c6e5aae0
SQL
alldatacenter/alldata
/lake/amoro/ams/server/src/main/resources/mysql/ams-mysql-init.sql
UTF-8
13,607
3.65625
4
[ "Apache-2.0", "BSD-3-Clause", "MIT" ]
permissive
CREATE TABLE `catalog_metadata` ( `catalog_id` int(11) NOT NULL AUTO_INCREMENT, `catalog_name` varchar(64) NOT NULL COMMENT 'catalog name', `catalog_metastore` varchar(64) NOT NULL COMMENT 'catalog type like hms/ams/hadoop/custom', `storage_configs` mediumtext COMMENT '...
true
216f99ca66e7e531d4fc04800ca5af1752ee1f15
SQL
nitinkumar04/LiquorWarehouse
/LiquorWarehouseStage_1_0/GVW/Tables/AccountsforHQByDim.sql
UTF-8
463
2.84375
3
[]
no_license
๏ปฟCREATE TABLE [GVW].[AccountsforHQByDim]( [GVWAccountsforHQBySKey] int identity(1,1), [AcctUnivDimID] [varchar](18) NULL, [AcctHQDimID] [varchar](18) NULL, [Type] [varchar](200) NULL, GVWCreatedDate datetime default getdate() NOT NULL, GVWLastModifiedDate datetime default getdate() NOT NULL, G...
true
6f5a06439a6badd013af05ba7a1afab6ae1d86c5
SQL
BhagyashriNBhamare/Employee-Appraisal-management
/Database/data.sql
UTF-8
4,636
2.828125
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.19, for Win64 (x86_64) -- -- Host: localhost Database: emp -- ------------------------------------------------------ -- Server version 8.0.19 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!4010...
true
7aaf79ba0dcb06a4f3f2d56968c573a335bd5750
SQL
LuffyWesley/Tempr
/query.sql
UTF-8
307
2.828125
3
[ "MIT" ]
permissive
-- Query to see everything in the tables -- SELECT * FROM test ORDER BY creationTime DESC; -- SELECT TOP 20 * FROM test2 ORDER BY creationTime DESC; -- SELECT AVG(compound) FROM test WHERE creationTime >= DATEADD(minute, -16000, GETDATE()); -- SELECT * FROM test; -- SELECT * FROM test2; SELECT * FROM list;
true
752bf835e7f10658366f95db03cbfb1b6ac43baa
SQL
vyesubabu/metview
/odb_api_bundle-0.17.6-Source/odb/src/ddl/sat_radar.sql
UTF-8
188
2.703125
3
[]
no_license
// //-- ODB/SQL file 'sat_radar.sql' // READONLY; CREATE VIEW sat_radar AS SELECT satellite_identifier, radar_station.offset UPDATED FROM sat WHERE radar_station.len>0 ;
true
2a94676af9910021bd0c78a6d4f1f31130feca60
SQL
dael-victoria-reyes/data-act-broker-backend
/dataactcore/scripts/raw_sql/backfill_awarding_office_names_q12019.sql
UTF-8
301
2.953125
3
[ "CC0-1.0" ]
permissive
UPDATE published_award_financial_assistance AS pafa SET awarding_office_name = office.office_name FROM office WHERE pafa.awarding_office_code = office.office_code AND cast_as_date(pafa.action_date) >= '2018/10/01' AND pafa.awarding_office_name IS NULL AND pafa.awarding_office_code IS NOT NULL;
true
932e7a68737522b767e67d48447412012512b63c
SQL
john310897/depthealthcaresys
/database/health_care.sql
UTF-8
5,770
3.28125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 23, 2020 at 10:01 AM -- Server version: 10.1.38-MariaDB -- PHP Version: 7.3.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
5e3c0b34e683f1a916066fa293e118ac870272d7
SQL
nikisf/SoftUni
/Databases Basics - MySQL/Subqueries and JOINs/17. Highest Peak and Longest River by.sql
UTF-8
566
4.3125
4
[]
no_license
SELECT `country_name`, MAX(p.elevation) AS highest_peak_elevation, MAX(r.length) AS longest_river_length FROM countries AS c JOIN mountains_countries AS mc ON mc.country_code = c.country_code JOIN mountains AS m ON m.id = mc.mountain_id JOIN countries_rivers AS cr ON...
true
d0a1b246c4a3377d0da6b412b2efa54c8d83dbc0
SQL
yolenta/jelis-rintan-arie-ignas
/Table DOSEN.sql
UTF-8
2,120
3.125
3
[]
no_license
-------------------------------------------------------- -- File created - Friday-June-03-2016 -------------------------------------------------------- -------------------------------------------------------- -- DDL for Table DOSEN -------------------------------------------------------- CREATE TABLE "HR"."D...
true
a16626bfb8819aaed2e63a5d5931d8778865cbc5
SQL
hdtrung01/TestGK
/blood_donor.sql
UTF-8
1,664
2.9375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.1.1 -- https://www.phpmyadmin.net/ -- -- Mรกy chแปง: 127.0.0.1 -- Thแปi gian ฤ‘รฃ tแบกo: Th10 21, 2021 lรบc 06:21 PM -- Phiรชn bแบฃn mรกy phแปฅc vแปฅ: 10.4.21-MariaDB -- Phiรชn bแบฃn PHP: 8.0.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHA...
true
5705b3837254d1067a20cf1bf8d14d9955b4268a
SQL
ArctosDB/DDL
/triggers/uam_triggers/taxonomy.sql
UTF-8
4,429
2.96875
3
[]
no_license
CREATE OR REPLACE TRIGGER TRG_MK_SCI_NAME BEFORE INSERT OR UPDATE ON TAXONOMY FOR EACH ROW DECLARE nsn varchar2(4000); nft varchar2(4000); BEGIN IF :NEW.subspecies IS NOT null THEN nsn := :NEW.subspecies; nft := :NEW.subspecies; END IF; IF :NEW.infraspecific_rank IS NOT null THEN nsn := :N...
true
04764215431c784b2fe46294b794301e82c11552
SQL
gialnet/collect_tax
/007_SEGURIDAD_Y_ACCESOS.SQL
ISO-8859-1
6,184
3.03125
3
[]
no_license
-- ----------------------------------------------------- -- Euro. Revisado el 30-11-2001. Lucas Fernndez Prez -- No se han realizado cambios. -- ----------------------------------------------------- -- *************************************************** -- -- Paquete de gestin de los logs de la base de datos -- -- ***...
true
c5d831969952a5d593c26c170e80f6c7da6cdd67
SQL
josyan/inline
/db/inline-ddl.sql
UTF-8
13,584
2.828125
3
[]
no_license
-- MySQL dump 10.11 -- -- Host: 127.0.0.1 Database: inline_development -- ------------------------------------------------------ -- Server version 5.0.51b-community-nt /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @...
true
74f6283ed5aaa3d69d307b6d248023e766589ef6
SQL
pickdani/leetcode
/Database/easy/customers-who-never-order.sql
UTF-8
165
2.96875
3
[]
no_license
SELECT Customers.name as Customers FROM Customers WHERE Customers.Id NOT IN ( SELECT Orders.CustomerId FROM Orders );
true
6add277fede427b42eeca660f4b0099764310e39
SQL
aeternity/aeternal
/migrations/2019-02-25-134849_contract_identifiers/up.sql
UTF-8
523
3.890625
4
[ "ISC" ]
permissive
-- Your SQL goes here CREATE TABLE contract_identifiers ( id SERIAL PRIMARY KEY, contract_identifier VARCHAR(55), transaction_id INTEGER NOT NULL REFERENCES transactions(id) ON DELETE CASCADE); CREATE INDEX contract_identifiers_contract_identifier ON contract_identifiers(contract_identifier); CRE...
true
e96164b66e9a83f67a08e0d57bf3f0eb80e579d4
SQL
mundodron/arduino-bot-aurelio
/Querys/~eb2383.sql
UTF-8
623
3.140625
3
[]
no_license
INSERT INTO ${TABELA} (ACCOUNT_NO, BILL_PERIOD,PROCESSO, DURACAO) SELECT DISTINCT ACCOUNT_NO,BILL_PERIOD,1,1 FROM GVT_TEMP_CONTAS_PROFORMA WHERE UPPER(BILL_PERIOD) IN (SELECT BILL_PERIOD FROM GVT_PROCESSAMENTO_CICLO WHERE UPPER(PROCESSAMENTO) = UPPER('${CICLO}')) UNION SELECT DISTINCT GPC.ACCOUNT_...
true
d1d8c52ebb0bc0112e5aa5226c139edf666dadfd
SQL
MaryuriL/BD
/Reto 4/registro.sql
UTF-8
1,555
2.8125
3
[]
no_license
CREATE TABLE `registro` ( idregistro INT NOT NULL AUTO_INCREMENT, fecha DATETIME NOT NULL, idmantenimiento INT NOT NULL, idempleado INT NOT NULL, FOREIGN KEY (idmantenimiento) REFERENCES mantenimiento(idmantenimiento), FOREIGN KEY (idempleado) REFERENCES empleado(idempleado) ON DELETE CASCA...
true
330fc9fc0c19c4f6689001e0c69d6d0183799d7d
SQL
anhken238/NewModule2
/session9/thuchanh_taokhoachinh.sql
UTF-8
759
3.859375
4
[]
no_license
-- tแบกo bแบฃng users vร  khoรก chรญnh cho bแบฃng lร  trฦฐแปng user_id CREATE TABLE users( user_id INT AUTO_INCREMENT PRIMARY KEY, username VARCHAR(40), password VARCHAR(255), email VARCHAR(255) ); -- sแปญ dแปฅng tแปซ khoรก PRIMARY แปŸ cuแป‘i cรขu lแป‡nh tแบกo khoรก chรญnh bแบฃng roles CREATE TABLE roles( role_id INT AUTO_INCREMENT, ...
true
c52323e7e797c04cd918f0bf95f4dea87facf1b5
SQL
diligejy/SQL
/sql_200/source_code/20_REPLACE.sql
UHC
404
2.9375
3
[]
no_license
SELECT ename, REPLACE(sal, 0, '*') FROM emp; SELECT ename, REGEXP_REPLACE(sal, '[0-3]', '*') as SALARY FROM emp; CREATE TABLE TEST_ENAME (ENAME VARCHAR2(10)); INSERT INTO TEST_ENAME VALUES('ศฃ'); INSERT INTO TEST_ENAME VALUES('ศป'); INSERT INTO TEST_ENAME VALUES('ึฟ'); COMMIT; SELECT REPLACE(ename, SUBSTR(...
true
c8e2e0db41c27007cdbe2d0178a9f9f9b1640a76
SQL
mblockelet/TaskPlatform
/dbv_data/schema/tm_tasks_subtasks.sql
UTF-8
415
2.796875
3
[ "MIT" ]
permissive
CREATE TABLE `tm_tasks_subtasks` ( `ID` bigint(20) NOT NULL, `idTask` bigint(20) NOT NULL, `iRank` tinyint(3) NOT NULL COMMENT 'position of the subtask in the task', `name` varchar(255) NOT NULL, `comments` text NOT NULL, `iPointsMax` tinyint(11) NOT NULL, `iVersion` int(11) NOT NULL, PRIMARY KEY (`ID`)...
true
ae2e1649095d341d5d35d40345b1a860f9d1dfa5
SQL
colinthomas-z80/cs418-Monitoring-Ships-At-Sea
/scripts/schema.sql
UTF-8
2,650
3.609375
4
[]
no_license
# nprenet@bsu.edu # CS418, Spring 2021 drop database if exists AISDraft; create database AISDraft; use AISDraft; ## Create here the VESSEL table: create table VESSEL( IMO mediumint unsigned, Flag varchar(40), Name varchar(128), Built smallint, Callsign varchar(8), Length smallint, Breadth tinyint, Tonnage ...
true
85c63c1027d065b5ea79ce7241fc9191d6531ef6
SQL
x12311231/open_thinkcms
/sql/sign.sql
UTF-8
393
2.828125
3
[]
no_license
DROP TABLE IF EXISTS `app_sign`; CREATE TABLE `app_sign` ( `id` int unsigned NOT NULL AUTO_INCREMENT COMMENT '่‡ชๅขžid', `uid` int unsigned NOT NULL COMMENT '็”จๆˆทuid', `sign_tm` int unsigned NOT NULL COMMENT '็ญพๅˆฐๆ—ถ้—ด', `sign_num` smallint(6) NOT NULL COMMENT '่ฟž็ปญ็ญพๅˆฐๅคฉๆ•ฐ', PRIMARY KEY (`id`) ) ENGINE=InnoDB DE...
true
28b782b9535cc815b905c14f31e7f4d5b07c4e71
SQL
johanreji/carparkingreservation
/database-dump.sql
UTF-8
18,895
3.03125
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.25, for Linux (x86_64) -- -- Host: localhost Database: bookmyslot -- ------------------------------------------------------ -- Server version 5.7.25-0ubuntu0.18.04.2 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER...
true
3034ff6d8e4f6f96416a3521a750974f5e31fa39
SQL
Muzznah/Pewlett-Hackards-People-Analysis
/Queries/queries.sql
UTF-8
4,600
4.3125
4
[]
no_license
--Get employees that are retiring soon(Born btw 1952-1955). SELECT first_name, last_name FROM employees WHERE birth_date BETWEEN '1952-01-01' AND '1955-12-31'; --Get employees that were born in 1952 and will retire soon. SELECT first_name, last_name FROM employees WHERE birth_date BETWEEN '1952-01-01' AND '1952-12-31'...
true
241b37a759f969bc9617e6e6260810accf30b1b1
SQL
ashamrock/Hot-Table
/customers.sql
UTF-8
1,037
3.40625
3
[]
no_license
DROP DATABASE IF EXISTS customersDB; DROP DATABASE IF EXISTS waitListDB; CREATE DATABASE customersDB; CREATE DATABASE waitListDB; USE customersDB; CREATE TABLE CUSTOMERS ( person_id INT NOT NULL AUTO_INCREMENT, identification VARCHAR(20) NOT NULL, customerName VARCHAR(20) NOT NULL, customerEmail VARCHAR(20)...
true
f54de5985120f80f5bb1b369cf1ff28f87ecbbd5
SQL
jzebker/Pewlett_Hackard_Analysis
/Queries/retirees_by_title.sql
UTF-8
257
4
4
[ "MIT" ]
permissive
-- Retirees by title SELECT ti.title, count(e.emp_no) FROM titles as ti INNER JOIN employees as e ON ti.emp_no = e.emp_no WHERE ti.to_date = '9999-01-01' AND (e.birth_date BETWEEN '1952-01-01' AND '1955-12-31') GROUP BY title ORDER BY count(e.emp_no) DESC;
true
1ef3a3859b93808d88ed88517b9e74dde2dd6511
SQL
jonjomckay/cozzer
/src/main/resources/migrations/V0003__create_submissions.sql
UTF-8
298
3.640625
4
[ "MIT" ]
permissive
CREATE TABLE IF NOT EXISTS submissions ( id uuid not null primary key, project_id uuid not null, created_at timestamp with time zone default now() ); ALTER TABLE submissions ADD CONSTRAINT fk_submissions_project FOREIGN KEY (project_id) REFERENCES projects (id) ON DELETE CASCADE;
true
8da06cf8b0c2716e2179a5b5ba7999bb69d99287
SQL
Louise-MP/Openclassrooms_project
/export_bdd/bdd.sql
UTF-8
5,598
3.140625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.0.1 -- https://www.phpmyadmin.net/ -- -- Hรดte : localhost:8889 -- Gรฉnรฉrรฉ le : sam. 28 dรฉc. 2019 ร  01:36 -- Version du serveur : 5.7.26 -- Version de PHP : 7.3.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Base de donnรฉes : `espace_membre` -- -- --...
true
f9732781f2a7a1fb1d89e6a21a1cde50e232c3f4
SQL
susannapeek1/seisundid_SQL
/Magistritรถรถ/SQL kood kรตigile disainidele/Pรตhiolemitรผรผbi_alamtรผรผpidena/4.7_S4/4.7_S4.sql
UTF-8
537
3.203125
3
[]
no_license
SELECT 'Ootel' AS seisund WHERE NOT EXISTS (SELECT * FROM ootel_tellimus) UNION SELECT 'Tรถรถtlemisel' AS seisund WHERE NOT EXISTS (SELECT * FROM tootlemisel_tellimus) UNION SELECT 'Vรคlja saadetud' AS seisund WHERE NOT EXISTS (SELECT * FROM valja_saadetud_tellimus) UNION SEL...
true
cb71ca433d6741fbb429c6d3490cae951b697f4c
SQL
feisishui/oracle-spatial-workshop
/Workshop_Files/labs/16-3D-support/02-point_clouds/03_load_from_points/07_clip_scene_polygon.sql
UTF-8
507
2.703125
3
[]
no_license
DROP TABLE lidar_points_clip PURGE; CREATE TABLE lidar_points_clip NOLOGGING PARALLEL AS SELECT * FROM TABLE ( get_points ( SDO_GEOMETRY ( 2003, 32617, NULL, SDO_ELEM_INFO_ARRAY (1, 1003, 1), SDO_ORDINATE_ARRAY ( 289650, 4321200, 289600, 4321150, 289650,...
true
b06970e13663dc8149d7a534025cba26da563c63
SQL
danz50of/DZCommandLibrary
/SQL/SO_COST_REVIEW_custom.sql
UTF-8
566
3.375
3
[]
no_license
select SO.ORDER_NO, SOC.PART_NO, SOC.CLOSE_DATE, SOC.REVISED_QTY_DUE BUILD_QTY, SOC.QTY_COMPLETE, SOC.TOTAL_STD_ACCUM_COST TOTAL_STANDARD_COST, SOC.TOTAL_ACTUAL_ACCUM_COST TOTAL_ACTUAL_COST, SOC.ACT_STD_ACCUM DIFF, SOC.ACT_STD_ACCUM_FACTOR PRCT_DIFF from shop_ord SO, SHOP_ORDER_COST_OVERVIEW SOC, ifsinfo.PRL_LAB_ACT...
true
ca448c690adbae2a05bd1978f0e1a0daf3e5022d
SQL
hah1346798520/FruitSalesPlatform
/sql/fruit_manage.sql
UTF-8
8,067
3.234375
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : localhost_3306 Source Server Version : 80013 Source Host : localhost:3306 Source Database : fruit_manage Target Server Type : MYSQL Target Server Version : 80013 File Encoding : 65001 Date: 2019-06-13 21:32:29 */ SET FO...
true
b0a43d18a7ad98060e19d90ecabe2af7627d4a06
SQL
stadobaranov/SkillboxJava
/module12/16/ToDoList/backend/src/main/resources/migrations/tasks.sql
UTF-8
206
2.765625
3
[]
no_license
CREATE TABLE `tasks` ( `id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT, `name` TEXT NOT NULL, `completed_at` DATETIME NULL DEFAULT NULL, `created_at` DATETIME NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB
true
8ab71b0b568e839bbe7dcaa830445194f359d89a
SQL
YaoChungLiang/Database
/HW3/hw3-q2.sql
UTF-8
233
3.6875
4
[]
no_license
SELECT DISTINCT F.origin_city AS City FROM Flights AS F WHERE F.origin_city NOT IN (SELECT DISTINCT F1.origin_city FROM Flights AS F1 WHERE F1.actual_time >= 180) ORDER BY City;
true
81aa666d08ac075529f604ae2c0f17e81a43c079
SQL
RyanO70/cs230_WebProcessingInformation
/assignment-04/cs230_u200293.sql
UTF-8
1,922
2.96875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.1.0 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Apr 03, 2021 at 12:46 AM -- Server version: 10.3.27-MariaDB-0+deb10u1 -- PHP Version: 7.3.27-1~deb10u1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
e845c785a3e4ec58b15c12e19f9e10011406325e
SQL
CaseyJames669/Databases_MySQL
/Project 11/SQLQuery21.sql
UTF-8
316
3.421875
3
[]
no_license
SELECT LGEMPLOYEE.EMP_NUM, LGEMPLOYEE.EMP_LNAME, LGEMPLOYEE.EMP_FNAME, Min(LGSALARY_HISTORY.SAL_AMOUNT) AS Sal_Amount FROM LGEMPLOYEE INNER JOIN LGSALARY_HISTORY ON LGEMPLOYEE.EMP_NUM = LGSALARY_HISTORY.EMP_NUM GROUP BY LGEMPLOYEE.EMP_NUM, LGEMPLOYEE.EMP_LNAME, LGEMPLOYEE.EMP_FNAME ORDER BY LGEMPLOYEE.EMP_NUM;
true
b63497819aab56eb0ab1f2f88df088c0a42f5d2e
SQL
yekoufeng/AssetExpress
/mysql/assetexpress.sql
UTF-8
5,333
3.515625
4
[]
no_license
/* Navicat MySQL Data Transfer Source Server : 192.168.93.183 Source Server Version : 50722 Source Host : 192.168.93.183:3306 Source Database : assetexpress_mjc Target Server Type : MYSQL Target Server Version : 50722 File Encoding : 65001 Date: 2018-09-06 09:58:52 */ -- CREATE USE...
true
2736958a591ea1868d834530ad87200e87cdb3bc
SQL
jurewerk/draggproject
/items.sql
UTF-8
2,485
2.953125
3
[]
no_license
-- -------------------------------------------------------- -- Host: 192.168.10.10 -- Server version: 5.6.27-0ubuntu0.14.04.1 - (Ubuntu) -- Server OS: debian-linux-gnu -- HeidiSQL Version: 9.3.0.4984 -- ------------------------------------------------...
true
c4111ff155481ba5e9cb603b8f4f82910de5146e
SQL
navikt/helse-spetakkel
/src/main/resources/db/migration/V6__vedtaksperiode_endret_historikk.sql
UTF-8
545
2.625
3
[ "MIT" ]
permissive
CREATE TABLE vedtaksperiode_endret_historikk ( vedtaksperiode_id UUID NOT NULL, forrige VARCHAR(64) NOT NULL, gjeldende VARCHAR(64) NOT NULL, endringstidspunkt TIMESTAMP NOT NULL, endringstidspunkt_nanos BIGINT NOT NULL ); CREATE INDEX idx_vedt...
true
b6a03e36d043150f672224a7acd0fabdbb1b2c0b
SQL
kimothokamau/sql_zoo
/SELECT_select.sql
UTF-8
3,153
4.71875
5
[ "MIT" ]
permissive
-- List each country name where the population is larger than that of 'Russia'. SELECT name FROM world WHERE population > (SELECT population FROM world WHERE name='Russia') -- Show the countries in Europe with a per capita GDP greater than 'United Kingdom'. SELECT name FROM world WHERE continent = 'EUROP...
true
9360a5a6cbf9c7db72c4bde4a602ab70d299716d
SQL
mAminl/HWs
/AP-HW3/backend/create.sql
UTF-8
3,813
3.9375
4
[]
no_license
#create User: CREATE TABLE "User" ( id SERIAL PRIMARY KEY, telegram_id VARCHAR(255) NOT NULL, phone VARCHAR(11) NOT NULL, email VARCHAR(255) NOT NULL, password VARCHAR(255) NOT NULL, first_name VARCHAR(30) NOT NULL, last_name VARCHAR(30) NOT NULL, verification_code VARCHAR(10) NOT NULL, profile_picture_url TE...
true
da1d7ec90904cce2fba4bb51196e8fc4b4dc09ac
SQL
Blackshirt99/1902
/1902/db/oracle/wifi.sql
UTF-8
2,794
3.84375
4
[]
no_license
create table student (id number primary key, name varchar2(20), score number(3), constraint ck_score check (score between 0 and 100), gender char(1 char) default '็”ท' check(gender in ('็”ท','ๅฅณ')) ); insert into student values(1,'wang',1,'ๅฅณ'); drop table student; / --PL/SQL set SERveroutput on; begin -- dbms_output.p...
true
5492e3b9b649762449908f7095ba466be865fa8f
SQL
Dipranil/test
/minipro.sql
UTF-8
7,656
3.171875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.0.4.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Nov 02, 2015 at 11:42 AM -- Server version: 5.5.32 -- PHP Version: 5.4.16 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */...
true
9c3b8033c10701963a403c49f7125328017a8cff
SQL
Nero951/tempFile
/mybatis-study/lib/init.sql
UTF-8
2,318
3.734375
4
[]
no_license
drop database if exists mybatis_study; create database mybatis_study character set utf8mb4; use mybatis_study; drop table if exists user; create table user ( id int primary key auto_increment, username varchar(20) not null unique comment '่ดฆๅท', password varchar(20) not null comment...
true
41e1cc501666fa6706018f5a2d5f298eaa24ddb5
SQL
eaudeweb/art17-2006
/article17/speciessummary/details/select_species_countries.sql
UTF-8
442
2.75
3
[]
no_license
-- Z SQL Method -- /article17/speciessummary/details/select_species_countries <params>region assesment_speciesname</params> SELECT etc_data_species_regions.eu_country_code, etc_data_species_regions.code, etc_data_species_regions.conclusion_assessment, etc_data_species_regions.region FROM etc_data_species_re...
true
a6852d819af42ee07f8c07520134b4de7796a9bd
SQL
muhammadrefaat91/agrimarket_gp_iti
/AgriMarket_v2.2/src/main/resources/agrimarket_data_dump.sql
UTF-8
17,643
3.078125
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.9, for Win64 (x86_64) -- -- Host: localhost Database: agrimarket_schema -- ------------------------------------------------------ -- Server version 5.0.51b-community-nt /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARAC...
true
c98bc3cbbdc53abe8e801476eec044709a143eea
SQL
radtek/abs3
/sql/mmfo/bars/Procedure/p_job_regkkforbk.sql
UTF-8
3,267
2.984375
3
[]
no_license
PROMPT ===================================================================================== PROMPT *** Run *** ========== Scripts /Sql/BARS/Procedure/P_JOB_REGKKFORBK.sql =========*** PROMPT ===================================================================================== PROMPT *** Create procedure...
true
3cc117d9ae821e369dfd120e230225b530a0f8d9
SQL
phac-nml/ngstar
/MySQLWorkbench/PopulateDatabaseStatements/NGSTAR_schema.sql
UTF-8
9,691
3.609375
4
[ "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0; SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0; SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES'; CREATE SCHEMA IF NOT EXISTS `NGSTAR` DEFAULT CHARACTER SET utf8 ; USE `NGSTAR` ; -- -------------------------------...
true
a1c20b88b151904f2c9d517ae10ade4c2f5a4f77
SQL
borbuevbeksultan/wallet
/server/src/main/resources/db/migration/V1__zero_migration.sql
UTF-8
368
3.359375
3
[]
no_license
CREATE TABLE user ( id int AUTO_INCREMENT PRIMARY KEY, email varchar(255) ); CREATE TABLE wallet ( id int AUTO_INCREMENT PRIMARY KEY, user int, FOREIGN KEY (user) REFERENCES user(id) ); CREATE TABLE balance ( id int AUTO_INCREMENT PRIMARY KEY, wallet int, amount decimal(19, 9), currency varchar(55),...
true
41f050263036a29fcc1779c3e6736a78321d3870
SQL
javascripto/sql
/04-select-like-not-like-limit.sql
UTF-8
1,146
4.125
4
[]
no_license
-- SELECT LIKE, NOT LIME, LIMIT, TOP, NUMROW use db_socios; -- Buscar pessoas que o nome comeรงe com 'a' select * from socios where nome like 'a%'; -- Buscar pessoas que o nome NรƒO comeรงe com 'a' select * from socios where nome not like 'a%'; -- Buscar pessoas que o nome comeรงe com tenham -- o nome 'garcia' em qualqu...
true
3b24ab9749ad0c3e13aaa6222b41cc9ea9ee4d82
SQL
sangjiexun/limsproduct2
/limsproduct/src/main/resources/db/migration/V20190507_1.0__proc_insert_attendance.sql
UTF-8
6,884
3.90625
4
[]
no_license
-- ๅ†™ๅ…ฅๅนถๆ›ดๆ–ฐtimetable_attendanceๆ•ฐๆฎ -- ้™ˆไนไธบ 2019ๅนด5ๆœˆ7ๆ—ฅ DROP PROCEDURE if exists `proc_insert_attendance`; DELIMITER ;; CREATE DEFINER=`root`@`localhost` PROCEDURE `proc_insert_attendance`(IN `term_id` int) BEGIN DELETE FROM timetable_attendance WHERE timetable_attendance.term_id=term_id AND timetable_attendance.actual_atten...
true
8694d7cf6b187e6be32a511f4a1d24eee0a7b6b4
SQL
jthaarmann/automation-appetite
/rest-services/src/main/resources/db/sql/create-db.sql
UTF-8
980
3.28125
3
[]
no_license
CREATE TABLE account ( id INT NOT NULL, name VARCHAR(50) NOT NULL, description VARCHAR(50) NOT NULL, PRIMARY KEY (id) ); CREATE TABLE DAY ( ID INT NOT NULL, ABBREVIATION VARCHAR(50) NOT NULL, NAME VARCHAR(50) NOT NULL, PRIMARY KEY (id) ); CREATE TABLE FOOD_GROUP ( NAME VARCHAR(50) NOT NUL...
true
fcb3a54b57475f65341dfda776ffd6841433f0b1
SQL
makendensetu/server_side
/prisma/migrations/20210925160940_/migration.sql
UTF-8
712
2.984375
3
[]
no_license
/* Warnings: - The primary key for the `Post` table will be changed. If it partially fails, the table could be left without primary key constraint. */ -- RedefineTables PRAGMA foreign_keys=OFF; CREATE TABLE "new_Post" ( "id" TEXT NOT NULL PRIMARY KEY, "createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAM...
true
5567361880df326caaa391d1187147af705d0ec8
SQL
carlos-sierra/cscripts
/cs_spch_first_rows.sql
UTF-8
2,849
2.53125
3
[]
no_license
---------------------------------------------------------------------------------------- -- -- File name: cs_spch_first_rows.sql -- -- Purpose: Create a SQL Patch with FIRST_ROWS for given SQL_ID, and drops SQL Profile and SQL Plan Baselines -- -- Author: Carlos Sierra -- -- Version: 2023/04/27 -- -- Usa...
true
ee174fddcc0c256b9cc323a8042f04cad7272ae4
SQL
smk-141510191/141510191-Ujikomm
/ujikomm.sql
UTF-8
14,838
2.78125
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.6.4 -- https://www.phpmyadmin.net/ -- -- Host: localhost:3306 -- Generation Time: Feb 23, 2017 at 08:04 AM -- Server version: 10.1.19-MariaDB -- PHP Version: 7.0.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER...
true
0d9de4202553569b52eb5cc96f82cbfee7b810de
SQL
jbballesteros/SQL_Zeuss
/2016/05 - Mayo/BONIFICACIONES2.sql
UTF-8
1,176
4.4375
4
[]
no_license
SELECT *,CASE WHEN FI.GAL_NIT=0 THEN FI.BONIFICACION ELSE (FI.BONIFICACION/FI.GAL_NIT)*FI.GAL_CODIGO END BONIF FROM ( SELECT M.nit,T.nombres,TR.nit NIT_REAL,TR.nombres NOMBRE_NIT,T3.nit CODIGO,T3.nombres NOMBRES_CODIGO, SUM(CASE WHEN MONTH(M.FEC)=5 THEN M.valor ELSE 0 END) BONIFICACION, P.MAYO GAL_CODIGO,S.MAYO GAL...
true
741ee3cc3127019766ccd4433e6a00a69a21d0d1
SQL
rhit-koenignm/csse333_ftc
/api/db_scripts/scripts/functions/12_match_view.sql
UTF-8
246
3.546875
4
[]
no_license
create or replace view match_info as select * from match m left join lateral ( select array ( select team_id from match_competitor mc where match_id = m.id --join team t on t.id = mc.team_id --where match_id = m.id ) as teams ) t on true;
true
ea2a31eadef4e4158d2fecbf6d03bdc3dccd03ce
SQL
rgoro/tp_bd
/generadores/add_stored_procedures.sql
UTF-8
4,761
4.21875
4
[]
no_license
-- TP 1 Bases de Datos 2015 1c -- Autor: Romรกn Gorojovsky, L.U. 530/02 START TRANSACTION; USE `elecciones`; -- Calcula los candidatos que ganaron las elecciones transcurridas en el ultimo anyo -- La subquery hace el join natural de todas las tablas necesarias, agrupa y ordena -- Aprovechando esto la query externa to...
true
ecfdd5ef784d5ae638579458d6d6ca550d58c435
SQL
Sarcross/finline
/src/main/sql/dbSetup.sql
UTF-8
616
3.734375
4
[]
no_license
CREATE DATABASE finline; USE finline; CREATE TABLE Users( ID INT NOT NULL AUTO_INCREMENT, PRIMARY KEY (ID) ); CREATE TABLE Accounts( ID INT NOT NULL AUTO_INCREMENT, UserID INT NOT NULL, Name VARCHAR(255) NOT NULL, Balance DECIMAL (18, 2) NOT NULL, PRIMARY KEY (ID), FOREIGN KEY (UserID...
true
7303c0303e8a65b3b2505b9410b201021bf4ef83
SQL
cdesmarais/WebDB-Test
/WebDB/StoredProcedures/Common/dbo.DNUsersFavoritesMarkAsMigrated.PRC
UTF-8
1,004
3.75
4
[]
no_license
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[DNUsersFavoritesMarkAsMigrated]') and OBJECTPROPERTY(id, N'IsProcedure') = 1) drop procedure [dbo].[DNUsersFavoritesMarkAsMigrated] GO CREATE Procedure dbo.DNUsersFavoritesMarkAsMigrated( @GlobalPersonIds nvarchar(4000) ) AS SET NOCOUNT ON SET TRA...
true
b9b7163baa46405a086c7ffe36295b5ee7b15818
SQL
cckmit/xinfu
/ccms/WebContent/WEB-INF/action/project/fitness/wx/market/index/getnum/ptrest_query.sql
UTF-8
209
2.90625
3
[]
no_license
select count(1) as baomingnum from cc_market_campaign_enroll e inner join cc_market_campaign m on m.code=e.campaigncode and m.status=1 and m.campaigntype=3 and m.org_id=${def:org} where e.org_id=${def:org}
true
b949595b17e65aee829c3ac77ff4e796e718f98a
SQL
pyrojd/Pokemon-Team-Builder
/Pokemon Team Builder/SQL/Pokemon Query.sql
UTF-8
1,403
3.140625
3
[]
no_license
create table Pokemon( ID INT NOT NULL, Name varchar(15) NOT NULL, Type1 varchar(10) NOT NULL, Type2 varchar(10), primary key (ID) ); create table Items( Item_ID int not null, Item_Name varchar(50) not null, Item_Desciption varchar(250) not null, primary key (Item_ID) ); create tab...
true
400dda582490422d71bb00f8d2c9921f91216429
SQL
supadhyaya/IB
/transformation/answer_Trans.sql
UTF-8
621
3.6875
4
[]
no_license
use socialvoyce; create table if not exists answer ( votingID integer not null , answerText varchar(1000), answerID char(24), votes int, jobDate datetime ); UPDATE answer INNER JOIN scrubAnswer ON answer.answerID = scrubAnswer.answerID set answer.votes=scrubAnswer.votes; insert into answer( votingID, answerText, ...
true
833f852b7c3f32321c17b383b76f3fb232053bbf
SQL
luizasenna/PintosQueries
/2018-09 - AD - Notas Baixas.sql
UTF-8
7,626
3.890625
4
[]
no_license
create temporary table notas_temp_todas (index PARTICIPANTE(PARTICIPANTE), index CODPESSOA(CODPESSOA)) select N.CODITEMAVAL AS ITEM, S.NOME AS NOMECOMPETENCIA, NOTAAVALIADOR AS NOTAAVALIADOR, P.CHAPAAVALIADO AS CHAPA, N.CODAVALIACAO ...
true
3d73264bf99f8e1c669c09c9912eee887c78f24b
SQL
DEvans3/CodeSharingWebsite
/SQL Scripts/setup.sql
UTF-8
1,233
3.703125
4
[]
no_license
DROP DATABASE IF EXISTS webserverdatabase; CREATE DATABASE webserverdatabase; use webserverdatabase; CREATE TABLE users ( id int NOT NULL AUTO_INCREMENT, uname varchar(20) UNIQUE NOT NULL, passwd varchar(64) NOT NULL, email varchar(64) UNIQUE NOT NULL, ts timestamp DEFAULT CURRENT_TIMESTAMP...
true
8dbb54c3151d68ddd3078808b93b77bcb9775b29
SQL
1Chava/unicourse
/base.sql
UTF-8
7,868
3.21875
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.21, for Win32 (AMD64) -- -- Host: localhost Database: unicourse -- ------------------------------------------------------ -- Server version 5.7.21-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */...
true
450e1beac3cc3158349fa1b7b51908ad50058a2c
SQL
MahdiyarTaghavi/miniature-system
/IMDB Create Tables.sql
UTF-8
4,987
3.8125
4
[]
no_license
create table "user" ( uid INTEGER NOT NULL, name CHARACTER VARYING(30), photo oid, primary key (uid) ) create table "login" ( uid INTEGER NOT NULL, username CHARACTER VARYING(30), password CHARACTER VARYING(30), primary key (uid), foreign key (uid) REFERENCES "user" (uid) ) create table "visit" ( u...
true
635babbbb821ee4cb654e8140c8ba8683d989fee
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/low/day18/select2200.sql
UTF-8
178
2.640625
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-17T22:00:00Z' AND timestamp<'2017-11-18T22:00:00Z' AND temperature>=11 AND temperature<=33
true
af3a7ce8f981fd42a353f53c7386b05b42884570
SQL
ramachandrann/message-db
/demo-db.sql
UTF-8
2,364
3.40625
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 5.7.17-log - MySQL Community Server (GPL) -- Server OS: Win64 -- HeidiSQL Version: 9.3.0.4984 -- --------------------------------------------------------...
true
47dd8610b81ee5761ecc9f8664a38e3220ffe13e
SQL
wabp/dba
/oracle/abf/wfanalyze.sql
UTF-8
217,047
2.90625
3
[]
no_license
REM HEADER REM $Header: workflow_analyzer.sql v4.06 BBURBAGE $ REM REM MODIFICATION LOG: REM REM BBURBAGE REM REM Consolidated script to diagnose the current status and footprint of workflow on an environment. REM This script can be run on 11.5.x or higher. REM REM workflow_analyzer.sql REM REM Th...
true
867f244bfed75db32abaf4f89ab95eaff8243b91
SQL
kikicat-meows/aA_Classwork
/W5D3/aa_questions/import_db.sql
UTF-8
2,508
4.28125
4
[]
no_license
PRAGMA foreign_keys = ON; /*REMEMBER THE SEMICOLON!!*/ /*NO TRAILING COMMAS!!*/ DROP TABLE IF EXISTS question_follows; DROP TABLE IF EXISTS question_likes; DROP TABLE IF EXISTS replies; DROP TABLE IF EXISTS questions; DROP TABLE IF EXISTS users; CREATE TABLE users ( id INTEGER PRIMARY KEY, fname VARCHA...
true
1afda075cffd74d52e86731d840688dc195ad0a1
SQL
JeffreyGallegosCoding/data-design
/sql/oml.sql
UTF-8
1,125
2.84375
3
[ "Apache-2.0" ]
permissive
insert into account(accountId, accountEmail, accountHash) values (unhex("1a6e8ac0d8a7402580e6ddadb18fc7f1"), "gamer@george.com", "password"); insert into product(productId, productPrice, productDetails) values (unhex("7d15be8e8a1a434c93a797ee6ecd969c"), "20", "Bloodborne"); insert into cart(cartId, cartAccountId, car...
true
3ee6dd72a9c71795f04f9f26ecf9d92d96bccadb
SQL
Maev4l/celsus-contacts
/tests/scripts/contact.sql
UTF-8
1,220
3.078125
3
[]
no_license
CREATE TABLE IF NOT EXISTS "contact" ( id VARCHAR(36) NOT NULL, user_id VARCHAR(36) NOT NULL, nickname VARCHAR(100) NOT NULL, thumbnail TEXT, CONSTRAINT contact_id_key UNIQUE (id) ) WITH ( OIDS = FALSE ) TABLESPACE pg_default; -- for test update INSERT INTO "contact" ("id", "user_id", "nickname...
true
dccd6272bb3477b7fc89aecd1adf4bbe11cbc6c0
SQL
irmasftri/Tubes-Basdat
/BASDAT/TUBES-PBO-master/DataBase/smiati_update.sql
UTF-8
3,550
3.140625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: May 02, 2019 at 01:21 PM -- Server version: 10.1.9-MariaDB -- PHP Version: 7.0.0 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIE...
true
0d4c6f9863b792997f45bd4186eac70155ad6f5f
SQL
Seas-dev/Coding-Dojo-Work
/MySQL/sample databases/twitter.sql
UTF-8
96
2.78125
3
[]
no_license
select region, count(id) as countries from countries group by region order by count(id) desc;
true
fd52877c1232e4a829563bb68eac5509cfa099cf
SQL
eltonmesquita87/test
/jose-typescript-nodejs-authentication/sql/schedule/billing_center/27-Error QUEUE PolicySystem.sql
UTF-8
122
2.609375
3
[]
no_license
select distinct m.payload, m.ErrorDescription from bc_message m where destinationid = 32 and errordescription is not null
true
2e644527c4b4c44279e9d41b3bcca53cae915539
SQL
eduardo-villasboas/transaction-manager
/src/main/resources/db/changelog/scripts/2020-11-07_CREATE_ACCOUNT_TABLE.sql
UTF-8
382
2.953125
3
[]
no_license
--liquibase formatted sql --changeset eduardo-villasboas:2020-11-07_01 author:eduardo-villasboas CREATE TABLE account ( account_id UUID NOT NULL, document_number BIGINT NOT NULL, CONSTRAINT account_pkey PRIMARY KEY (account_id) ); CREATE UNIQUE INDEX account_account_id_index ON account(account_id); --rollback DROP i...
true
3cdd6b7c8c931c2798b7edd21b65b9d54ee1f1a5
SQL
7aske/uni
/se321/se321-pz-nikola_tasic_3698/ddl/rzp.ddl
UTF-8
6,390
3.671875
4
[]
no_license
#create database if not exists `rzp-database`; #use `rzp-database`; # #create user if not exists 'rzp-root'@'localhost' identified by 'rzp-root'; #grant all on `rzp-database`.* to 'rzp-root'@'localhost'; set foreign_key_checks = 0; drop table if exists `category`; create table `category` ( `category_id` in...
true
d830c36d1c73dcb9c41662ca028b99a062ae5c5b
SQL
mateoqac/raktv
/db/structure.sql
UTF-8
7,982
3.265625
3
[]
no_license
SET statement_timeout = 0; SET lock_timeout = 0; SET idle_in_transaction_session_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; SELECT pg_catalog.set_config('search_path', '', false); SET check_function_bodies = false; SET xmloption = content; SET client_min_messages = warning; SET row...
true
88b1aa5465223225c3923a78e42f231c200f6664
SQL
agzsoftsi/holbertonschool-web_back_end
/0x0C-MySQL_Advanced/5-valid_email.sql
UTF-8
299
3.4375
3
[]
no_license
-- Task 5: Email validation to sent - creates a trigger that resets the attribute valid_email -- only when the email has been changed DELIMITER | CREATE TRIGGER email_bool BEFORE UPDATE ON users FOR EACH ROW BEGIN IF NEW.email <> OLD.email THEN SET NEW.valid_email = 0; END IF; END; |
true
267ea2d08825e1fa1bc658847a020ed465d9775a
SQL
orbs-network/marvin
/docker/mysql/cre-events.sql
UTF-8
567
2.515625
3
[]
no_license
CREATE TABLE `events` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `event_start` datetime NOT NULL, `event_end` datetime DEFAULT NULL, `vchain` varchar(50) DEFAULT '', `description` varchar(200) DEFAULT '', `tag1` varchar(16) ...
true
267d44e6993c78c8fb1f6af4164264f7a16a782c
SQL
ComptonMSHI/hcris-mssql
/validation-counts.sql
UTF-8
2,347
2.859375
3
[ "MIT" ]
permissive
/* hosp10 RECORD COUNTS BY YEAR FOR THE QUARTER ENDING 2018-03-31 [hosp10.hosp10] FY RPT count ALPHA count NMRC count 2010 2322 1347622 7397272 2011 6150 3534353 19341879 2012 6227 3594970 19687768 2013 6248 3664554 19907610 2014 6247 3659511 1980978...
true
6d35758332b2a89e93efc1ecc350b22e83a0d554
SQL
soniakshay/online-mobile-reparing
/project.sql
UTF-8
6,997
2.921875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Feb 05, 2016 at 03:06 AM -- Server version: 10.1.9-MariaDB -- PHP Version: 5.6.15 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLI...
true
6494defe24041e0d67662abb7406d208ce48d853
SQL
nisarg291/Training-Aug-21
/SQL/chirag/day 5/day 5(queries).sql
UTF-8
1,881
4.15625
4
[]
no_license
/*SELECT * FROM Employees create table Incentive ( Incentives_ID int, Incentives_Date date, Incentives_Amount int, EmployeeID decimal(6,0) cONstraint fk foreign key references Employees(EmployeeID) ) create table Manager ( ManagerID decimal(6,0), ManagerName varchar(23) ) Insert into manager values('100','karan') I...
true
b38fad7ac42591daf45b62b11e6b006b009d88de
SQL
jm-park/sql
/[Where]595_Big Countries.sql
UTF-8
269
3.125
3
[]
no_license
# [LeetCode] 595. Big Countries # https://leetcode.com/problems/big-countries/solution/ # it has an area of bigger than 3 million square km or a population of more than 25 million. SELECT name, population, area FROM World WHERE area > 3000000 OR population > 25000000
true
86f3101b37e6517ad6644e18de0866cded1c6b3c
SQL
a-bemporad/Astrid-Alejandra
/semana16/exerciciosSQL/Actor.sql
UTF-8
1,565
3.703125
4
[]
no_license
CREATE TABLE Actor ( id VARCHAR(255) PRIMARY KEY, name VARCHAR(255) NOT NULL, salary FLOAT NOT NULL, birth_date DATE NOT NULL, gender VARCHAR(6) NOT NULL ); INSERT INTO Actor (id, name, salary, birth_date, gender) VALUES("001", "Tony Ramos" ,400000, "1948-08-25", "male"); INSERT INTO Actor (id, name, salary, birth_da...
true