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
a6bfbac66081bf065d1239261a9e16b59a472457
SQL
leojen23/ComparOperator
/comparoperator.sql
UTF-8
5,118
3.15625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Hôte : localhost:3306 -- Généré le : Dim 21 juin 2020 à 13:42 -- Version du serveur : 5.7.24 -- Version de PHP : 7.2.19 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CL...
true
97ace5dae8ad6170d010703f9700826113628c49
SQL
spalonytoster/lolesportsapp
/lolesportsapp-core/sql/prebuildDB.sql
UTF-8
2,928
3.234375
3
[]
no_license
DROP TABLE Player; DROP TABLE Team; CREATE TABLE Team (idTeam BIGINT GENERATED BY DEFAULT AS IDENTITY (START WITH 1) PRIMARY KEY, name VARCHAR(20) NOT NULL, region VARCHAR(4) NOT NULL, dateOfEstablishment DATE); CREATE TABLE Player (idPlayer BIGINT GENERATED BY DEFAULT AS IDENTITY (START WITH 1) PRIMARY KEY, name V...
true
fd6c1d16a99e456ee5e3a8b8166e467c29edb088
SQL
AlmasHosssain/Database-Oracle-
/DATABASE COLLECTION OBJECT.SQL
UTF-8
917
3.625
4
[]
no_license
SET SERVEROUTPUT ON; CREATE OR REPLACE TYPE NET_TABLE IS TABLE OF VARCHAR2(30); / CREATE TABLE TYE( N_ID NUMBER, N_PERSON VARCHAR2(10), NEST NET_TABLE )NESTED TABLE NEST STORE AS KOOP; / DESC TYE; INSERT INTO TYE(N_ID,N_PERSON,NEST) VALUES (1,'ALMAS', NET_TABLE('BOSA','KAKA','VI','HOK')); I...
true
cced411b538ad269a94eac3357898eaaa01d7485
SQL
Jack-D1/Training-List
/data.sql
UTF-8
3,288
3.046875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.0 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Apr 09, 2018 at 05:32 PM -- Server version: 5.7.17 -- PHP Version: 5.6.30 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACT...
true
931da4290835dad0d7a6f5ad2ed0044d8d85b971
SQL
EAlas7alo/MittausApi
/001-init.sql
UTF-8
283
2.65625
3
[]
no_license
CREATE TABLE IF NOT EXISTS `measurements` ( id INTEGER PRIMARY KEY, name TEXT NOT NULL, quantity TEXT NOT NULL, referenceValueLower REAL NOT NULL CHECK (CAST(referenceValueLower||1 AS REAL)), referenceValueUpper REAL NOT NULL CHECK (CAST(referenceValueUpper||1 AS REAL)) );
true
2825815adc1cd6829412c93996e1d9debbc767d9
SQL
angel-aleksandrov06/SoftUni-Engineering-CSharp
/Databases Basics - MS SQL Server/Exams/Exam - 16 Apr 2019/12. LostLuggages.sql
UTF-8
161
3.515625
4
[]
no_license
SELECT PassportId, [Address] FROM Passengers p LEFT JOIN Luggages l ON l.PassengerId = p.Id WHERE LuggageTypeId IS NULL ORDER BY PassportId ASC, Address ASC
true
36daa5ac517889c881f6fe433e40f00b7d6fada1
SQL
Kamfeth/Praktyczny-kurs-SQL-Wydanie-III-Danuta-Mendrala-Marcin-Szeliga-
/Część II/Rozdział 9/Zadanie 3/Zadanie3.sql
UTF-8
112
2.578125
3
[]
no_license
CREATE INDEX IX_SalesOrderHeader_DueDate ON SalesLT.SalesOrderHeader (DueDate) INCLUDE (SalesOrderID, TotalDue)
true
d44e31fff3717e5fa28af7f58d08ebf757ef7716
SQL
prameetu/sql_practice
/union_3.sql
UTF-8
368
3.09375
3
[]
no_license
SELECT customer_id, first_name, points, 'Bronze' AS type FROM customers WHERE points < 2000 UNION SELECT customer_id, first_name, points, 'Silver' AS type FROM customers WHERE points >= 2000 AND points < 3000 UNION SELECT customer_id, first_name, points, 'Gold' AS type FROM customers WHER...
true
0103ac3c4be9ff351d09b2a8976c8ce8a012e3f4
SQL
behemoth-13/Academy
/src/test/resources/test.sql
UTF-8
2,628
3.140625
3
[]
no_license
DROP SCHEMA IF EXISTS `academytest`; CREATE DATABASE IF NOT EXISTS `academytest` /*!40100 DEFAULT CHARACTER SET utf8 */; USE `academytest`; -- MySQL dump 10.13 Distrib 5.7.12, for Win64 (x86_64) -- -- Host: localhost Database: library -- ------------------------------------------------------ -- Server version 5.7....
true
592e42641daae9760beb3874384dad0140fee099
SQL
BalioFVFX/Database-Basics-MySQL-September-2018
/EXAM PREPARATION I/02. Insert/02. Insert.sql
UTF-8
256
3.453125
3
[]
no_license
INSERT INTO issues (title, issue_status, repository_id, assignee_id) SELECT CONCAT('Critical Problem With ', f.name, '!'), 'open', CEIL((f.id * 2) / 3), cm.contributor_id FROM files f JOIN commits cm ON cm.id = f.commit_id WHERE f.id >= 46 AND f.id <= 50;
true
d77b173ec30f3f462d493bccf12fc838a41b9682
SQL
oleayaona/timetraker
/myDb.sql
UTF-8
2,430
3.84375
4
[]
no_license
-- \dt - Lists the tables -- \d+ public.user - Shows the details of the user table -- DROP TABLE public.user - Removes the user table completely so we can re-create it -- \q - Quit the application and go back to the regular command prompt -- // DATABASE_URL='postgres://ktbpmcuwirkaoq:39a0add99d89e8a04017792d4e6c3b380a...
true
379dff021c70e94389d4203a1a73d4f4e288268f
SQL
rklaus/proxy_fork
/sql/_load_all.sql
UTF-8
665
2.78125
3
[]
no_license
\echo Start Database load \set ON_ERROR_STOP on \pset pager off --\timing on set client_min_messages to warning; -- Acquire an exclusive lock to force sequential deploys DO $func$ DECLARE lock_acquired boolean; BEGIN SELECT pg_try_advisory_lock(hashtext('dataload')) INTO lock_acquired; IF NOT lock_acquir...
true
78fe740c38f997ad1cc436eb667d3d4d41126e57
SQL
bellmit/flexdb
/2.HOST/3.Procedure/gl1007.sql
UTF-8
5,691
3.375
3
[]
no_license
CREATE OR REPLACE PROCEDURE GL1007 ( PV_REFCURSOR IN OUT PKG_REPORT.REF_CURSOR, OPT IN VARCHAR2, BRID IN VARCHAR2, F_DATE IN VARCHAR2, T_DATE IN VARCHAR2 ) IS -- -- PURPOSE: B?O C?O CHI TI?T DOANH S? THEO NH? VI? M? GI?I - CAREBY VIP TEAM...
true
4f154523c5135f422ba3c769cfff34bedca0f3df
SQL
NickyGon/MiProyecto
/clase5/clase5_ejercicios.sql
UTF-8
1,135
3.65625
4
[ "MIT" ]
permissive
select ingredients.name from ingredients inner join vendors on ingredients.vendorid=vendors.vendorid && vendors.companyname='Veggies_R_Us'; select ingredients.name from ingredients inner join vendors on ingredients.vendorid=vendors.vendorid && (vendors.companyname='Veggies_R_Us' || vendors.companyname='Spring Water S...
true
a3fd95e2cf4c916c52040489a5f51aacb9756d1c
SQL
cnzhoufei/linfei
/Data/backupdata/2017-03-11-15-38-27/structure/linfei_productimge32e43c95ee056dffeac8cfb8b3ea452.sql
UTF-8
423
2.71875
3
[]
no_license
-- ---------------------------- -- Table structure for linfei_productimg -- ---------------------------- DROP TABLE IF EXISTS `linfei_productimg`; CREATE TABLE `linfei_productimg` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `productid` int(11) NOT NULL COMMENT '产品id', `img` varchar(255) NOT NULL DEFAULT '' ...
true
5a89a6cc504cc987a30b53790a171ee28539692e
SQL
4l13n5/PB2-seminarska
/views.sql
WINDOWS-1250
1,121
3.421875
3
[]
no_license
create or replace view ponudba_poslovalnic as select poslovalnica.id_poslovalnice, (poslovalnica.potna_st || ' ' || posta.mesto || ', ' || poslovalnica.ulica || ' ' || poslovalnica.hisna_st) as naslov, vrsta_artikla.kategorija,artikel.ime_artikla,zaloge.koliina from poslovalnica join posta on posta.potna_t...
true
e3fcb96e8e1b018ce3d270db1237f7e02f8a7386
SQL
Mynor2397/apiRest-mysql-branca
/database.sql
UTF-8
1,417
3.984375
4
[]
no_license
DROP database IF EXISTS network; CREATE DATABASE IF NOT EXISTS network; USE network; CREATE TABLE IF NOT EXISTS user( id int auto_increment primary key, email varchar(50) not null unique, username varchar(50) not null unique, password varchar(75) not null, followers_count int not null default 0 check...
true
ac390c91e335147cb4ac6a9e0cd329df89c7a040
SQL
jussijartamo/toocljs
/example.database.sql
UTF-8
536
2.9375
3
[ "BSD-3-Clause" ]
permissive
CREATE TABLE films ( code char(5) CONSTRAINT firstkey PRIMARY KEY, title varchar(40) NOT NULL, len interval hour to minute ); INSERT INTO films VALUES ('MOV01', 'Some movie 1', '1:59'); INSERT INTO films VALUES ('MOV02', 'Some movie 2', '2:59'); INSERT INTO films VALUES ('MOV...
true
f5cefedfc7d33fa804af23de5970db2ee934a73d
SQL
longlehoang/myPersonalProject
/report_scripts/iot_desc.sql
UTF-8
1,300
2.578125
3
[]
no_license
DELETE SFACodeDEsc WHERE REC_USER_CODE = 'IOT interface' INSERT INTO SFACOdeDESC SELECT DISTINCT '*', '*', 'CoolerIOTAsset', AssetID, CoolerAssetNo, GETDATE(), GETDATE(), 0, 'IOT interface' FROM Alerts WHERE CoolerAssetNo NOT LIKE '% %' INSERT INTO SFACOdeDESC SELECT DISTINCT '*', '*', 'CoolerIOTStatus', 1, 'New', G...
true
1572cecd0d4b1cb7e17f3e83f1928b7aacd571d2
SQL
NazmusShakib/e-gym
/DB.sql
UTF-8
25,361
3
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.4.1deb2ubuntu2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Mar 05, 2017 at 11:38 AM -- Server version: 5.7.17-0ubuntu0.16.04.1 -- PHP Version: 7.0.15-0ubuntu0.16.04.4 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_C...
true
f385888d760db4f09b451ee044c6d716c8bf7140
SQL
ilevmedis/alters
/alters/alters_2012/ALTER_2012_02_13_PBL_PACKAGEDIAGNOSISCODELNK.sql
UTF-8
1,364
3.328125
3
[]
no_license
create table PBL_PACKAGEDIAGNOSISCODELNK (PACKAGEDIAGNOSISCODELNKID number(38) not null, companyid number(38) not null, fyearid number(38) not null, diagnosisgroupingid number(38) not null, diagnosiscodeid varchar2(40) not null, PACKAGEID number(38) not null); alter table PBL_PACKAGEDIAGNOSISCODELNK add constraint ...
true
e0e86744fd0e3c1b449bcfe7c6fcb7f515268881
SQL
ranavikas/IAA
/Database Assets/Full Database Dump - 2017-10-07.sql
UTF-8
62,195
3.25
3
[]
no_license
/* SQLyog Enterprise v12.4.1 (64 bit) MySQL - 10.1.21-MariaDB : Database - iaa_cms ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN...
true
7c3b998d3eadcbd90ef4e4d53598832e49bb4e26
SQL
patricknaka/Nova
/Relatórios LN/LN_Contas a pagar - Agrupamento CTRC.sql
UTF-8
17,595
2.546875
3
[]
no_license
SELECT tfacp201.t$mopa$d CODE_MODAL_PGTO, DESC_MODAL_PGTO. DESC_MODAL_PGTO, tfacp201.t$payd DATA_VENCTO, tfacp200.t$docd DATA_EMISSAO, tcmcs065.t$dsca NOME_FILIAL, tccom130f.t$fovn$l ...
true
8a8587a5f607d93a875e5eb929ef0133b431bc00
SQL
favianahza/saas-2
/saas_2.sql
UTF-8
4,327
3.0625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jul 16, 2020 at 01:06 AM -- Server version: 10.3.16-MariaDB -- PHP Version: 7.3.6 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @O...
true
f59461d77b487abe9569bfaf5066b4dfde1c4360
SQL
FranciscoMan/TestDB2
/PRD/Stored Procedures/SPE_GET_UNUSED_PRODUCTION_LINE.sql
UTF-8
2,249
3.4375
3
[]
no_license
-- ============================================= -- Proyecto: Plaskolite -- Copyright (c) - Acrux - 2017 -- Author: Julio Tavares -- CREATE date: 23/05/2017 -- Description: Unused production lines. -- ============================================= -- 18/08/2017 JDR Change subquery to use CTE -- 18/08/2017 JDR FG_EMPLOY...
true
2b65e3550de0f91fdd8f0289acdf462b268130da
SQL
Belyj/Integrator
/src/main/resources/sqlScripts/Procedures/getUserByName.sql
UTF-8
303
2.96875
3
[]
no_license
DELIMITER // CREATE PROCEDURE `getUserByName` (IN userName VARCHAR(255), userPass VARCHAR(256)) LANGUAGE SQL DETERMINISTIC COMMENT 'searching user info @param user name, user pass' BEGIN SELECT uid, uname FROM handbook_schema.user_table WHERE uname = userName AND pass = userPass; END//
true
8591eeab7c97f0f95d96830c9e2a9f4d1d8417d1
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day28/select1311.sql
UTF-8
178
2.65625
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-27T13:11:00Z' AND timestamp<'2017-11-28T13:11:00Z' AND temperature>=48 AND temperature<=73
true
ee3be505b53174047ad1461f4370fb2750d51fe2
SQL
abdulweb/Revenue-Management-System
/rms.sql
UTF-8
3,443
3.015625
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.19, for Win64 (x86_64) -- -- Host: localhost Database: rms -- ------------------------------------------------------ -- Server version 5.7.19 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!4010...
true
20fecf1f5437e9f220c2d255e3975056eedca357
SQL
Atikasoft/protteus2
/proteus-ejb/src/main/resources/db/migration/V201707171305__AGREGAR_CAMPO_TIPO_LIQUIDACION_TABLA_LIQUIDACION.sql
UTF-8
478
2.609375
3
[]
no_license
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ ALTER TABLE sch_proteus.liquidaciones ADD tipo_liquidacion_id NUMERIC(19,0), CONSTRAINT liquidaciones_...
true
ab127dcb4798c77099056c59cb43fe46853ed17d
SQL
szhxjt1334/WoWCircle434
/sql/updates/circle_updates/characters/2169_guild_challenge.sql
UTF-8
345
2.703125
3
[]
no_license
DROP TABLE IF EXISTS `guild_challenge`; CREATE TABLE `guild_challenge` ( `guildId` INT(10) UNSIGNED NOT NULL, `dungeonCount` TINYINT(3) UNSIGNED NOT NULL DEFAULT '0', `raidCount` TINYINT(3) UNSIGNED NOT NULL DEFAULT '0', `RBGCount` TINYINT(3) UNSIGNED NOT NULL DEFAULT '0', PRIMARY KEY (`guildId`) ) COLLATE='utf8_...
true
50e71798cc3d884974eb517826c9504579a8718b
SQL
jbigtani/SnowflakeWebApp
/IoTE2EPipeline.sql
UTF-8
2,161
3.4375
3
[]
no_license
CREATE FILE FORMAT "DEMO_DB"."PUBLIC".COLORS_CSV TYPE = 'CSV' COMPRESSION = 'AUTO' FIELD_DELIMITER = ',' RECORD_DELIMITER = '\n' SKIP_HEADER = 1 FIELD_OPTIONALLY_ENCLOSED_BY = 'NONE' TRIM_SPACE = FALSE ERROR_ON_COLUMN_COUNT_MISMATCH = TRUE ESCAPE = 'NONE' ESCAPE_UNENCLOSED_FIELD = '\134' DATE_FORMAT = 'AUTO' TIMESTAMP...
true
19f68d999d1d2777c6f0fcbe44c05131dd7296fd
SQL
skullcrusher55/sparksjan2021
/banking.sql
UTF-8
2,998
3.375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jan 14, 2021 at 03:04 PM -- Server version: 10.4.14-MariaDB -- PHP Version: 7.4.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
6dd7a7d3b1f2096c7d880011bc7232e50cf1717c
SQL
diarmuid451/sql-developers
/2019-12-05.sql
UTF-8
4,775
4.1875
4
[]
no_license
--실습 sub4 INSERT INTO dept VALUES (99,'ddit','daejeon'); commit; select * from dept where deptno NOT IN (select deptno from emp); --실습 sub5 select * from product where pid NOT IN (select pid from cycle where cid =1); --실습 sub6 --(cid = 2인 고객이 애음하는 제품)중 cid = 1인 고객이 애음하는 제품의 애음정보를 조회 select * from cycle where cid ...
true
6d0641d658d197e978b35268966131f2fbe40429
SQL
guanjiechen/Twitter-Analytics-Web-Service
/code/ETL/q2/q2procedure.sql
UTF-8
178
2.5625
3
[]
no_license
Delimiter // CREATE PROCEDURE q2(IN timein timestamp, IN userin INT UNSIGNED) BEGIN SELECT tweet_id FROM tweets_q2 WHERE time = timein AND user_id = userin; END; // Delimiter ;
true
aac10dabd58768a1b84e42cd055afd49b9240d49
SQL
lover2668/stemsible
/sql/create_unlikes.sql
UTF-8
824
4.15625
4
[]
no_license
-- Create unlikes table -- Used to record when a user unlikes a message that they previously liked -- unlink the likes table, this table does not have a unique constraint -- on user_id, message_id create table unlikes ( id integer unsigned not null auto_increment primary key, user_id in...
true
8d6e46ebf22ba92098dc3af5cffa32772a75516a
SQL
lhty/nest-auth
/prisma/migrations/20210714134343_user/migration.sql
UTF-8
935
4.03125
4
[]
no_license
-- CreateEnum CREATE TYPE "Roles" AS ENUM ('PASSWORD_REQUIRED', 'INACTIVE', 'REGULAR', 'ADVANCED', 'SU'); -- CreateTable CREATE TABLE "User" ( "id" SERIAL NOT NULL, "password" TEXT NOT NULL, "email" TEXT NOT NULL, "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, "updatedAt" TIMESTAMP(3)...
true
91e1aaf7bcacac83ed29ceafdf759ed87e271c19
SQL
thangduong3010/PL-SQL
/lopfiles-1.0/ch05/simple_select.sql
UTF-8
548
3.28125
3
[]
no_license
REM $Id: simple_select.sql,v 1.1 2001/11/30 23:19:51 bill Exp $ REM From "Learning Oracle PL/SQL" page 152 REM Show use of SELECT INTO to retrieve one row REM In the first printing of the book, two question marks appear in the REM declaration of a variable, that is, VARCHAR2(??). The correct code REM appears below. ...
true
129e210a61cbcbc4ae85eea226fdcea1e9bdd796
SQL
ThiagoOliveira001/smn-atividade-sql
/josiel/Exercicio 18.sql
UTF-8
281
3.15625
3
[]
no_license
SELECT NomeMarca, COALESCE( (SELECT CAST(NomeProduto AS VARCHAR(50)) + ', ' AS [text()] FROM Produto AS P WHERE P.IdMarca = M.IdMarca FOR XML PATH(''), TYPE).value('.[1]', 'VARCHAR(MAX)'), '') AS Produtos FROM Marca AS M GROUP BY NomeMarca, M.IdMarca order by NomeMarca
true
ff35cdd220bb414159017a133b261bc2eee553ff
SQL
ynonp/apanel
/script/initdb.sql
UTF-8
1,096
3.8125
4
[]
no_license
DROP TABLE IF EXISTS users; DROP TABLE IF EXISTS roles; DROP TABLE IF EXISTS user_roles; CREATE TABLE users ( id INTEGER PRIMARY KEY, active CHAR(1) NOT NULL, username TEXT NOT NULL UNIQUE, password TEXT NOT NULL, password_expires TIMESTAMP, name TEXT NOT NULL, email_address TEXT NOT NULL, ...
true
6659800f64edb92b4a8a30e73e8270ea886e7e1d
SQL
robin253/doc
/oracle/sqls/Oracle 性能分析.sql
GB18030
692
3.78125
4
[]
no_license
-- Oracleܷ DROP VIEW V_TOP_DYNAMIC_SQL; -- ͼ CREATE OR REPLACE VIEW V_TOP_DYNAMIC_SQL AS SELECT USER_NAME,MACHINE,OSUSER,PROGRAM,SID,SERIAL#,EXECUTIONS,OPTIMIZER_COST,SORTS,SQL_TEXT FROM ( select o.user_name, s.machine, s.osuser, s.program, o.sid,s.serial#, q.EXECUTIONS, q.OPTIMIZER_COST, q.sorts, q.sql_text from v$op...
true
b294f5685e1b14472b30a63c66a8ad36528ff316
SQL
bernhardsohndesherbert/engage
/ext_tables.sql
UTF-8
1,385
2.703125
3
[]
no_license
# # Table structure for table 'tx_engage_domain_model_engage' # CREATE TABLE tx_engage_domain_model_engage ( uid int(11) NOT NULL auto_increment, pid int(11) DEFAULT '0' NOT NULL, tstamp int(11) DEFAULT '0' NOT NULL, crdate int(11) DEFAULT '0' NOT NULL, cruser_id int(11) DEFAULT '0' NOT NULL, t3ver_oid int(11) ...
true
f8d2a5703e49a929a47ea5a53ec4736ca35c29a6
SQL
oliverw1/summerschool_capstone
/sql/01_monthly_max.sql
UTF-8
188
2.90625
3
[]
no_license
-- Show the maximum value of the air quality parameters (NOx, CO, ...) per month. select month(date(utc)), parameter, max(value) as monthly_max from AQ group by month(date(utc)),parameter;
true
c33e415c49a55bd252e8459ab22df72ff3559b9d
SQL
CesarArt/Actividades_proyecto_IN
/Practica etl/tabla_hechos.sql
UTF-8
1,154
3.71875
4
[]
no_license
CREATE PROCEDURE cargaTablaHechos() BEGIN DROP TABLE IF EXISTS Ventas; CREATE TABLE Ventas( id_producto VARCHAR(20), numero_cliente VARCHAR(20), fecha DATE, importe_venta DOUBLE, unidades_vendidas DOUBLE, venta_neta DOUBLE, PRIMARY KEY(id_producto, numero_cliente, fecha)); ALTER TABLE ...
true
d82317366f41db30f5983283c906c71492b67264
SQL
SuiteLHY/lemon
/src/main/resources/dbmigrate/mysql/data_report/V0_0_0_1__data.sql
UTF-8
615
3.09375
3
[ "Apache-2.0" ]
permissive
INSERT INTO REPORT_SUBJECT(ID,NAME,PRIORITY) VALUES(1,'活跃流程',1); INSERT INTO REPORT_QUERY(ID,CONTENT,SUBJECT_ID) VALUES(1,'SELECT PD.NAME_ AS NAME,COUNT(PD.NAME_) AS C FROM ACT_HI_PROCINST PI,ACT_RE_PROCDEF PD WHERE PI.PROC_DEF_ID_=PD.ID_ AND PD.TENANT_ID_=? GROUP BY PD.NAME_',1); INSERT INTO REPORT_DIM...
true
d123119fa70b82a147e9ee9d2978ba5152c0cc9a
SQL
jmgold/SQL-Queries
/Library requests/mld weekly fines paid.sql
UTF-8
887
3.390625
3
[ "LicenseRef-scancode-warranty-disclaimer" ]
no_license
SELECT f.paid_date_gmt::DATE AS DATE, COALESCE(SUM(f.paid_now_amt) FILTER(WHERE f.charge_type_code IN ('2','6'))::MONEY,0.00::MONEY) AS overdue, COALESCE(SUM(f.paid_now_amt) FILTER(WHERE f.charge_type_code = '5')::MONEY,0.00::MONEY) AS lost_book, COALESCE(SUM(f.paid_now_amt) FILTER(WHERE f.charge_type_code = '3')::MON...
true
3584631ed2266a4e56e501db83867ee12740684f
SQL
OHDSI/Vocabulary-v5.0
/JMDC/load_stage_2.sql
UTF-8
4,833
3.90625
4
[ "Unlicense" ]
permissive
--add manual mapping INSERT INTO aut_ingredient_mapped (concept_name, precedence, concept_id_2) SELECT DISTINCT concept_name, COALESCE(precedence, 1), concept_id_2 FROM ingredient_mm WHERE concept_id_2 IS NOT NULL AND concept_id_2 NOT IN (17, 0) AND concept_name NOT IN ( SELECT concept_nam...
true
63f3377ff893ab0321ef17d77784ed64fa398ac2
SQL
ArturPab/facebook-clone
/src/main/resources/database/2020-12-13/02-create-post.sql
UTF-8
1,745
2.90625
3
[]
no_license
--liquibase formatted sql --changeset apabjan:2 create table POST ( post_id bigint not null auto_increment, content varchar(255), user_id bigint, created datetime(6), primary key (post_id)) engine=InnoDB; alter table POST add constraint FK72mt33dhhs48hf9gcqrq4fxte foreign key (user_id) references user(user_id); inse...
true
2b73c2b23363972fb41f5a446a16089eafe82df8
SQL
akheron/sqltyper
/src/sql/tableColumns.sql
UTF-8
327
3.4375
3
[]
no_license
SELECT attnum, attname, atttypid, attnotnull, attisdropped FROM pg_catalog.pg_attribute attr JOIN pg_catalog.pg_class cls on attr.attrelid = cls.oid JOIN pg_catalog.pg_namespace nsp ON nsp.oid = cls.relnamespace WHERE cls.relkind = 'r' AND nsp.nspname = ${schemaName} AND cls.relname = ${tableName} ORDER BY ...
true
95e8158062a6e1f63d599f2ebbdda5f7f13a55a2
SQL
bcgov/PIMS
/backend/dal/Migrations/v01.03.00/Up/PostUp/01-Projects.sql
UTF-8
188
3.125
3
[ "Apache-2.0" ]
permissive
PRINT 'Update Projects' -- Update the project metadata. UPDATE p SET p.[Metadata] = b.[Metadata] FROM dbo.[Projects] p INNER JOIN #Projects b ON b.[Id] = p.[Id] DROP TABLE #Projects
true
b6b2696d391b0d96da37dea0aa358d5b344f39bf
SQL
jacobsimeon/arc
/spec/support/schemas/mysql.sql
UTF-8
564
3.046875
3
[]
no_license
DROP TABLE IF EXISTS superheros; CREATE TABLE superheros ( id INTEGER NOT NULL PRIMARY KEY AUTO_INCREMENT, name VARCHAR(256) NOT NULL, born_on DATE NOT NULL, photo BLOB NULL, created_at TIMESTAMP NOT NULL ); DROP TABLE IF EXISTS powers; CREATE TABLE powers ( id INTEGER NOT NULL PRIMARY KEY AUTO_INCREMENT, na...
true
1d2c114c4692295cdecb36966ba56e0ac9729e00
SQL
yknot/rocStats
/scripts/getData.sql
UTF-8
2,874
4.53125
5
[]
no_license
USE roc; /* total number of rows*/ SELECT COUNT(*) AS Count FROM gear g INNER JOIN rentals r ON g.inventory_code = r.inventory_code ORDER BY r.rental_id; /*********************** TYPES OF GEAR ***********************/ /* Number of rentals per activity */ SELECT SUBSTRING(g.inventory_code, 1, 2) AS Activity , C...
true
080352553713e4e4c4a5309eba5ba7698b7130ec
SQL
fuchanghe/IMS3
/sql/Interaction_ontology_qualifier.sql
UTF-8
791
3.65625
4
[]
no_license
CREATE TABLE IF NOT EXISTS interaction_ontologies_qualifiers( interaction_ontology_qualifier_id BIGINT(10)PRIMARY KEY AUTO_INCREMENT, interaction_ontology_id BIGINT(10)NOT NULL, ontology_term_id BIGINT(10)NOT NULL, user_id ...
true
58eb72cb8ac985b2456bce81c0172fd5bcc9e933
SQL
akashiarnaud/HotelVao
/hotel.sql
UTF-8
6,285
3.34375
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.5.4.1 -- http://www.phpmyadmin.net -- -- Client : localhost -- Généré le : Mer 08 Mai 2019 à 08:43 -- Version du serveur : 5.7.11 -- Version de PHP : 5.6.18 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET...
true
6d1d6eb76e6281a0cd5a859eee11597b9a74d1f8
SQL
trineshchetty/Waiters-App
/tables.sql
UTF-8
802
3.046875
3
[]
no_license
create table weekdays ( id serial not null primary key, week_days text not null ); create table waiters ( id serial not null primary key, waiter text not null ); create table shifts ( id serial not null, waiter_id int not null, days_id int not NULL, FOREIGN key (waiter_id) REFERENCES w...
true
d3ca386dcffe70f5f1349dba8be9919dbf97c3ab
SQL
VijayMVC/JCC-Data-Warehouse
/SQLDB/dbo/Views/AA_PL_ALLOCATION_HISTORY_VIEW.sql
UTF-8
1,319
3.3125
3
[]
no_license
create view AA_PL_ALLOCATION_HISTORY_VIEW /* ** Returns a table to be used specifically with AA_PL_ALLOCATION_HISTORY_LIST_S ** ** Written : 08/03/2005 SH ** Last Amended: 03/05/2005 SRB, 20/09/2005 DB, 17/10/2007 DB */ as select H.P_AL_PRIMARY as [PRIMARY] , H.P_AL_DATE , H.P_AL_YEAR , H.P_AL_PERIOD , (H....
true
45f96fb73f40b38d21f6c6f53f87227b7ab29d65
SQL
ncollins-berkeley/W205
/exercise_1/transforming/transform.sql
UTF-8
11,870
3.59375
4
[]
no_license
create table d_providers as select providerid, hospitalname, state, hospitaltype, hospitalownership, emergencyservices from hospitals; create table d_procedures as select z.measurename as procedurename, z.measureid as procedureid from measures z INNER JOIN (select distinct ...
true
072776a8ce474b0bedf2571913633cc9e73e35d5
SQL
jeven2016/gdp
/conf/db/sqlfiles/mysql/smf_admin.sql
UTF-8
5,058
3.375
3
[]
no_license
-- 参考知识点 -- 1. SET sql_mode='NO_AUTO_VALUE_ON_ZERO'; 可以设置自动增长的步长从0开始,默认从1开始 -- 2. truncate table : 直接清空不考虑数据备份即历史记录 -- 3. 关于时间的一些小知识: -- 日期类型 日期格式、所占存储空间、日期范围 比较。 -- 日期类型 存储空间 日期格式 日期范围 -- ------------ --------- --------------------- ----------------------------------------- -- datetime ...
true
2b03a5755e989e317b638ac63841e4573cb068b9
SQL
Diegovitri/ControleEstoque
/ControleEstoque/scripts/insert do banco.sql
UTF-8
1,448
3.078125
3
[]
no_license
use controleestoque; select * from tb_construtora; insert into tb_construtora(nm_construtora) values('C & A Construtora'); select * from tb_obra; insert into tb_obra(nm_obra,ds_endereco,numero,cd_construtora,res_obra) values('Corrego do Oleo','Rua do Oleo - Mansour',130,1,'Pedro'), ('Residencial Maravilha','Rua da ...
true
7ab763a7b4043989757f2e49507e139374922285
SQL
AbraaoHonorio/dotNet-trainning
/Project 03 - API/TesteStore/Infra/Scripts/Procedures/spCreateAddress_31-12-2018_001.sql
UTF-8
824
2.609375
3
[]
no_license
DROP PROCEDURE IF EXISTS spCreateAddress; DELIMITER $$ CREATE PROCEDURE spCreateAddress ( IN IdP char(36), IN CustomerIdP char(36), IN NumberP VARCHAR(10), IN ComplementP VARCHAR(40), IN DistrictP VARCHAR(60), IN CityP VARCHAR(60), IN StateP VARCHAR(2), IN CountryP VARCHAR(2), IN ZipCodeP VARCHAR(8), ...
true
95491b0bb9ef82fc696136e25ba0283458fd7b70
SQL
jayhjlee/cg-exercise
/chronograph.sql
UTF-8
2,495
4.5
4
[]
no_license
-- #1 SELECT D.ID FROM DOCUMENT AS D FULL JOIN PAGE AS P ON D.ID = P.DOCUMENT_ID WHERE DOCUMENT_ID IS NULL; -- #2 SELECT R.TITLE, COUNT(*) AS PAGES FROM REPORT AS R, ( SELECT D.REPORT_ID FROM DOCUMENT AS D FULL JOIN PAGE AS P ON D.ID = P.DOCUMENT_ID WHERE P.DOCUMENT_ID IS NOT NUL...
true
7edb9006d176599e7cc5d8b3aeff6814cb7cc4e6
SQL
ytatus94/Leetcode
/SQL/1795_Rearrange_Products_Table.sql
UTF-8
877
3.6875
4
[]
no_license
-- 考 pivot table -- 方法 1 SELECT product_id, "store1" AS store, CASE WHEN store1 THEN store1 END AS price FROM Products WHERE store1 IS NOT NULL UNION SELECT product_id, "store2" AS store, CASE WHEN store2 THEN store2 END AS price FROM Products WHERE store...
true
dac90b9dade7754da2a74725dcab33fc9cfbc6b7
SQL
Deepshikha6/Database-for-child-care-management-system
/Views.sql
UTF-8
1,067
3.6875
4
[]
no_license
-- Count of sponsors for an orphanage---------- CREATE view sponsor_count as Select orphanage.Orphanage_Name, COUNT(sponsor.person_idPerson) as SponsorCount from orphanage join orphanage_has_sponsor on orphanage_has_sponsor.orphanage_idorphanage = orphanage.idorphanage join sponsor on sponsor.person_idPerson=orphanag...
true
2b7532a6923c2e6eff6d48cec1a56d662c50be4e
SQL
ChangMike/spring-boot-test
/sql/spring_boot_mybatis_test.sql
UTF-8
1,171
3.046875
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : my Source Server Version : 80015 Source Host : localhost:3306 Source Database : spring_boot_mybatis_test Target Server Type : MYSQL Target Server Version : 80015 File Encoding : 65001 Date: 2019-04-10 19:02:48 */ SET FOREIGN_KEY_CHECK...
true
534e581e2ce8a20bc732b403336c5cf0056f189f
SQL
MartimZanatti/ist-BD
/Projeto/Part3/storedprocstriggers.sql
UTF-8
1,117
3.609375
4
[]
no_license
DROP TRIGGER IF EXISTS insert_offer; DROP TRIGGER IF EXISTS verify_timestamp; DROP TRIGGER IF EXISTS insert_estado_paga; DELIMITER // CREATE TRIGGER insert_offer BEFORE INSERT ON oferta FOR EACH ROW BEGIN DECLARE quantidade INT; select count(1) into quantidade from ( select morada, codigo, data_inicio, data_fim...
true
494de4d514a14ddaab93280f0214854a8b183ff8
SQL
hiuchina/JAVA-000
/Week_08/第15课作业/sql/tb_order.sql
UTF-8
765
3.21875
3
[]
no_license
CREATE TABLE `tb_order` ( `order_id` bigint(20) NOT NULL COMMENT '订单ID', `order_sn` varchar(20) NOT NULL COMMENT '订单编号', `order_sum_price` decimal(10,2) NOT NULL COMMENT '订单总价', `order_count` int(11) NOT NULL COMMENT '商品总数量', `user_id` bigint(20) NOT NULL COMMENT '【购买商品的】用户ID,tb_user', `user_address_id` big...
true
9aec88d2a339f1af4c6de96f1c1eeec8df48a7c8
SQL
USHANIL/DataGrip.PokemonSqlLab
/FinalReport.sql
UTF-8
419
4
4
[]
no_license
select p.name as 'Pokemon Name' , t.trainername as 'Trainer Name', pt.pokelevel as Level, t1.name as 'Primary Type' , t2.name as 'Secondary Type' from pokemon_trainer pt inner join pokemons p on pt.pokemon_id = p.id inner join trainers t on pt.trainerID = t.trainerID join types as t1 on p.primary_type = t1.id join t...
true
6b8462bb57e30049a014711bdcd693ed36a744c3
SQL
PitAnalytics/skeleton
/test2.sql
UTF-8
990
3.546875
4
[]
no_license
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; -- -- Base de datos: `TESTBIS` -- CREATE DATABASE IF NOT EXISTS `TESTBIS` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; USE `TESTBIS`; -- -------------------------------------------------------- -- -- Estr...
true
56058dd0f6d523064709ae21c2f592df82ff7f39
SQL
batego/db_fintra
/fintra/administrativo/Tables/administrativo.demanda.sql
UTF-8
1,158
2.984375
3
[]
no_license
-- Table: administrativo.demanda -- DROP TABLE administrativo.demanda; CREATE TABLE administrativo.demanda ( id serial NOT NULL, reg_status character varying(1) NOT NULL DEFAULT ''::character varying, dstrct character varying NOT NULL DEFAULT ''::character varying, id_etapa integer NOT NULL, negocio charact...
true
0c100843323540a57a3bf7955a26d54ef79db175
SQL
folio-org/folio-install
/alternative-install/kubernetes-rancher/TAMU/ldp-derived-tables/sql/derived_tables/invoice_lines_fund_distributions.sql
UTF-8
2,690
3.890625
4
[ "Apache-2.0" ]
permissive
DROP TABLE IF EXISTS folio_reporting.invoice_lines_fund_distributions; -- Create a local table for Fund Distributions CREATE TABLE folio_reporting.invoice_lines_fund_distributions AS WITH funds_distr AS ( SELECT id AS invoice_line_id, json_extract_path_text(dist.data, 'code') AS fund_distribution_c...
true
2d486dc699462567db0fba2586d9bb44aa0f0102
SQL
phinemo/admin2
/phinemo_2018-10-08.sql
UTF-8
8,832
2.765625
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
# ************************************************************ # Sequel Pro SQL dump # Version 4541 # # http://www.sequelpro.com/ # https://github.com/sequelpro/sequelpro # # Host: 127.0.0.1 (MySQL 5.7.22) # Database: phinemo # Generation Time: 2018-10-08 08:31:45 +0000 # ***********************************************...
true
9c4eea7d07d29c78c5635d3f431de62ca728b5ea
SQL
figoxu/egghead_window_functions
/007_frame_clauses/window.sql
UTF-8
1,458
4.28125
4
[]
no_license
-- Aggregate functions create a running total when used -- with window functions + the ORDER BY clause. -- -- Remove ORDER BY to remove the running total behavior -- SELECT projects.name, backers.name, backers.contribution, SUM(contribution) OVER (PARTITION BY project_id ORDER BY contribution DESC) AS running_total FRO...
true
5ab62e3bca35ee4152631b0bb4c6a873e0887e80
SQL
oscar9705/VeterinariaBackend
/src/main/resources/db/migration/V2__initial.sql
UTF-8
1,940
3.03125
3
[]
no_license
CREATE TABLE public.mascota ( id_mascota serial NOT NULL, nombre_mascota character varying(100) NOT NULL, especie_mascota character varying(100) NOT NULL, edad_mascota character varying(100) NOT NULL, raza_mascota character varying(100) NOT NULL, sexo_mascota character varying(100) NOT NULL, ...
true
b72a4c53de7b37b738b2b8054654c3496c1c4e03
SQL
xiaorenwulinian/shop-admin
/document/sql/create_table_assigned_roles.sql
UTF-8
563
3.5
4
[]
no_license
CREATE TABLE `assigned_roles` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `role_id` int(10) unsigned NOT NULL, `entity_id` int(10) unsigned NOT NULL, `entity_type` varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, PRIMARY KEY (`id`), KEY `assigned_roles_entity_index` (`entity_id`,`entity_type`), KEY ...
true
d71950e73fad70647d2fc9f42f0fa7f90ebe79e6
SQL
onanongth/Database_Lab
/Lab7/Lab7_test.sql
UTF-8
2,271
3.5
4
[]
no_license
-- การเรียกใช้ EXECUTE test_2; EXEC test_2; BEGIN test_2; END; / CREATE OR REPLACE PROCEDURE test_2 IS --DECLARE vpid product.pid%type; vpname product.pname%type; vprice product.price%type; vlname location.lname%type; BEGIN SELECT pid,pname,price,lname INTO vpid,vpname,vprice,vlname FROM Product,Location WHER...
true
3a849f37dc228a1e82812facde975531226a093f
SQL
CCCHENNNN/DK-Information-Integration
/Lab2/lab.sql
UTF-8
3,312
3.140625
3
[]
no_license
1. PREFIX foaf: <http://xmlns.com/foaf/0.1/> PREFIX dbr: <http://dbpedia.org/resource/> PREFIX dbo: <http://dbpedia.org/ontology/> PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> SELECT * WHERE { ?p dbo:birthPlace dbr:Digne-les-Bains. } LIMIT 100 2. PRE...
true
bd19453624efbcab90acccf3ad22d063db2a1701
SQL
lamproot/telegramh5
/DB/user_code_log.sql
UTF-8
1,489
3.109375
3
[ "WTFPL" ]
permissive
/* Navicat Premium Data Transfer Source Server : localhost Source Server Type : MySQL Source Server Version : 50627 Source Host : localhost Source Database : telegram Target Server Type : MySQL Target Server Version : 50627 File Encoding : utf-8 Date: 05/16/2018 20:45:...
true
ea07e37b09c3bf24219afe18deaacba7bc4d8806
SQL
mahmoudahmedd/payment-gateway-library
/Database Files/database.sql
UTF-8
2,218
3.328125
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 5.0.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Aug 01, 2021 at 03:22 PM -- Server version: 10.4.17-MariaDB -- PHP Version: 7.4.14 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
61d0156dcb898efc9debd042c723e42b9c5ceccc
SQL
miyasaka/Frontire
/resources/data/selNewTopicList.sql
UTF-8
1,271
3.546875
4
[]
no_license
SELECT C.CID AS CMID, CB.MID AS MEMBERID, M.NICKNAME, C.BBSID, CB.ENTRYTYPE, CB.TITLE AS TITLE, CB.COMNO AS COMNO, C.TITLE AS COMMUNITY, TO_CHAR(C.UPD,'yyyy年mm月dd日 hh24:mi') AS UPDATE...
true
4c68cdcaa4f0034e0b7d8b7a9b815225bae5a485
SQL
ferreirabner/SQL
/PI_III/zadmin_banco_DISCIPLINA.sql
UTF-8
2,947
2.84375
3
[ "MIT" ]
permissive
-- MySQL dump 10.13 Distrib 5.7.19, for Linux (x86_64) -- -- Host: 192.168.77.195 Database: zadmin_banco -- ------------------------------------------------------ -- Server version 5.5.52-0+deb8u1 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_...
true
fc4fad4cfa01cc490572f5b07a30073b393f6313
SQL
NovemBit/dev-log
/src/DataMapper/Migration/mysql.sql
UTF-8
704
3.515625
4
[]
no_license
CREATE TABLE `logs` ( `id` INT PRIMARY KEY AUTO_INCREMENT, NAME VARCHAR(16), TYPE VARCHAR(32) ); CREATE UNIQUE INDEX `logs_hash_uindex` ON `logs` (NAME); CREATE UNIQUE INDEX `logs_id_uindex` ON `logs` (id); CREATE TABLE `logs_data` ( `id` INT PRIMARY KEY AUTO_INCREMENT, `log_id` INT, ...
true
455fb9943153d82424d1a10bfe1e3e86309f195d
SQL
mr1hm/shuttle-employee-management
/server/sql/structure/operator_availability.sql
UTF-8
1,393
2.65625
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 5.7.28-0ubuntu0.18.04.4 - (Ubuntu) -- Server OS: Linux -- HeidiSQL Version: 10.2.0.5599 -- -------------------------------------------------------- /*!4...
true
dadcf6a4036654867853c4295017c51424fe7ee4
SQL
dibrovsd/scripts
/asan/scripts/asan_to_crm.sql
UTF-8
1,032
3.03125
3
[]
no_license
/** * Данные для сверки с CRM */ drop table tmp_crm_copy; create table tmp_crm_copy as select t.id, t.ins_legal_itin, t.ins_person_pin, t.n_contract, 'auto' as product from docflow_document2 t where t.canceled = false and t.n_contract is not null and t.n_contract != '' union ALL select t.id, t.ins_legal_i...
true
695bbd0f1557271cc975511647b9b7df074fb35c
SQL
abeauquel/projet-capture-serveur-php
/data/station_meteo.sql
UTF-8
3,924
2.90625
3
[]
no_license
-- -- PostgreSQL database dump -- -- Dumped from database version 10.5 (Ubuntu 10.5-0ubuntu0.18.04) -- Dumped by pg_dump version 10.5 (Ubuntu 10.5-0ubuntu0.18.04) SET statement_timeout = 0; SET lock_timeout = 0; SET idle_in_transaction_session_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings...
true
c49020af13f94e969568cab61103afd8724d25fd
SQL
pentaqa/autotest
/de-myq/partition_testdb.sql
UTF-8
10,636
2.96875
3
[]
no_license
drop table if exists t_partition_range1; drop table if exists t_partition_range1_imsi; create table t_partition_range1( xdate int(8) default 0, xhour varchar(2) not null default '00', tag1 varchar(100) not null default '', tag2 varchar(300) not null default '', val int(10) unsigned not null default '0', key ndx_x...
true
b465b5d3b4a7dcd342ebbc2342704e56d8eec533
SQL
rbrouwer/dewin
/application/tests/files/sql/test_original.sql
UTF-8
13,370
2.859375
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
de1ea28845298eb6419560cbd36695aa42ce2369
SQL
axle12693/cs313-php
/db/forum_db_Setup.sql
UTF-8
4,158
3.5625
4
[]
no_license
CREATE TABLE App_User_Type ( user_type_id SERIAL PRIMARY KEY, user_type_title VARCHAR(30) ); INSERT INTO App_User_Type (user_type_title) VALUES ('Global Admin'), ('Forum Moderator'), ('User'); CREATE TABLE App_User ( app_user_id SERIAL PRIMARY KEY, user_type_id SERIAL REFE...
true
fed874794db442af7cb9fe5074562ffbc19006bb
SQL
ProgrammersForABetterTomorrowYesterday/FC_PolyDart
/util/initdb.sql
UTF-8
157,674
3.484375
3
[]
no_license
-- MySQL Script generated by MySQL Workbench -- Tue 01 Dec 2015 11:47:32 AM EST -- 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_M...
true
4323d1578efe28c4cb2a3a34d4f8d9c5b0535eff
SQL
jilek/Pewlett-Hackard-Analysis
/Queries/Employee_Database_challenge.sql
UTF-8
1,560
4.53125
5
[]
no_license
-- Use Dictinct with Orderby to remove duplicate rows SELECT DISTINCT ON (______) _____, ______, ______, ______ INTO nameyourtable FROM _______ ORDER BY _____, _____ DESC; ---------------- -- Deliverable 1: The Number of Retiring Employees by Title ---------------- -- Steps 1 to Step 7: Create retirement_titles SEL...
true
3956b016b0983d41ed201bd98cb47fc5371e7d56
SQL
Ebon97/DevelopmentProject2
/appointment.sql
UTF-8
3,485
3.125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Apr 09, 2019 at 06:37 PM -- Server version: 10.1.28-MariaDB -- PHP Version: 7.1.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
645eec04dfebfe25c36a9e1bd889664b8e580b2f
SQL
lgcarrier/AFW
/5.2.3/Database/Constraints/AFW_11_PARMT_AFW_UK1.sql
UTF-8
122
2.546875
3
[ "MIT" ]
permissive
SET DEFINE OFF; ALTER TABLE AFW_11_PARMT_AFW ADD ( CONSTRAINT AFW_11_PARMT_AFW_UK1 UNIQUE (CODE) ENABLE VALIDATE) /
true
453b525c86f086a5d457a3046680b919ab24802b
SQL
HuiAhh/travel-angency-course-work
/db/sql-fai;ure-procedure/2.calc_day_income.sql
UTF-8
6,704
3.890625
4
[]
no_license
DROP PROCEDURE if EXISTS calc_day_income; -- --in->日期,按半月显示折线图 -- {{ date xxxx.xxxx }}: ¥cash -- 存储过程 -- ret incomeByDay -- var person child gmtcreated cancel_pay_ratio -- where paystatus gmtmodified delete -- link orderid orderdetailid travelpathid -- calc ratio -- param day DELIMITER // -- 计算日收入 CREATE PROCEDU...
true
4922a85935ced0b8053a249f016d2550b6ff5d97
SQL
EmmeFreeze/EmmeDomotica
/Database/EmmeDomoticadb.sql
UTF-8
396
3.34375
3
[ "MIT" ]
permissive
-- Database name 'EmmeDomotica' -- Created 11/04/2017 -- Database creation CREATE DATABASE IF NOT EXISTS EmmeDomotica; USE EmmeDomotica; -- Table to store devices CREATE TABLE IF NOT EXISTS device ( mac_address VARCHAR(18) NOT NULL, descrizione ENUM('led', 'door', 'bulb') NOT NULL, status BOOLEAN, num...
true
7a86cc923f7a1e1ed91f47f09c49d87e629b0bab
SQL
krishemenway/sloshydoshman
/SloshyDoshMan.Service/PlayedGames/PlayerPlayedWave.sql
UTF-8
523
2.875
3
[]
no_license
CREATE TABLE public.player_played_wave ( steam_id varchar(22) NOT NULL, wave integer NOT NULL, played_game_id uuid NOT NULL, kills integer NOT NULL DEFAULT 0, perk text COLLATE pg_catalog."default", CONSTRAINT px_player_played_wave PRIMARY KEY (steam_id, played_game_id, wave) ) WITH (OIDS = FALS...
true
d468ccd96f56c70e5aa5995e6bc1d2cf13be10f6
SQL
bytesweaver/cicada-web
/src/main/resources/sql/author.sql
UTF-8
321
2.734375
3
[]
no_license
CREATE TABLE author( author_id VARCHAR(32) NOT NULL -- -- 作者ID -- , author_name VARCHAR(256) COMMENT "作者名字", birth_date DATE COMMENT "出生日期", birth_palace VARCHAR(256) COMMENT "出生地点", nationality VARCHAR(64) COMMENT "出生国家", sex CHAR(1) COMMENT "性别", PRIMARY KEY (author_id) )
true
82d5eff6294b227253f36337cf20aa4b2d794b09
SQL
ilyakats/CUNY-DATA607
/Project 3/db_creation_nn_no.sql
UTF-8
1,261
4
4
[]
no_license
# Nkasi Nedd # Nnaemezue Obi-Eyisi CREATE SCHEMA IF NOT EXISTS datascienceskills; USE datascienceskills; DROP TABLE IF EXISTS skillsdata; DROP TABLE IF EXISTS Skills; DROP TABLE IF EXISTS Categories;Location DROP TABLE IF EXISTS Location; # Categories table to store information about categories of skills. CREATE TA...
true
2cf78b08afa83ee1fe91a5fb0dc058ddaa1a6c1b
SQL
slientServer/evaluationSystem
/Data/evaluation.sql
UTF-8
18,706
3.15625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.3.11 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: 2016-09-06 17:12:10 -- 服务器版本: 5.6.24 -- PHP Version: 5.6.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @...
true
ccb7523ee57413e3976d12c3b42c312cbf097a8b
SQL
Good725/ideabubble-lamp
/application/model/model-20191217160200.sql
UTF-8
2,671
2.859375
3
[]
no_license
/* ts:2019-12-05 08:22:00 */ INSERT IGNORE INTO `engine_users` (`role_id`, `email`, `password`, `name`, `surname`, `timezone`, `registered`, `email_verified`, `can_login`, `deleted`, `status`) (SELECT `id`, 'trainer@courseco.co', 'b5a6123dbe6a28b25a68566c03194898ecccfc14d527c5bb...
true
595a0a30ff171688ba6d10d0627c44e8478ab502
SQL
shugamoe/mpcs_db
/a3/query.sql
UTF-8
1,293
4.0625
4
[]
no_license
-- Queries for ASsignment 3, Julian McClellan USE jmcclellanDB; -- Find the the author and score of the 10 highest scoring CMV_Submissions SELECT DISTINCT(author), score FROM ( SELECT * FROM ( SELECT * FROM CMV_Submission ORDER BY score DESC LIMIT 10 ) AS t1 ) AS t2; -- Find the distinct authors o...
true
34dae79ae1e93bb0137fba117b6dd565f83ca33c
SQL
oehrlis/docker
/samples/common/setup/04_eus_config.sql
UTF-8
2,671
2.890625
3
[ "Apache-2.0" ]
permissive
---------------------------------------------------------------------------- -- Trivadis AG, Infrastructure Managed Services -- Saegereistrasse 29, 8152 Glattbrugg, Switzerland ---------------------------------------------------------------------------- -- Name......: 04_eus_config.sql -- Author....: Stefan Oehrli ...
true
204db48bc9dd6fc828e42cefbadae929470278bc
SQL
Gio1378/M2iFormation
/95_jQueryTPVersionAvancee/ressources/sql/bd_ajax_create_insert.sql
UTF-8
717
3.21875
3
[]
no_license
13DROP DATABASE IF EXISTS ajax; CREATE DATABASE ajax DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; USE ajax; CREATE TABLE ajax.pays ( id_pays VARCHAR(4) NOT NULL , nom_pays VARCHAR(50) NOT NULL, PRIMARY KEY (id_pays) ) ENGINE = MYISAM ; INSERT INTO ajax.pays (id_pays, nom_pays) VALUES ('033', 'France'), ('03...
true