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
b23051a1033183237660d4aa681aa65f5b4cf229
SQL
msyatlaus/employee-management-system
/employeeTracker.sql
UTF-8
2,517
3.75
4
[]
no_license
DROP DATABASE IF EXISTS employeeTracker_db; CREATE DATABASE employeeTracker_db; USE employeeTracker_db; CREATE TABLE department ( id INT NOT NULL AUTO_INCREMENT, department_name VARCHAR (30), PRIMARY KEY (id) ); CREATE TABLE employeeRole ( id INT NOT NULL AUTO_INCREMENT, title VARCHAR (30), salary INT (...
true
f7461554d9de061caede05d9315d9b1394671dc1
SQL
PaladinAn/MySQL-Note
/基本.sql
UTF-8
1,969
4.0625
4
[]
no_license
/*基礎查詢 SELECT 查詢列表(表中的字串、常數、數學表達式、函數) FROM表名 */ /*查詢表中單個字串*/ SELECT last_name FROM employees; /*查詢表中多個字串*/ SELECT last_name,salary,email FROM employees; /*查詢表中所有字串*/ SELECT * FROM employees; /*查詢常數*/ SELECT 100; SELECT 'john'; /*查詢表達式*/ SELECT 100*98; /*查詢函數*/ /*取該函數的返回值,並顯示*/ SELECT version(); /*取名 1. 便於理解 2. ...
true
3375f66963774a3e66cdb4487516e7f5c56e78d2
SQL
keos2017/PLSQL_EJ
/cursor Explicito/cursorExplicitoConFor.sql
UTF-8
949
3.59375
4
[]
no_license
DECLARE CURSOR c_major IS SELECT DISTINCT major FROM students WHERE major = 'Computer Science'; CURSOR c_students(p_major students.major%type) IS SELECT id, first_name, last_name, current_credits FROM students WHERE major = p_major FOR UPDATE NOWAIT; BEGIN FOR r_major IN c_m...
true
b3cfbe432ac567d9ff78c52f3ced1f386b23efe5
SQL
chrc/permisdevote
/sql/schema.sql
UTF-8
5,554
4.09375
4
[]
no_license
create table CandidacyJPA ( id varchar(255) not null, nbCandidates integer not null, candidate1_id varchar(255), primary key (id) ); create table CandidacyJPA_CandidateJPA ( CandidacyJPA_id varchar(255) not null, candidates_id varchar(255) not null, ...
true
a4b06f9de285228c10b54f59f37f4e39c5dba4cb
SQL
WagnerPrata/BancoDeDadosI
/Resposta dos Laboratorios /Lab05.sql
ISO-8859-1
3,684
3.5625
4
[]
no_license
-- Script para os Labs 05 e 05.1 -- Objetivo: Criao do Esquema de Locadora de DVDs -- 1) Criao do Esquema --DROP TABLE TB_ALUGUEL --DROP TABLE TB_DVD --DROP TABLE TB_CATEGORIA --DROP TABLE TB_USUARIO CREATE TABLE TB_USUARIO ( cd_usuario int not null, nm_usuario varchar(50) not null, dt_cadastro da...
true
fa48ec69841f26b9165bd78fc2607a4df7f9ea4b
SQL
tarun-nagpal-github/gobind
/installer/data/database.sql
UTF-8
8,533
3.265625
3
[]
no_license
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET...
true
9f16029f94d8b17992a0b3ee1ff27cd2d37f17f3
SQL
toddcoulson/feithTimeManagement
/sql/getTmProjectRoles.sql
UTF-8
422
2.6875
3
[]
no_license
SELECT ROLE_ID, rpl.PHASE_ID, HOURLY_RATE, NEGOTIATED, ROLE_HOURS, ROLE_BUDGET, proj.project_name, pi.phase_name FROM fdd.tm2_role_project_lookup rpl INNER JOIN fdd.tm2_phase_item pi ON rpl.phase_id = pi.phase_id INNER JOIN fdd.tm2_project_item proj ON pi.project_id = proj.project_id WHERE {proj_id} = proj.project_id O...
true
16093ae38bb52d90452a2308e15493e8587c66ab
SQL
felipesdias/Extractor-URI-Online-Judge
/URI-PT/SQL/2616 - Nenhuma Locação.sql
UTF-8
288
3.15625
3
[]
no_license
-- Autor: Felipe Souza Dias<felipe.s.dias@outlook.com> -- Nome: Nenhuma Locação -- Nível: 1 -- Categoria: SQL -- URL: https://www.urionlinejudge.com.br/judge/pt/problems/view/2616 select c.id, c.name from customers c left join locations l on c.id = l.id_customers where l.locations_date is null order by c.id
true
28703eab60e9b80a9393d115108bb0350b1c8057
SQL
SzymoRatajczak/DataBase-cryptography
/cryptodb/SQL/local_key_store.sql
UTF-8
188
2.5625
3
[]
no_license
CREATE TABLE local_key_store ( key_id INTEGER PRIMARY KEY AUTO_INCREMENT, key_data VARCHAR(32), --encrypted bits of key-- kek_id INTEGER --says what key was used to encrypt key-- );
true
44377999037c0d655b4de3f4c7070554b1aaa2f4
SQL
teitei-tk/Tree-Structure
/path_enumeration/search.sql
UTF-8
288
2.640625
3
[ "Apache-2.0" ]
permissive
SELECT pe.*, CONCAT(pe.path, "%") as LikeQuery FROM path_enumeration AS pe WHERE "1/5/6/8" LIKE CONCAT(pe.path, "%"); -- SELECT -- pe.*, -- CONCAT("1/5/", "%") AS LikeQuery -- FROM -- path_enumeration AS pe -- WHERE -- pe.path LIKE CONCAT("1/5/", "%"); --
true
eb65d96de10ef39d69f1056407a0f9a4a62fae5c
SQL
barbalex/apf2
/sql/apflora/one_offs/2023-04-19_qk_tpopAbperNichtRelevantOhneGrund.sql
UTF-8
333
2.625
3
[ "ISC" ]
permissive
UPDATE apflora.qk SET sort = sort + 1 WHERE sort > 70; INSERT INTO apflora.qk(name, titel, sort) VALUES ('tpopAbperNichtRelevantOhneGrund', 'Teilpopulation, für AP-Bericht nicht relevant, ohne Begründung', 71); INSERT INTO apflora.apqk(ap_id, qk_name) SELECT id, 'tpopAbperNichtRelevantOhneGrund' FROM ap...
true
aa0a5d79e22a1ab1311dff6844565192d5492138
SQL
gsilvadoliveira/REU_Summer2016
/ConTest files/100_90.sql
UTF-8
3,543
2.75
3
[]
no_license
SELECT COUNT(mid) FROM casts; SELECT COUNT(mid) FROM movie_directors; SELECT COUNT(mid) FROM movie_directors; SELECT COUNT(did) FROM movie_directors; SELECT COUNT(pid) FROM casts; SELECT COUNT(fname) FROM actor; SELECT COUNT(fname) FROM actor; SELECT COUNT(mid) FROM casts; UPDATE genre SET genre = 'News' WHERE genre = ...
true
65e9541df3dad192019aa538345aaf23a4065e8c
SQL
PengInGitHub/SQL-Tutorial-W3School
/union_where.sql
UTF-8
122
2.828125
3
[]
no_license
SELECT City FROM Custoemrs WHERE Country='Germany' UNION SELECT City FROM Suppliers WHERE Country='Germany' ORDER BY City;
true
9bc9e585c717526cbf30b2a3d3f42d78394d3b68
SQL
gaoshangguo/ditu
/PostGis.ODAL/DBScript/db.sql
UTF-8
490
2.859375
3
[]
no_license
--this script need run in oracle 12c --Tablespace create tablespace postgis datafile 'D:\app\Administrator\oradata\orcl\postgis01.dbf' size 1000M autoextend on; -- USER SQL Create USER postgis IDENTIFIED BY password DEFAULT TABLESPACE "POSTGIS" TEMPORARY TABLESPACE "TEMP" ACCOUNT UNLOCK ; -- ROLES GRAN...
true
9ceef3722a24e931e707100c2df77a035ebdbffa
SQL
kranthi003/Lib_Pers
/transaction/common/Database/P2a/FX_PT_AUDIT_TRAIL.sql
UTF-8
2,669
3.421875
3
[]
no_license
/*==============================================================*/ /* DBMS name: ORACLE Version 10g */ /* Created on: 8/3/2011 8:21:03 PM */ /*==============================================================*/ /*==========================================...
true
995440ec28b1a5e1c6838ef4881fd9ddf3b1dcbf
SQL
dmesitov/OK_test_problems
/ok_sobes.sql
UTF-8
1,174
3.96875
4
[]
no_license
--Посчитать по-дневное количество просмотров видео, аудиторию сервиса и количество различных видео-роликов, просмотренных в этот день. select date, count(user_id) as daily_views, count(distinct user_id) as daily_uniq, count(distinct video_id) as videos_viewed from video group by date --Найти в...
true
259d70145072affe4e42d4113c2dc4cb585de10b
SQL
aazmuhammadnoor/e-register
/sql/azhar_perubahan/t_permohonan_lingkungan.sql
UTF-8
1,497
3.140625
3
[]
no_license
/* Navicat Premium Data Transfer Source Server : localhost_3306 Source Server Type : MySQL Source Server Version : 100137 Source Host : localhost:3306 Source Schema : palembang_fix Target Server Type : MySQL Target Server Version : 100137 File Encoding : 65001 Date: ...
true
324ff3d96f1471973cb66efd69761d9cbde1f633
SQL
withelm/Algorytmika
/leetcode/database/MSSQL/Ad-Free Sessions/Ad-Free Sessions.sql
UTF-8
343
3.921875
4
[]
no_license
select session_id from Playback where session_id not in ( select session_id from Playback left join Ads on Playback.customer_id = Ads.customer_id where start_time <= timestamp and timestamp <= end_time group by ...
true
838eb8b5171b2e98925c5feb2991b2fafd3b1cab
SQL
xtxiaoteng/Demo
/MyCms/Template/table.sql
UTF-8
2,367
2.59375
3
[ "Apache-2.0" ]
permissive
/* Navicat MySQL Data Transfer Source Server : localhost Source Server Version : 60011 Source Host : localhost:3306 Source Database : kekeblog2 Target Server Type : MYSQL Target Server Version : 60011 File Encoding : 65001 Date: 2015-11-29 02:02:43 */ SET FOREIGN_KE...
true
9d9ecfed1e829427bb28a358e4b3b4a7c79c6d36
SQL
manoel-ats/atsfinanceiro
/script/cancela_estoque_venda.sql
UTF-8
343
2.71875
3
[]
no_license
CREATE OR ALTER TRIGGER CANCELA_ESTOQUE_VENDA FOR VENDA ACTIVE AFTER UPDATE POSITION 0 AS BEGIN IF ((New.STATUS = 14) and (old.STATUS <> 14)) then begin UPDATE MOVIMENTODETALHE SET BAIXA = 3 WHERE CODMOVIMENTO = NEW.CODMOVIMENTO; update RECEBIMENTO rec set rec.STATUS = 14 where rec.CODVENDA = o...
true
d5db7bf3b75e09a2984dff5f1200681f076c0a5c
SQL
siddharthJadhav/CLINIC_MANAGEMENT_SYSTEM
/perfect.sql
UTF-8
2,074
3.359375
3
[]
no_license
create database clinic use clinic select * From Login create table login(name varchar(100)not null,password varchar(100)not null,utype varchar(100)not null,hint varchar(100)) insert into login values('amir','sanas','admin','amir') insert into login values('anand','rajesh','users','anand') insert into login values('ch...
true
518bc03a64cb3bac24d6cca3698acfa7098c2ea1
SQL
mandov/07.Databases
/07.Intro-to-SQL/SQLQuery.sql
WINDOWS-1250
5,119
4.40625
4
[]
no_license
-- 1. Structured Query Language) is a special-purpose programming language designed for managing data -- held in a relational database management system (RDBMS) -- DML is abbreviation of Data Manipulation Language. It is used to retrieve, store, -- modify, delete, insert and update data in database. -- Examples: SELEC...
true
b9b7d272942c5768221c41997f9b5c27d1871c64
SQL
ArturTrautenmuller/Sistema-de-Gestao-Academico
/Final/cadastro.sql
UTF-8
2,875
3.140625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: 09-Dez-2018 às 18:32 -- Versão do servidor: 10.1.36-MariaDB -- versão do PHP: 7.2.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @...
true
d26008533964be146a2bc1eee085f3f7825d966b
SQL
JoseR98/holbertonschool-higher_level_programming
/0x0D-SQL_introduction/103-max_state.sql
UTF-8
190
3.234375
3
[]
no_license
-- 103 Temperatures #2 -- Displays the max temperature of each state (ordered by State name). SELECT state, MAX(value) AS 'max_temp' FROM temperatures GROUP BY state ORDER BY max_temp DESC;
true
33f095b9e3f8811c6328b9fe94aeaa0b2b6037a2
SQL
sagaekakristi/ppla02
/Source Code/backup-important-files/mysql-sql-file/defaultSearchQuery.sql
UTF-8
778
3.921875
4
[]
no_license
select freelancer_info_id, judul, deskripsi, upah_max, upah_min, name, alamat from /* c adalah table yang berisi informasi tentang job dengan judul yang mengandung kata pada input */ (select j.freelancer_info_id, j.judul, j.deskripsi, j.upah_max, j.upah_min from job j where judul like '%web%') as c join /* d ...
true
bcb072ffadcaf5e22053df1568d06479f334c3b4
SQL
haochenprophet/database
/constitute.sql
UTF-8
5,033
3.28125
3
[]
no_license
CREATE DATABASE IF NOT EXISTS `constitute` /*!40100 DEFAULT CHARACTER SET utf8 */; USE `constitute`; -- MySQL dump 10.13 Distrib 8.0.13, for Win64 (x86_64) -- -- Host: localhost Database: constitute -- ------------------------------------------------------ -- Server version 8.0.13-commercial /*!40101 SET @OLD_CHA...
true
e07c99bd78761111af3bffcb091c8f509508b9e0
SQL
maxg/omnivore
/test/db/keys_on_update_delete_stale_current.sql
UTF-8
720
2.859375
3
[ "MIT" ]
permissive
INSERT INTO raw_data VALUES ('alice', 'test.alpha', t(), '0', 'tester'); INSERT INTO current_data VALUES ('alice', 'test.alpha', t(), '0', NULL, 'tester'); SELECT * INTO STRICT result FROM all_data; PERFORM assert(result.username = 'alice', result::TEXT); PERFORM assert(result.key = 'test.alpha', result::TEXT); PERFOR...
true
191d1b8ae32c46d6662310b72c88c1cf1c442138
SQL
israel-viveros/sistema-programacion
/query.sql
UTF-8
959
4.09375
4
[]
no_license
--QUERY FINNAL CON INNER select a.nombre, b.fecha, d.nombre, e.horario from canal a INNER JOIN programacion c ON c.id_canal = a.id_canal INNER JOIN fecha b ON b.id_fecha = c.id_fecha INNER JOIN programacion_contenido f ON c.id_programacion = f.id_programacion INNER JOIN contenido e ON f.id_contenido = e.id_contenido ...
true
42d70f354cc165595323ba62141daac1621b2380
SQL
AmandineYborra/cinemaSQL
/DumpCinema.sql
UTF-8
5,885
2.90625
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.13, for Win64 (x86_64) -- -- Host: localhost Database: cinema -- ------------------------------------------------------ -- Server version 8.0.13 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS *...
true
5f279e92474041e98f8c9680349a3c47b3b2b56d
SQL
BernardoFontes/Projeto-Vocabulary-Booster
/desafio9.sql
UTF-8
250
4.0625
4
[]
no_license
SELECT CONCAT(e.FirstName, ' ', e.LastName) AS 'Nome completo', COUNT(o.OrderID) AS 'Total de pedidos' FROM w3schools.orders AS o INNER JOIN w3schools.employees AS e ON e.EmployeeID = o.EmployeeID GROUP BY `Nome completo` ORDER BY `Total de pedidos`;
true
32e402056f6b55cdd0a477d46f4357b26e1d6470
SQL
quangtran97/BTL-CNWEB
/quanlydiem.sql
UTF-8
6,153
3.0625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.1 -- https://www.phpmyadmin.net/ -- -- Máy chủ: 127.0.0.1 -- Thời gian đã tạo: Th1 09, 2020 lúc 03:34 PM -- Phiên bản máy phục vụ: 10.4.8-MariaDB -- Phiên bản PHP: 7.3.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!...
true
9b3c80b4e084ca470277b45613a18bcaf28cd6c2
SQL
Drei109/Lab02
/Lab02/Lab02/Scripts/Lab02_4.3.01.sql
UTF-8
214
2.609375
3
[]
no_license
---**Ejercicio 1------ CREATE VIEW VW_EMPLEADOS AS SELECT employee_id, first_name, d.department_id FROM employees as e, departments as d WHERE d.department_id = e.department_id; select * from VW_EMPLEADOS;
true
a4ad950377236c187d027ce53b4561aedbf42d0b
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/low/day19/select1621.sql
UTF-8
262
2.90625
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['6219','2228','3234','2216','6042','3026','3062','6013','2100_1','5232'])
true
8a025e131004bd3ff03da344791cbcb0f72452d6
SQL
luisitocaiza17/CrudBasicoPhpGit
/src/database.sql
UTF-8
365
3.171875
3
[]
no_license
/* Create Database and Table */ create database crud_db; use crud_db; CREATE TABLE `users` ( `id` int(11) NOT NULL auto_increment, `name` varchar(100), `email` varchar(100), `mobile` varchar(15), PRIMARY KEY (`id`) ); CREATE USER root2@"%" IDENTIFIED WITH mysql_native_password BY 'root'; GRANT ALL PRIVIL...
true
e38f98565a7c1b5ab4c95021b44e19724ee31aee
SQL
hadipsy27/kape
/database.sql
UTF-8
16,112
2.90625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.1 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Oct 29, 2020 at 04:38 PM -- Server version: 10.4.8-MariaDB -- PHP Version: 7.3.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
f323060e0426e41478230bc2abda43e02e366996
SQL
yeah-union/OnlineTestingPlatform
/sql/create-db.sql
UTF-8
2,359
3.53125
4
[]
no_license
CONNECT 'jdbc:derby://localhost:1527/testingDB;create=true;user=admin;password=test'; DROP TABLE test_results; DROP TABLE answers; DROP TABLE questions; DROP TABLE tests; DROP TABLE users; ---------------------------------------------------------------- -- USERS ---------------------------------------------...
true
c5efd0bdb17cbcee42999ce795c9a406fc85d7d5
SQL
lcapriles/GenDtl
/DB/GD_HM_OD_FAMILIAS_CONSTRAINT.sql
UTF-8
362
2.609375
3
[]
no_license
-------------------------------------------------------- -- Constraints for Table GD_HM_OD_FAMILIAS -------------------------------------------------------- ALTER TABLE "GDCNO"."GD_HM_OD_FAMILIAS" MODIFY ("FAMILIA" NOT NULL ENABLE); ALTER TABLE "GDCNO"."GD_HM_OD_FAMILIAS" ADD CONSTRAINT "GD_HM_OD_FAMILIAS_PK" PRI...
true
06d30319ad563dc6be90c9f5edf112cec7c433c9
SQL
microsoft/ContextualSP
/unified_parser_text_to_sql/third_party/spider/preprocess/parsed_sql_examples.sql
UTF-8
3,914
3.90625
4
[ "MIT", "LicenseRef-scancode-generic-cla", "LicenseRef-scancode-proprietary-license", "LicenseRef-scancode-free-unknown", "LicenseRef-scancode-unknown-license-reference", "LGPL-2.1-or-later", "Apache-2.0", "LicenseRef-scancode-public-domain", "BSD-2-Clause" ]
permissive
################################ # Assumptions: # 1. sql is correct # 2. only table name has alias # 3. only one intersect/union/except # # val: number(float)/string(str)/sql(dict) # col_unit: (agg_id, col_id, isDistinct(bool)) # val_unit: (unit_op, col_unit1, col_unit2) # table_unit: (table_type, col_unit/sql) #...
true
f399436edd1a8e538c08be180bfc1e1cf7cae481
SQL
thanhnhan2tn/NhaTro
/code/ketnoi.sql
UTF-8
716
3.203125
3
[]
no_license
-- insert into groups(group_name, group_detail) values ('admin','admin'); -- insert into users (user_name,user_fullname, user_sdt, user_gioitinh, user_namsinh, group_id) values ('test','nguyanv an a',0909333999,1,1990,1); -- insert into auth(user_id, user_pass) values ('3','test2'); -- select user_pass from auth where...
true
5a5e51a94fa882d064496020c0574c41a7788e4f
SQL
cksgur59/ezenshop
/CSP1/membersql.sql
UTF-8
935
3.203125
3
[]
no_license
drop table member CREATE TABLE member( id VARCHAR2(50) PRIMARY KEY, pw VARCHAR2(100) NOT NULL, name VARCHAR2(30) NOT NULL, gender VARCHAR2(10) NOT NULL, email VARCHAR2(100) NOT NULL, address1 VARCHAR2(300) NOT NULL, address2 VARCHAR2(300) NOT NULL, address3 VARCHAR2(300) NOT NULL, phone VARCHAR2(100) NOT NULL, admin ...
true
2678df9a78f1a5ef673565b0f7c83358c9bf95cb
SQL
EIVSoftware/java-design-patterns
/id-generation/src/main/resources/script-mssql.sql
UTF-8
684
4.0625
4
[]
no_license
CREATE TABLE provincias ( id bigint NOT NULL, nombre varchar(100) NOT NULL ); ALTER TABLE provincias ADD CONSTRAINT PK_provincias PRIMARY KEY (id); ------------------------ CREATE TABLE localidades ( id bigint NOT NULL, nombre varchar(100) NOT NULL, provincia_id bigint NOT NULL ); ALTER TABLE l...
true
9827facfb78b377a6ee343474bbe2c04ac98cf08
SQL
pleacu/jbosstools-integration-stack-tests
/tests/org.jboss.tools.teiid.ui.bot.test/resources/ddl/sqlserver_parts.ddl
UTF-8
710
2.875
3
[]
no_license
CREATE TABLE PARTS ( PART_ID VARCHAR(50) NOT NULL, PART_NAME VARCHAR(255), PART_COLOR VARCHAR(30), PART_WEIGHT VARCHAR(255) ) GO CREATE TABLE SHIP_VIA ( SHIPPER_ID DECIMAL(2) NOT NULL, SHIPPER_NAME VARCHAR(30) ) GO CREATE TABLE STATUS ( STATUS_ID DECIMAL(2) NOT NULL, STATUS_NA...
true
454e4e3612937780152992cfad62465394b829fa
SQL
IrynaKuzmiankova/James-Monitoring
/Monthly_payments adjusting.sql
UTF-8
2,796
3.9375
4
[]
no_license
select loan.id as Loan_Id, loan.original_loan_application_id as Application_ID ,date_format(now(), '%Y-%m-01') as Reporting_Month ,loan_type.name as Type_of_Loan /* max outstanding principal is used in order to show principal before payment (so always the first payment of the month is chosen) */ ...
true
de5c6e7f2777e6d7a2a0e011a3616fae04a3f278
SQL
jayaddison/autochef
/dbs/autochef/functions/utils/unnest.sql
UTF-8
188
2.53125
3
[]
no_license
create or replace function unnest(anyarray) returns setof anyelement as ' select $1[i] from generate_series(array_lower($1, 1), array_upper($1, 1)) as i; ' language sql immutable;
true
c2f941ae6a4723ec5d84e0d3cf57d972fb3f3ea2
SQL
samyan19/SQL-Scripts
/SAM - KPMG/DB and Cases Including Backup Growth.sql
UTF-8
1,653
3.9375
4
[]
no_license
;WITH a AS( SELECT c.Name AS 'ProjectName' ,d.artifactid AS 'WorkspaceID' ,d.name AS 'DatabaseName' ,create_date ,collation_name ,recovery_model_desc FROM ( SELECT * ,SUBSTRING(name,PATINDEX('%[0-9]%',name),LEN(name)) AS artifactid FROM sys.databases WHERE name LIKE 'EDDS%[0-9]%' ) d JOIN EDDS.eddsdbo.[Case] c...
true
c566b025ef311f702f299e529617144647ee7a05
SQL
joshsoftware/peerly
/go-backend/migrations/1589893448_create_reported_recognitions.up.sql
UTF-8
381
2.9375
3
[ "MIT" ]
permissive
CREATE TABLE reported_recognitions ( id SERIAL PRIMARY KEY NOT NULL UNIQUE, recognition_id integer REFERENCES recognitions(id), type_of_reporting varchar(50), reason_for_reporting TEXT, reported_by INTEGER REFERENCES users(id), reported_at BIGINT, created_at timestamp with time zone NOT NULL default current_t...
true
c2b5b2d05d83039d2f166c7a7f564bc3ff761382
SQL
leosilvadev/EstoqueAdmin
/scripts/Fornecedores_Produtos.sql
UTF-8
3,928
2.640625
3
[]
no_license
/*!40000 ALTER TABLE `fornecedor` DISABLE KEYS */; INSERT INTO `fornecedor` (`id`,`version`,`ativo`,`email`,`empresa_id`,`endereco`,`nome`,`telefone`) VALUES (1,0,1,'orleonmotos@orleonmotos.com.br',1,'R. Gen. Osório, 517, São Paulo - SP, 01213-001','ORLEON - ATACADISTA DE MOTOPEÇAS','(11)32252233'), (2,0,1,'contato@...
true
9cf90337ad8b9f2d127ca73cf0be94eb012dfc43
SQL
jananik1066/Task-Management
/database/task.sql
UTF-8
1,930
3.09375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Mar 28, 2019 at 03:49 PM -- Server version: 5.7.24 -- PHP Version: 7.2.14 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CH...
true
943a279577ff20f2b6ff4bd26c7e2dd83777ba3b
SQL
Emalsha/E-Channeling-System
/Procedures/ACMA_CANCEL_APPOINMENT_AND_VIEW_SINGLE_APPOINEMNT.sql
UTF-8
2,055
4.03125
4
[ "Apache-2.0" ]
permissive
--create type object for store table of records create or replace type acma_app_o as object (app_id number, pat_id varchar2(64), doc_id varchar2(64), cre date, app_d date, app_t varchar2(64), cat varchar2(64), sta number); --store object to table create or replace type acma_app_t is table of acma_app_o; --function to...
true
6e7074ae8bbeae2b540386d3c905821a91107c69
SQL
lftechnologyinc/hack_codejammers
/sql/sumit.sql
UTF-8
2,875
3.328125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.5.1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: May 09, 2013 at 05:12 PM -- Server version: 5.5.31-0ubuntu0.12.04.1 -- PHP Version: 5.4.14-1~precise+1 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=...
true
302d7760d152e79655f3c05d82d32864d741ac24
SQL
cha63506/print-18
/db.sql
UTF-8
8,685
3
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 3.5.7 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Nov 15, 2013 at 05:52 AM -- Server version: 5.5.29 -- PHP Version: 5.4.10 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Database: `print` -- -- --------------------------------------...
true
664b5112b802e30076d8043a8b73079f9a536267
SQL
MikelTozza/PL-SQL
/tp6/Formatif_isbn/Suppression.sql
UTF-8
1,381
3.25
3
[]
no_license
SET SERVEROUTPUT ON SET VERIFY OFF PROMPT *********** Suppression d''une vente ************ ACCEPT codeusager PROMPT "Entrer le code de l'usager: " ACCEPT isbn PROMPT "Entrer l'isbn: " ACCEPT datevente PROMPT "Entrer la date de vente [dd-mm-yy]: " DECLARE varcodeusager listevente.codeusager%TYPE:='&codeusager'; varis...
true
2f17234194eecb3090db601dbc65a4ba85a98e57
SQL
hasadna/OpenTrainCommunity
/train2/create_guest.sql
UTF-8
260
2.671875
3
[]
no_license
CREATE USER guest WITH ENCRYPTED PASSWORD 'guest'; GRANT CONNECT ON DATABASE train2 to guest; \c train2 GRANT USAGE ON SCHEMA public to guest; GRANT SELECT ON ALL SEQUENCES IN SCHEMA public TO guest; GRANT SELECT ON ALL TABLES IN SCHEMA public TO guest;
true
100b7eb6340191cadd4226ad768c0a3c3cb418bb
SQL
AnnaBratucu/semantic-web-XML-PHP
/users.sql
UTF-8
2,020
3.078125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Nov 24, 2019 at 05:15 PM -- Server version: 10.4.6-MariaDB -- PHP Version: 7.3.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
2c7ee261c9509101ffb10171485600ad5241f88f
SQL
siminitchi/tekwill
/lesson8/homework.sql
UTF-8
3,966
3.734375
4
[]
no_license
select last_name ,round(months_between(sysdate,hire_date)) from employees; select last_name ,lpad(salary,10,'$') from employees; select last_name ,lpad(' ',salary/1000,'*') from employees order by 2; select last_name ,round((sysdate-hire_date)/7) tenure from employees ...
true
6b24447a3ee8922fe6aad7526a6ee6d86438fd21
SQL
markgermano/reproduce_lactate_load
/acquire/covariates/main_vars.sql
UTF-8
1,013
3.734375
4
[ "MIT" ]
permissive
SELECT ie.subject_id , ie.hadm_id , ie.stay_id , pt.anchor_age AS age , CASE WHEN pt.gender = 'F' THEN 1 ELSE 0 END AS female , wt.weight_admit AS weight , sof.SOFA AS sofa_score , sap.sapsii AS sapsii_score , DATE_DIFF(adm.dischtime, adm.admittime, DAY) AS length_of_hospital_stay , DATE_DIFF(outtime, intime, DAY) AS l...
true
40e7be669b574bbb471630cc145b1b1f12811245
SQL
bettertony/Octopus
/src/test/regress/sql/pipeline_stats.sql
UTF-8
1,414
2.78125
3
[]
no_license
CREATE DATABASE octopus_stats_db; \c octopus_stats_db CREATE STREAM test_octopus_stats_stream (x int); CREATE CONTINUOUS VIEW test_octopus_stats0 AS SELECT COUNT(*) FROM test_octopus_stats_stream; SELECT pg_sleep(2); SELECT output_rows, errors, cv_create, cv_drop FROM octopus_stats WHERE type = 'combiner'; SELECT inp...
true
a5b08111318734a57519a3be9e065a575dbae746
SQL
cho-iii/yaus
/updategeoip.sql
UTF-8
2,852
3.03125
3
[]
no_license
TRUNCATE geoip2_network; load data infile 'geotmp/GeoIP2-City-Blocks-IPv6-Hex.csv' into table geoip2_network fields terminated by ',' enclosed by '"' lines terminated by '\n' ignore 1 rows (@network_start, @network_end, @geoname_id, @registered_country_geoname_id, @represented_country_geoname_id, @is_anonymous_proxy,...
true
fd50ba9647235b1c44b75171b61cfcbd0c2ee077
SQL
danny6547/VPD5
/ISO 19030/validateFrequencies.sql
UTF-8
7,964
3.390625
3
[]
no_license
/* Check whether data shows that measurement frequencies are sufficient for ISO19030-2 standard. Procedure must be called prior to data being averaged over higher- frequencies or repeated over lower-frequencies. */ DROP PROCEDURE IF EXISTS validateFrequencies; delimiter // CREATE PROCEDURE validateFrequencies(OUT...
true
2db405141cade50d0b6a9f97976af82f264a926e
SQL
akiong/exda-skripsi
/grails-app/conf/sequence.sql
UTF-8
2,447
3.625
4
[]
no_license
-- If "ERROR HY000: This function has none of DETERMINISTIC, NO SQL, or READS SQL DATA in its declaration and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)" -- Run this command as admin, before re-run the script -- SET GLOBAL log_bin_trust_function_creators...
true
2e1d4ab8312cbf574979f4ca2e8ea65eb2094898
SQL
k13jolai/COEN-178-Intro-to-Databases
/hw2/pt2.sql
UTF-8
1,011
3.984375
4
[]
no_license
CREATE OR REPLACE FUNCTION mostMealOrders RETURN CHAR IS ret CHAR(100); custname Customer.name%type; custnumber Customer.phone%type; BEGIN SELECT name INTO custname FROM Customer WHERE acctId IN (SELECT acctId FROM (SELECT acctId, COUNT(menuID) as ORDERS FROM MealOrder GROUP ...
true
6d885c3683a94117a49a5dae4d7348630f0e117a
SQL
ColeNicholson/Database-API-Interaction
/PC_Parts.sql
UTF-8
40,129
3.15625
3
[]
no_license
DROP TABLE IF EXISTS user_; CREATE TABLE IF NOT EXISTS user_ ( ID int NOT NULL AUTO_INCREMENT, email varchar(255) UNIQUE, username varchar(255), fname varchar(255), lname varchar(255), PRIMARY KEY (ID), CHECK (email LIKE '%@%.%') ); DROP TABLE IF EXISTS psu_; CREATE TABLE IF NOT EXISTS ps...
true
eba6bf52113d21a90ecc0a3328ff29e41697b871
SQL
KenAhon/ScrapCT
/.SCHEMAS/2_dw_teccheck.sql
UTF-8
11,458
2.703125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.4.1deb2ubuntu2 -- http://www.phpmyadmin.net -- -- Servidor: localhost -- Tiempo de generación: 01-11-2017 a las 06:35:39 -- Versión del servidor: 5.7.19-0ubuntu0.16.04.1 -- Versión de PHP: 7.0.22-0ubuntu0.16.04.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; ...
true
d8f86dde26b5043c635250b74a6eb463c28273ef
SQL
rkshapiro/myxt-packages
/package_report/dbscripts/tables/CREATE_tbl_impact_teacher.sql
UTF-8
2,518
3.484375
3
[]
no_license
-- Sequence: _report.impact_teacher_impactteacher_id_seq DROP SEQUENCE IF EXISTS _report.impact_teacher_impactteacher_id_seq CASCADE; CREATE SEQUENCE _report.impact_teacher_impactteacher_id_seq INCREMENT 1 MINVALUE 1 MAXVALUE 9223372036854775807 START 2 CACHE 1; ALTER TABLE _report.impact_teacher_impactteac...
true
7ab7865967a22c6aa1b09ffff8c674939d0454a5
SQL
josmatoje/BBDD
/KIT BBDD/Boletines/8/ConsultasBoletin8.1.sql
ISO-8859-1
2,476
4.21875
4
[]
no_license
--BOLETIN 8.1 USE Northwind --1. Nombre del pas y nmero de clientes de cada pas, ordenados alfabticamente por el nombre del pas. SELECT Country, COUNT(*) AS NumberCustomer FROM Customers --WHERE GROUP BY Country ORDER BY Country --2. ID de producto y nmero de unidades vendidas de cada producto. SELECT ProductID,...
true
5ef7ca8929c1962bfdb89f90e0640c6d8054b2a4
SQL
jordicato/i18n-aware-vaadin-addon
/i18n-aware-noticeboard/NoticeBoardDump20130414.sql
UTF-8
6,411
2.765625
3
[]
no_license
CREATE DATABASE IF NOT EXISTS `noticeboard` /*!40100 DEFAULT CHARACTER SET latin1 */; USE `noticeboard`; -- MySQL dump 10.13 Distrib 5.5.28, for debian-linux-gnu (i686) -- -- Host: localhost Database: noticeboard -- ------------------------------------------------------ -- Server version 5.5.28-0ubuntu0.12.04.3 /...
true
470a54b109f8eb890a92241d892b4d5fb337fb7e
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day13/select1444.sql
UTF-8
178
2.65625
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-12T14:44:00Z' AND timestamp<'2017-11-13T14:44:00Z' AND temperature>=31 AND temperature<=83
true
e628795d49ca44d67acb04bfe29063c95a03f74c
SQL
njkevlani/Notice_Board
/Database/notice_board.sql
UTF-8
2,878
3.078125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Apr 12, 2017 at 06:39 PM -- Server version: 10.1.16-MariaDB -- PHP Version: 7.0.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLI...
true
4aea1600e68f519362f64139945f6a740b07d7ae
SQL
snukneLeo/Laboratorio-Basi-Di-Dati
/esami duplicati con diverse soluzioni/esame_20_09_16/20_09_16.sql
UTF-8
3,661
4.375
4
[]
no_license
--ESERCIZIO1 --Si ricorda che: (1) il codice delle autostrade italiane considerate è composto dal carattere ’A’ seguito da un numero. --(2) il codice ISTAT di un comune è una stringa di 6 cifre. (3) l’attributo numeroCaselli indica il numero di caselli --dell’autostrada presenti nel territorio del comune (potrebbe es...
true
ffd4e8e99292c0155f5c70e07e184eb42f688a59
SQL
LabKey/wnprc-modules
/WNPRC_EHR/resources/queries/study/Necropsy Schedule.sql
UTF-8
2,350
3.5
4
[ "Apache-2.0" ]
permissive
/* This query feeds the Necropsy Schedule JSP page/calendar. */ SELECT lsid ,necropsy.taskid ,animalid ,animalid.Demographics.gender AS sex ,animalid.age.ageFriendly AS age ,animalid.mostRecentWeight.mostRecentWeight AS weight ...
true
b24bf984b86bcbcbb8d2950103a66a84e4a6b3b7
SQL
jgarzonext/plsql-testing
/script_plsql/bd_iaxis/script/indices/CONTAB_MANU_DIA_PK.sql
UTF-8
406
2.6875
3
[]
no_license
-------------------------------------------------------- -- DDL for Index CONTAB_MANU_DIA_PK -------------------------------------------------------- CREATE UNIQUE INDEX "AXIS"."CONTAB_MANU_DIA_PK" ON "AXIS"."CONTAB_MANU_DIA" ("CPAIS", "FEFEADM", "CPROCES", "CCUENTA", "NLINEA", "NASIENT", "CEMPRES", "FCONTA", "TDES...
true
17fadc6e70f0c48bfb7720f0a22d81673e0989ad
SQL
fathitarek/projectDemoLaravel5.4
/laravel.sql
UTF-8
11,862
2.890625
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.0.10deb1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Dec 13, 2017 at 07:44 PM -- Server version: 5.5.55-0ubuntu0.14.04.1 -- PHP Version: 5.5.9-1ubuntu4.21 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_C...
true
eb789abfed13c6498ce3da1b93cd5c52da39e0fa
SQL
knureigs/itech
/lb/ITech2_PDO/Additional/lb_pdo_workers.sql
UTF-8
4,671
3.234375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Хост: 127.0.0.1:3306 -- Время создания: Мар 08 2023 г., 21:22 -- Версия сервера: 8.0.15 -- Версия PHP: 7.3.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SE...
true
19710ee1b4812d2fbb2db27609d9dc4559e68c4d
SQL
Leandri-png/Karl
/Oracle SQL Module (Advanced Databases)/Past Test Papers/2018 - 2/Question 1.1.sql
UTF-8
585
3.515625
4
[]
no_license
CREATE TABLE VEHICLE ( VIN CHAR(6) PRIMARY KEY NOT NULL, MANUFACTURER VARCHAR(25) NOT NULL, VEHICLE_MODEL VARCHAR(25) NOT NULL, PRICE DECIMAL(9, 2) NOT NULL ); / CREATE TABLE CUSTOMER ( CUSTOMER_ID CHAR(8) PRIMARY KEY NOT NULL, CUSTOMER_NAME VARCHAR(50) NOT NULL, CUSTOMER_EMAIL VARCHAR(25) NOT NULL ); / CREATE TAB...
true
8d8614b2081ca9958fc7c0fb0efbc9588f742470
SQL
vijaydairyf/TimelyFish
/SolomonApp/dbo/Views/dbo.vXP236PigGroup.sql
UTF-8
695
3.203125
3
[]
no_license
--************************************************************* -- Purpose:Pig Group list based on user parameters -- -- Author: Charity Anderson -- Date: 8/25/2005 -- Usage: Pig Group Verification Screen Pig Group DBNav -- Parms:UnVerifiedFlag, VerifiedFlag,PigGroup --**********************************************...
true
270c3956a94d31f1773b9b1e0c682bf833f96d3a
SQL
srinu2020/sunnona
/database schema and values/sunnona_favourites.sql
UTF-8
2,531
3.078125
3
[ "MIT" ]
permissive
CREATE DATABASE IF NOT EXISTS `sunnona` /*!40100 DEFAULT CHARACTER SET latin1 */; USE `sunnona`; -- MySQL dump 10.13 Distrib 5.7.29, for Linux (x86_64) -- -- Host: localhost Database: sunnona -- ------------------------------------------------------ -- Server version 5.7.29-0ubuntu0.18.04.1 /*!40101 SET @OLD_CHAR...
true
977387149af23dc59f49e3b29c7ebd5d2d5aecb4
SQL
ramasamys/T_Report
/db/project1.sql
UTF-8
1,515
2.890625
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
-- phpMyAdmin SQL Dump -- version 3.5.8.1deb1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Jul 23, 2013 at 12:42 PM -- Server version: 5.5.31-0ubuntu0.13.04.1 -- PHP Version: 5.4.9-4ubuntu2.1 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLI...
true
116a2f5a759f60821a79f379ca1839130715b9ec
SQL
czl026/cmf
/install/spcmf.sql
UTF-8
52,180
3.21875
3
[ "Apache-2.0" ]
permissive
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; -- -- 数据库: `spcms` -- -- -------------------------------------------------------- -- -- 表的结构 `sp_access` -- CREATE TABLE `sp_access` ( `role_id` smallint(6) unsigned NOT NULL, `g` varchar(20) NOT NULL COMMENT '项目', `m` varchar(20) NOT NULL COMMENT '模块', `a` varchar(...
true
67f27089d35b1619874bad2ed996895dab3caa61
SQL
rowan-adair/CSC2042-48
/assignment48/querydb48.sql
UTF-8
2,168
4.21875
4
[]
no_license
-- Query Scripts -- Rowan Adair - 40226787 - Team 48 -- Draft 1 -- Query 1 Find the number of apartments with/without ensuites and the -- total apartments in the building. -- Draft 3 - Rowan Adair- 40231585 - 2019-11-09 SELECT apartmentbuilding.BuildingID AS "Building", building.Address AS "Address", COUNT(CASE W...
true
68d3658b4dabc5676c6faeb98ab7813dae8cf911
SQL
svotoq/MSSQL
/lab6(Joins)/Zad6.sql
WINDOWS-1251
188
2.828125
3
[]
no_license
USE UNIVERlab4 SELECT PULPIT.PULPIT_NAME , ISNULL(TEACHER.TEACHER_NAME,'***') FROM PULPIT LEFT OUTER JOIN TEACHER ON PULPIT.PULPIT = TEACHER.PULPIT
true
29fdd488778bd60a9c95c4fec96a989c53df67be
SQL
jd-camontoy/project-systat
/services/storage-mysql/scripts/tables-systat.sql
UTF-8
1,430
3.453125
3
[]
no_license
CREATE TABLE `rj_period_tb` ( `id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT, `period_name` VARCHAR(10) NOT NULL COMMENT 'Period name/term used for the period (e.g 2H2020)', `period_start_date`DATETIME NOT NULL COMMENT 'Start date of the period', `period_end_date` DATETIME NOT NULL COMMENT 'End date of t...
true
32cb34488f53fd29bf1c65a00469f69951183670
SQL
SrivatsanV/Canteen-Management-System
/TestScript.sql
UTF-8
4,691
3.28125
3
[]
no_license
-- MySQL Script generated by MySQL Workbench -- Sun Nov 17 02:07:32 2019 -- Model: New Model Version: 1.0 -- MySQL Workbench Forward Engineering 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='ON...
true
754540f689e99cedecc714b12d39fad526fd57f4
SQL
NikolayKryzhevoy/SQL-practice-Employee-Turnover
/report.sql
UTF-8
18,395
4.5625
5
[]
no_license
--------------------------------------------------------------------------------------------------- -- Part I --------------------------------------------------------------------------------------------------- -- How many unique companies we are dealing with? SELECT COUNT(DISTINCT companyAlias) as Companies FR...
true
60c74444f3be18e785b29b5510163a28a70f5869
SQL
Kaushik098/Oracle_sql_file_2
/14.)Views/Views/2_invalid_views.sql
UTF-8
2,665
3.8125
4
[]
no_license
--check the status column - important SELECT * FROM USER_OBJECTS WHERE OBJECT_NAME = 'V_RESTRICTED_EMP_DATA'; --when will a view become invalid? CREATE TABLE t_invalid ( num1 NUMBER, num2 NUMBER, num3 NUMBER ); --create a view on top of t_invalid and show only 2 columnsin that view CREATE OR REPLACE VIEW v_...
true
c103928a23951aaf203fe188e04703bbe97078b6
SQL
saraval09/saraval09.github.io
/mysql/EricValMusic_2016-11-16.sql
UTF-8
4,737
2.96875
3
[]
no_license
# ************************************************************ # Sequel Pro SQL dump # Version 4541 # # http://www.sequelpro.com/ # https://github.com/sequelpro/sequelpro # # Host: localhost (MySQL 5.5.42) # Database: EricValMusic # Generation Time: 2016-11-17 03:56:41 +0000 # ******************************************...
true
694639902e2604f2ebf11fec0a77e8293f7fe1e9
SQL
Euibp/As_Aventuras_de_PI
/MySql_InsertAll.sql
UTF-8
1,179
2.703125
3
[]
no_license
INSERT INTO refrigerador(nome_refrigerador) VALUES ('Estoque'),('Richard_Parcker'); INSERT INTO cor(nome_cor) VALUES ('Vermelho'),('Azul'),('Branco'),('Verde'),('Preto'); INSERT INTO produto(nome_produto,real_preco,fk_id_cor) VALUES ('CAIXA01',10.90,1), ('CAIXA02',11.80,2), ('CAIXA03',12.70,3), ...
true
5a8b1ab071391a1185084c3745ae06c12636f68f
SQL
syuanivy/SMail
/db/shuai/webmail/webmail_dev.sql
UTF-8
12,271
2.6875
3
[]
no_license
PRAGMA foreign_keys=OFF; BEGIN TRANSACTION; CREATE TABLE incoming(id TXT PRIMARY KEY, sender TXT, recipient TXT NOT NULL, subject TXT, body TXT, attached INT DEFAULT 0, label INT DEFAULT 0, time TXT DEFAULT CURRENT_TIMESTAMP, FOREIGN KEY (recipient) REFERENCES accounts(email_address)); INSERT INTO "incoming" VALUES('Gm...
true
f25117b41d0f98d894c987f88c88624fdf1b1337
SQL
grvgoel81/leetcode
/game-play-analysis-iv.sql
UTF-8
443
4.21875
4
[]
no_license
SELECT ROUND(COUNT(*) / (SELECT COUNT(DISTINCT player_id) FROM Activity), 2) AS fraction FROM ( SELECT 1 FROM ( SELECT player_id, DATE_ADD(MIN(event_date), INTERVAL 1 DAY) AS second_date FROM Activity GROUP BY player_id ...
true
9994f51c4805392810000380bd5edb694dc57133
SQL
HristoKolev/PgNet
/src/PgNetGenerator/get-functions.sql
UTF-8
702
3.515625
4
[ "MIT" ]
permissive
SELECT n.nspname as SchemaName, f.proname as FunctionName, (case pg_get_function_identity_arguments(f.oid) when '' then null else pg_get_function_identity_arguments(f.oid) end) as FunctionArgumentsAsString, (select t.typname::text from pg_type t where t.oid = f.prorettype) as FunctionReturnTypeName, ...
true
93096e47bf47378953baee95155dcdc55c59e22c
SQL
bellmit/SVNrepo
/DBScripts/GoldenSourceMasterScript/1_Model/501.pm.sp_upload_sec_asset_mapping.sql
UTF-8
2,451
4.03125
4
[]
no_license
DROP PROCEDURE IF EXISTS `sp_upload_sec_asset_mapping`; DELIMITER $$ CREATE PROCEDURE `sp_upload_sec_asset_mapping`( IN p_theme VARCHAR(20) ) BEGIN DELETE FROM `invdb`.`sec_asset_mapping` where theme = p_theme; /* Insert from sec_primeasset_mapping */ INSERT INTO `invdb`.`sec_asset_mapping` (`theme`,...
true
9bf963973d10a384d1beed85335ae6563757cb28
SQL
PerlineDemange/GeneticNurtureNonCog
/PGS_LDpred/ProcessSumstats.sql
UTF-8
619
2.734375
3
[]
no_license
.mode csv .separator "," create table tab1(RSID TEXT, JOINID TEXT, CHR TEXT, POS INTEGER, REF TEXT, ALT TEXT); create table tab2(CHR TEXT, POS INTEGER, REF TEXT, ALT TEXT, REFFREQ REAL, BETA REAL, SE REAL, P REAL, N INTEGER); .import ./LDPred/1KG_LDPred_Markermap.csv tab1 .import ./_Table1.dat tab2 .output /dev/shm/_OK...
true
5e4673d771008704f00221b54bf9cd20db5aa684
SQL
AlikJoke/CSCM-Microservices
/cscm-base/cscm-dao/src/main/resources/ddl-scripts/postgres/t_cm_route_org.ref.sql
UTF-8
116
2.640625
3
[ "Apache-2.0" ]
permissive
ALTER TABLE T_CM_ROUTE_ORG ADD CONSTRAINT T_CM_ROUTE_ORG_FK FOREIGN KEY (INST_ID) REFERENCES T_CM_INST (ID);
true
e6182aa78daf959b4bb7a953818751d48a7ed4d1
SQL
Sniezdapal/PBZ_first
/scripts/first_task/queries/9_classrooms_100_200.sql
UTF-8
471
3.3125
3
[]
no_license
-- Получить названия предметов и названия групп, которые ведут занятия в аудиториях с 100 по 200. SELECT subject_name, group_name FROM teacher_teaches_subjects JOIN subjects ON teacher_teaches_subjects.code_subjet_number = subjects.code_subjet_number JOIN student_groups ON teacher_teaches_subjects.code_group_number ...
true
612cec82faf5a8f598e6ad9ac09910f262829823
SQL
asadali08527/springDataTutorials
/Spring-Data-Jdbc-tutorials/src/main/resources/schema.sql
UTF-8
804
3.4375
3
[]
no_license
create table users( id integer identity primary key, full_name varchar(50), date_of_birth date, ); create table address( id integer identity primary key , users integer references users(id), address_line varchar(250) ); create table books( id integer identity primary key, title varchar(250), isbn var...
true
c3d2a37536b08f3fbcfa637f8c07eba471b0dff8
SQL
kushvaharavi/formValidation
/form_data.sql
UTF-8
2,426
2.96875
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Dec 03, 2017 at 08:05 PM -- Server version: 10.1.28-MariaDB -- PHP Version: 7.1.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
ff632890b053f6bf1b657b5ac1d162a03f03c9d9
SQL
JonathanRH07/Control-de-versiones
/DB ICAAVweb/Suite_mig_demo/Stored_Procedures/sp_cat_cliente_adicional_c.sql
UTF-8
740
3.234375
3
[]
no_license
DELIMITER $$ CREATE DEFINER=`suite_deve`@`%` PROCEDURE `sp_cat_cliente_adicional_c`( IN pr_id_cliente INT, OUT pr_message VARCHAR(500)) BEGIN /* @nombre: sp_cat_cliente_adicional_c @fecha: 25/01/2017 @descripción: @autor : Griselda Medina Medina. @cambios: */ DECLARE EXIT HANDLER FOR SQLEXCEPTION ...
true
45b1cecd608745444f487bb5927b7eb9aa0235e0
SQL
MaayanLab/adhesome
/templates/__network_stats.sql
UTF-8
1,443
3.09375
3
[]
no_license
{% set intrinsic_view %} create temp view `intrinsic_nodes` as select * from `components` where `FA`="Intrinsic Proteins"; {% endset %} {% set intrinsic_edges_query %} select count(*) from `edges` where `Source`=(select `Official Symbol` from `intrinsic_nodes`) or `Target`=(select `Official Symbol` from `intrin...
true
ea9a0fdfa355738125fcf740fcef564cad482999
SQL
Thekami/api_demo
/db.sql
UTF-8
2,952
3.09375
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Versión del servidor: 5.7.15-log - MySQL Community Server (GPL) -- SO del servidor: Win32 -- HeidiSQL Versión: 9.4.0.5125 -- --------------------------------------------------------...
true
ba5c474cda9fff112e90b7d7192a9f0b01a0a260
SQL
mdheller/Panoptes
/db/structure.sql
UTF-8
131,200
3.078125
3
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
-- -- PostgreSQL database dump -- SET statement_timeout = 0; SET lock_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 client_min_messages = warning; -- -- Name: plpgsql; Type: EXTENSION; Sch...
true
ab590cf525c2eb4e098f0a7ea0fbf001eae01d7a
SQL
christiandeangelis/meetpad-public
/cdst-business/cdst_be_marche/src/main/resources/db/migration/V1.61__insert_evento_partecipante.sql
UTF-8
1,273
2.734375
3
[]
no_license
DELETE FROM cdst.evento_partecipante where id_evento_partecipante in (6, 7, 8, 9); INSERT INTO cdst.evento_partecipante (fk_tipo_evento, fk_ruolo_partecipante) VALUES ('9', '1') ON CONFLICT DO NOTHING; INSERT INTO cdst.evento_partecipante (fk_tipo_evento, fk_ruolo_partecipante) VALUES ('9', '3') ON CONFLICT DO NOTHING...
true