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
49ccd65a482b21063cafbc6a02d81c16e9ac6626
SQL
hsharma263/sql-challenge
/EmployeeSQL/employee_db_tables.sql
UTF-8
1,310
3.8125
4
[]
no_license
-- DATA ENGINEERING -- DROP TABLE employees; -- DROP TABLE departments; -- DROP TABLE dept_emp; -- DROP TABLE dept_manager; -- DROP TABLE salaries; -- DROP TABLE titles; -- Creating Tables CREATE TABLE employees ( emp_no INT NOT NULL, emp_title_id VARCHAR NOT NULL, birth_date DATE NOT NULL, first_name VARCHAR NO...
true
52d536ca54b1e577b64567e8c598ede8b86995e1
SQL
iunupe/sql-challenge
/EmployeeSQL/homework_sql_queries.sql
UTF-8
3,332
3.953125
4
[]
no_license
CREATE TABLE "employees" ( "emp_no" INT NOT NULL, "emp_title_id" VARCHAR(100) NOT NULL, "birth_date" DATE NOT NULL, "first_name" VARCHAR(100) NOT NULL, "last_name" VARCHAR(100) NOT NULL, "sex" VARCHAR(10) NOT NULL, "hire_date" DATE NOT NULL, CONSTRAINT "pk_employees" PRIMAR...
true
80595b5267404c2d3e7960fce08ed62c0c810865
SQL
mybrainisout/SIO2-box
/SIO2/Prog/Projets/MyPersonalBank/Base de Donnée/MyPersonalBank.sql
UTF-8
1,897
3.5625
4
[]
no_license
CREATE DATABASE MyPersonalBank; USE MyPersonalBank; /* CREATE TABLE */ CREATE table COMPTE(cpt_id int NOT NULL PRIMARY KEY auto_increment, cpt_nom varchar(45), cpt_type varchar(45), cpt_montant float, cpt_bnqid int); CREATE table BANQUE(bnq_id int NOT NULL PRIMARY KEY auto_increment, bnq_nom varchar(45), bnq_utlid i...
true
ded3f33d93ea0f9b4bf10d36e97e361d16a96ae1
SQL
ariefmulya/PetakUmpet
/Skeleton/Project/app/AppName/res/sql/01_schema.sql
UTF-8
1,463
3.40625
3
[]
no_license
CREATE TABLE userdata ( id serial, userid varchar(25), name varchar(100), password text, status varchar(10), is_admin boolean, parent_id integer, first_login boolean, PRIMARY KEY (id), FOREIGN KEY (parent_id) REFERENCES userdata (id) ); CREATE TABLE user_profile ( id serial, user_id integer, ...
true
0c6281992de3291999bb6e90767a0dd99c437bbf
SQL
AgoraTopika/database
/core_db_schema.sql
UTF-8
677
3.34375
3
[]
no_license
CREATE TABLE shop_category( id VARCHAR(36) PRIMARY KEY, category_name VARCHAR(128), date_added TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW() ); CREATE TABLE shop( id VARCHAR(36) PRIMARY KEY, category_id VARCHAR(32) REFERENCES shop_category(id), shop_name VARCHAR(128), street...
true
fd1e31e4dc02881f29c6464cd7d904ee8b4dc0af
SQL
pacanDude/ForumApp
/ForumService/Functions.sql
UTF-8
4,412
3.6875
4
[]
no_license
CREATE FUNCTION GetAllUsers () RETURNS TABLE AS RETURN (select name from OneUser) create proc RegisterUser (@name varchar(max), @password varchar(max), @foto varbinary(max), @age int, @rating int,@ratingAnswers int,@ratingQwery int,@about nvarchar(max)) as begin insert into OneUser(name, ...
true
bbfd857df79ae60ded0eb26252cc0162a3697b9d
SQL
Thinhjapan/Railway14
/SQL/Assignment 2/Testing_System_Assignment_2.sql
UTF-8
6,092
3.59375
4
[]
no_license
DROP DATABASE IF EXISTS Testing_System; CREATE DATABASE Testing_System; USE Testing_System; ----------- Create table 1: Department - phong ban---------- DROP TABLE IF EXISTS `DEPARTMENT`; CREATE TABLE `Department` ( DepartmentID TINYINT UNSIGNED PRIMARY KEY, DepartmentName VARCHAR(50) NOT NULL UNIQ...
true
e7433d83ce3a8f7b67eaf6d90539cdcced91b50e
SQL
alexdeassis7/CursoMistico
/review-service/ScriptsDB/review.sql
UTF-8
412
2.515625
3
[]
no_license
DROP TABLE IF EXISTS `reviews`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!50503 SET character_set_client = utf8mb4 */; CREATE TABLE `reviews` ( `idreview` int unsigned NOT NULL AUTO_INCREMENT, `rating` int DEFAULT NULL, `name` varchar(45) DEFAULT NULL, `user` varchar(45) DEFAULT N...
true
0bf5cc591450c743b501e10b8deb79e27af6d5eb
SQL
Tanzin/nithcareerbox
/sqlfile/nithcareerbox.sql
UTF-8
1,783
2.90625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.4.1deb2ubuntu2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Jul 15, 2016 at 08:32 PM -- Server version: 5.7.12-0ubuntu1.1 -- PHP Version: 7.0.4-7ubuntu2.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_...
true
1673ae56c81c54db533d69541d4f97a51adf0647
SQL
ovaistariq/DBT3-scripts-for-MySQL
/queries/sqlserver/13.sql
UTF-8
483
3.6875
4
[ "Artistic-1.0" ]
permissive
-- @(#)13.sql 2.1.8.1 -- TPC-H/TPC-R Customer Distribution Query (Q13) -- Functional Query Definition -- Approved February 1998 :b :x :o SELECT C_COUNT, COUNT(*) AS CUSTDIST FROM (SELECT C_CUSTKEY, COUNT(O_ORDERKEY) FROM CUSTOMER left outer join ORDERS on C_CUSTKEY = O_CUSTKEY AN...
true
a7f53e240ee53dd47f4198e8347fa4297f90a194
SQL
ArthurSchiavom/gestao-veiculos-partilhados--projeto-academico
/Modelo Relacional/Script/Procedures.sql
UTF-8
2,539
3.703125
4
[]
no_license
create or replace procedure register_bicycle( p_weight vehicles.weight%type, p_aerodynamic_coefficient vehicles.aerodynamic_coefficient%type, p_frontal_area vehicles.frontal_area%type, p_bicycle_size bicycles.bicycle_size%type, p_description vehicles.DESC...
true
23ffcce1513e875b5aab07ba5f3fb3fe55d4db1b
SQL
imavishek/StairSupplies
/db/changes/2010/2010-03-22 - mysql structure.sql
UTF-8
42,240
3.328125
3
[]
no_license
-- ---------------------------------------------------------------------- -- MySQL Migration Toolkit -- SQL Create Script -- ---------------------------------------------------------------------- SET FOREIGN_KEY_CHECKS = 0; DROP DATABASE IF EXISTS `ironbaluster_dbo`; CREATE DATABASE IF NOT EXISTS `ironbaluster_dbo` ...
true
ecd2b01b3585f1a494717f519db0b1bab58e9cbe
SQL
jomedinas7/luciddb
/farrago/initsql/createMgmtViews.sql
UTF-8
47,827
3.265625
3
[ "Apache-2.0", "GPL-2.0-only", "GPL-1.0-or-later" ]
permissive
-- $Id$ -- This script creates a view schema used for database management !set verbose true -- create views in system-owned schema sys_boot.mgmt create or replace schema sys_boot.mgmt; set schema 'sys_boot.mgmt'; set path 'sys_boot.mgmt'; create or replace function repository_properties() returns table(property_name...
true
6dfb64a49e72d8e820dbe2abe49d1ad60325b30c
SQL
luguanxing/JavaWeb-Apps
/01-JavaWeb网上商城/数据库结构.sql
UTF-8
3,238
3.4375
3
[]
no_license
/* SQLyog 企业版 - MySQL GUI v8.14 MySQL - 5.7.3-m13 : Database - db_store ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHEC...
true
2380efa7af08dcabe9a2ce573f8e39b416a04825
SQL
aulianurzaytun/kegiatan-praktikum-3
/akademik.sql
UTF-8
1,719
3.0625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.1.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 21, 2021 at 09:10 PM -- Server version: 10.4.21-MariaDB -- PHP Version: 8.0.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
7c132e0fe9d474402e1e0c889b57d6a7cb3a8a8f
SQL
williamvds/dis
/scripts/importGtrOutcomes.sql
UTF-8
9,001
3.578125
4
[]
no_license
-- Run with -- $ psql -U <username> -d <database> -f importGtrOutcomes.sql -- Ensure the outcomes.xml file exists in the PostgreSQL data directory DO $$ DECLARE file text := 'outcomes.xml'; xmlRecords xml; outcome record; nss text[][2] := array[ array['api', 'http://gtr.rcuk.ac.uk/gtr/api'], array['out', 'http:...
true
fc9ce123e44f46511d082e75f5446c441dd03ebb
SQL
bxxtxx/sql
/20200715.sql
UTF-8
7,512
4.375
4
[]
no_license
오라클 객체 (object) table - 데이터 저장 공간 . ddl 생성, 수정, 삭제 view - sql(쿼리다) 논리적인 데이터 정의, 실체가 없다 view 구성하는 테이블의 데이터가 변경되면 view 결과도 달라지더라 sequence - 중복되지 않는 정수값을 반환해주는 객체 유일한 값이 필요할 때 사용할 수 있는 객체 nextval , currval index - 테이블의 일부 컬럼을 기준으로 미리 정렬해 놓은 데이터 ==> 테이블 없이 단독적으로 생성 불가, 특...
true
a9407d5beb2eda8aebe431f0eda1f58f1c2d8a5c
SQL
iamsteeve/basic-money-tracking
/generated-sql/default.sql
UTF-8
2,494
3.59375
4
[]
no_license
# This is a fix for InnoDB in MySQL >= 4.1.x # It "suspends judgement" for fkey relationships until are tables are set. SET FOREIGN_KEY_CHECKS = 0; -- --------------------------------------------------------------------- -- account -- --------------------------------------------------------------------- DROP TABLE I...
true
be7fe7ad4c6dbe1ecc8711ce0e6529d102684aa0
SQL
Antloup/SereProject
/dbInitScript.sql
UTF-8
2,069
3.265625
3
[ "MIT" ]
permissive
-- 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='TRADITIONAL,ALLOW_INVALID_DATES'; -- ----------------------------------------------------- -- Schema mydb -- -...
true
531612c13ae08984ce1cfb341b6d9d2dbb3aa959
SQL
s-darling/TestForLink
/EBXworkspace/Libraries/EBX Core/ebx_CD_5.4.0.0907-0001/ebx.software/files/ddl/PostgreSQL/ddl12_HVM.1_newIn_5.0.0.sql
UTF-8
1,767
3
3
[]
no_license
CREATE TABLE EBX_HV_TX ( tx_id INTEGER NOT NULL , user_id INTEGER, action_id INTEGER, home_id INTEGER, session_id INTEGER, timestamp BIGINT, uuid VARCHAR(36), execution_info VARCHAR(10485760), CONSTRAINT EBX_HV_TX_PK PRIMARY KEY (tx_id)); CREATE SEQUENCE EBX_HV_TX_SEQ START WITH 1 INCREMENT BY 1; C...
true
1171f65bd2be261c9b3566a5bed35d400f41a689
SQL
cem-ege-saygili/CoursePlanner
/inputs/sampleSelectQueries/select1.sql
UTF-8
1,122
3.921875
4
[]
no_license
select SUBSTR(i.InstructorName, INSTR(i.InstructorName, ',') + 1, LENGTH(i.InstructorName) - INSTR(i.InstructorName, ',')) || ' ' || SUBSTR(i.InstructorName, 0, INSTR(i.InstructorName, ',')) as "Course Instructor First & Last Name", c.CourseSubject || ' ' || c.CourseCatalog as "Course Name", c.CourseCareer as "Cou...
true
72faae9b1940d39dfc441cdc1ebfdfc0bdc08795
SQL
xuboxun/BlogAPI
/db/blog_v0.0.2.sql
UTF-8
11,167
3.203125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.4.1deb2ubuntu2.1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: 2018-11-13 20:44:41 -- 服务器版本: 5.7.24-0ubuntu0.16.04.1 -- PHP Version: 7.0.32-0ubuntu0.16.04.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET...
true
5602b8c60f43d332229c49daba125b0a72bee1f8
SQL
LassiViitakoski/SQL-and-PostgreSQL-The-Complete-Developer-s-Guide
/unions/unions.sql
UTF-8
787
4.34375
4
[]
no_license
-- Tables structure CREATE TABLE users ( id SERIAL PRIMARY KEY, first_name VARCHAR, last_name VARCHAR ); CREATE TABLE products ( id SERIAL PRIMARY KEY, name VARCHAR, department VARCHAR, price INTEGER, weight INTEGER ); CREATE TABLE orders ( id SERIAL PRIMARY KEY, user_id INTEGER REFERENCES users(...
true
af90224745d79813d81c0131b8a2f9ddfde7c886
SQL
teamshield/greenfield-api-reviews
/schema.sql
UTF-8
2,493
3.921875
4
[]
no_license
DROP DATABASE IF EXISTS greenfield; CREATE DATABASE greenfield; \c greenfield; CREATE TABLE characteristics ( id INTEGER, product_id INTEGER, name VARCHAR(10) ); CREATE TABLE reviews ( id SERIAL, product_id INTEGER, rating INTEGER, date DATE DEFAULT NOW(), summary VARCHAR(150) DEFAULT '', body VAR...
true
aa0be9e446e252dd670b8484bc40cabe9bb169a3
SQL
sinhu-jung/mariadb_practices
/sql연습/select-기본.sql
UTF-8
1,632
4.15625
4
[]
no_license
-- select 연습 select * from departments; select dept_no, dept_name from departments; -- concat, alias(as, 생략 가능) select concat(first_name, " ", last_name) as name, gender, hire_date from employees; select concat(first_name, " ", last_name) name, gender, hire_date from employees; select concat(first_name, " ", last_name...
true
1a70fbd3a35e19380c721228cc3435bb01f87976
SQL
JcGaara/SGA-PLSQL-OPE
/SGA-OPERACION/Procedures/P_CONS_EQUIPOS_IW.sql
UTF-8
847
2.8125
3
[]
no_license
CREATE OR REPLACE PROCEDURE OPERACION.P_CONS_EQUIPOS_IW(a_codsolot in solot.codsolot%type, o_resultado out PQ_INTRAWAY.T_CURSOR) IS V_CURSOR PQ_INTRAWAY.T_CURSOR; BEGIN OPEN V_CURSOR FOR SELECT CUSTOMER_ID, COD_ID, TIPO_SERVICIO, ID_PRODUCTO, CASE WHEN IN...
true
924c9bf4e2db1b1bc64784e6b5868f0adefb2317
SQL
rrowland17/sql-challenge
/SQLfiles/sales.sql
UTF-8
346
4.09375
4
[]
no_license
--List all employees in the Sales department --including their employee number, last name, first name, and department name. SELECT emp.emp_no, emp.first_name, emp.last_name, dp.dept_name FROM dept_emp as d_emp JOIN employees as emp ON (d_emp.emp_no = emp.emp_no) JOIN departments as dp ON (d_emp.dept_no = dp.dept_no) W...
true
473997e4dcbbbbfba4501aabda825b0f4ff61c26
SQL
lyzilvia/lyzilvia
/Practice/SQL/Projects/SQLQuery1.sql
GB18030
567
3.53125
4
[]
no_license
create database test_; create table S (NO_ char(2) Unique Not Null, NAME char(10) Unique, SEX char(2), AGE int, CLASS char(5), primary key (NO_)); insert into S values(25, '', '', 21, '95031'); insert into S values(10, '', 'Ů', 20, '95101'); insert into S(CLASS, NO_, NAME) values('95031', 30, '֣'); cre...
true
35403267a1ce8effeb26071f9d3ea8496bbbd60f
SQL
ulexxander/nats-inspector
/server/migrations/002.subscriptions.sql
UTF-8
266
3.234375
3
[ "Apache-2.0" ]
permissive
CREATE TABLE subscriptions ( id integer PRIMARY KEY AUTOINCREMENT, connectionId integer NOT NULL, subject text NOT NULL, dateCreated text NOT NULL DEFAULT CURRENT_TIMESTAMP, dateUpdated text, FOREIGN KEY (connectionId) REFERENCES connections(id) );
true
fda0c8f7a42216d73eb4241dd963400d80a946ff
SQL
GoogleCloudPlatform/professional-services
/tools/bigquery-zos-mainframe-connector/gszutil/test-scripts/bq_export.sql
UTF-8
957
2.84375
3
[ "Apache-2.0" ]
permissive
/* * Copyright 2022 Google LLC All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicab...
true
ca6c3a563be6cab12ebd873fd7784b98358f1302
SQL
iwanmitowski/SoftUniBeforeCourse
/SoftUniDBJanuary2021/TableRelationsExercise/03.Problem.sql
UTF-8
653
3.640625
4
[]
no_license
CREATE TABLE Students ( StudentID INT PRIMARY KEY IDENTITY, [Name] VARCHAR(30) NOT NULL ) CREATE TABLE Exams ( ExamID INT PRIMARY KEY IDENTITY(101,1), [Name] VARCHAR(30) NOT NULL ) CREATE TABLE StudentsExams ( StudentID INT FOREIGN KEY REFERENCES Students(StudentID), ExamID INT FOREIGN KEY REF...
true
bd7d51c3f257951292378e0f3e46d13f211dfbb8
SQL
mcmd1962/dotfiles
/.psqlrc.aliases/database/locks.sql
UTF-8
431
3.546875
4
[]
no_license
SELECT bl.pid AS blocked_pid, a.usename AS blocked_user, kl.pid AS blocking_pid, ka.usename AS blocking_user, a.query AS blocked_statement FROM pg_catalog.pg_locks bl JOIN pg_catalog.pg_stat_activity a ON bl.pid = a.pid JOIN pg_catalog.pg_locks kl JOIN pg_catalog.pg_stat_activit...
true
e4dd5a1a137248fdb943b074e162b13ead79d756
SQL
indoctrinatedrecluse/Community_App
/src/main/webapp/db/comments.sql
UTF-8
250
2.78125
3
[]
no_license
CREATE TABLE comments ( comment_id NUMBER NOT NULL, comment_content VARCHAR2(250) DEFAULT NULL, post_id NUMBER NOT NULL, timestamp TIMESTAMP NOT NULL, user_id NUMBER NOT NULL, CONSTRAINT comments_pk PRIMARY KEY (comment_id) );
true
f8dec717783a2f94719dd2934d7ff8bedcdf63eb
SQL
sylr/mike
/functions/xstatf.sql
UTF-8
1,987
3.265625
3
[]
no_license
-- Mike's Function -- vim: set tabstop=4 expandtab autoindent smartindent: -- author: Sylvain Rabot <sylvain@abstraction.fr> -- date: 04/03/2011 -- copyright: All rights reserved CREATE OR REPLACE FUNCTION mike.xstatf( IN in_id_inode bigint ) RETURNS mike.inode_full_t AS $__$ -- Version: MIKE_VERSION SE...
true
295ad31909df7240fd188433ef2da9a5863c79fa
SQL
ZerocoolVishal/medinfi-work
/db/medinfi.sql
UTF-8
6,138
3.203125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Sep 03, 2018 at 06:15 AM -- Server version: 10.1.32-MariaDB -- PHP Version: 7.2.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @O...
true
f9714715e9339d60a1508c798848bb1bd738a08f
SQL
renlanchuke/zhihuspider
/setup.sql
UTF-8
5,250
3.3125
3
[]
no_license
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Struct of table `cookies` -- CREATE TABLE IF NOT EXISTS `cookies` ( `email` varchar(100) NOT NULL, `password` varchar(100) NOT NULL, `name` varchar(100) NOT NULL, `hash` varchar(100) NOT NULL, `cookie` varchar(500) NOT NULL ) ENGINE=My...
true
a93d46c87e0928474f79b516f65296d3902d0a7a
SQL
trananhdung1983/mavengggg
/mavengggg/src/database.sql
UTF-8
233
2.859375
3
[]
no_license
create table appuser ( id number, firstName varchar2 (30), lastName varchar2 (30), userName varchar2 (30), password varchar2 (40), constraint appuser_pk primary key (id), constraint app_username_uk unique (userName) );
true
a37376733701f81bbc07493b20e6e78a920efafe
SQL
btfurukawatkr/demo-jpa
/src/main/resources/schema-postgresql.sql
UTF-8
424
2.78125
3
[]
no_license
-- Table: parent DROP TABLE IF EXISTS parent; CREATE TABLE parent ( id numeric ); -- Table: child DROP TABLE IF EXISTS child; CREATE TABLE child ( id numeric, parent_id numeric ); -- Sequence: hibernate_sequence DROP SEQUENCE IF EXISTS hibernate_sequence; CREATE SEQUENCE hibernate...
true
ad4f5a25aeb5959e831136daa4889f11c8c45459
SQL
bernardinooctavio/BIBLIOTECAPREPA
/biblioprepa(2).sql
UTF-8
10,596
3.15625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.5.1 -- http://www.phpmyadmin.net -- -- Servidor: localhost -- Tiempo de generación: 24-05-2019 a las 01:41:31 -- Versión del servidor: 5.5.21 -- Versión de PHP: 5.4.3 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER...
true
69fa60463a560f06556d0a05e26b00344c48b345
SQL
naienko/chinook-naienko
/total_invoices_2011.sql
UTF-8
135
2.96875
3
[]
no_license
--How many Invoices were there in 2011? SELECT COUNT(i.InvoiceId) AS InvoicedIn2011 FROM Invoice i WHERE YEAR(i.InvoiceDate) = '2011';
true
53a94c136e24a0099e68bcfa62fd283bc1bf02c9
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day14/select1755.sql
UTF-8
178
2.671875
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-13T17:55:00Z' AND timestamp<'2017-11-14T17:55:00Z' AND temperature>=19 AND temperature<=54
true
85f59ecc99fb7c7ba846ae63e420607d8f2e52fb
SQL
datyasuo1/LapTrinhC
/bai 6/SQLQuery13.sql
UTF-8
419
2.515625
3
[]
no_license
CREATE DATABASE [SalesDB] ON PRIMARY ( NAME = 'SalesDB', FILENAME ='C:\Program Files\Microsoft SQL Server\MSSQL11. MSSQLSERVER\MSSQL\DATA\SalesDB.mdf' , SIZE = 3072KB , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB ), FILEGROUP [MyFileGroup] ( NAME = 'SalesDB_FG', FILENAME = 'C:\Program Files\Microsoft SQL Server\MSSQL11. M...
true
d58bb390b351c1c4c6804b5dc6d9a39ea097c355
SQL
farisally23/C43-A2
/queries/q10.sql
UTF-8
1,150
4.28125
4
[]
no_license
set search_path to a2; CREATE VIEW WinLossTable2014 AS ( select winner as pname, wins.courtname as court, wins.year as year, wins, losses from (select pname as winner, courtname, year, count(*) as wins from event join player on winid = pid join court on court.courtid = event.courtid where year = 201...
true
4024e27dc6f2b7a3607ff47bdde4051d98141ca4
SQL
pravinba/_SpringBoot
/src/main/resources/schema.sql
UTF-8
272
2.59375
3
[]
no_license
create table stock( stock_id int, company_name varchar2(50), symbol varchar2(10), price decimal(10,2) ); insert into stock values(1,'VM Ware','VMW',56.05); insert into stock values(2,'Facebook','FB',100.05); insert into stock values(3,'Microsoft','MSFT',256.05);
true
5c798000171a9bba17f60d3f31225b4e870c39be
SQL
pfittante1001/SGearzAPI
/addressjoincustomer.sql
UTF-8
154
3
3
[]
no_license
select Customers.FirstName, CustAddresses.Address1, CustAddresses.Id from Customers inner join CustAddresses where Customers.Id = CustAddresses.CustomerID
true
7c25143b00b4284a271f3a1de0f5a72e15afd856
SQL
csys-fresher-batch-2021/rechargeapp-core-kiruba
/sql/Register.sql
UTF-8
351
3.015625
3
[]
no_license
/** * query for create table users. */ create table users( id serial PRIMARY KEY, username varchar(30) unique not null, userpassword varchar(30) not null, email varchar(30) unique not null, mobile_Number varchar(10) unique, age int, adhaar_Number varchar(20)unique, CONSTRAINT age CHECK (age>0 AND age<=100...
true
3f1eb81203b348a22b39b0c727da3290e20ea73f
SQL
akula-srinu/Customization_Test
/custom/NVWB_PO_Rcv_Transactions_Vsat_Base.sql
UTF-8
151,378
2.5625
3
[]
no_license
-- ******************************************************************************* -- FileName: NVWB_PO_Rcv_Transactions_Vsat_Base.sql -- -- Date Created: 2019/Aug/28 06:12:39 -- Created By: nemuser -- -- Source: -- - Package: Package_2018_P11_B1_DEV_NEW -- - Environment: ...
true
b7b27d094fb51b813d072aa3ca0baf208103d2b1
SQL
msw822/xjny_dev
/xjny_version/dw_hadoop/table/dim/hb_ztlx.sql
UTF-8
528
2.59375
3
[]
no_license
-- DESCRIPTION: 载体类型代码 -- -- OPTIONS: --- -- REQUIREMENTS: --- -- BUGS: --- -- NOTES: --- -- AUTHOR: song.shengjie@h3c.com -- COMPANY: h3c.bigdata -- VERSION: 1.0 -- CREATED: 2017/08/18 -- REVIEWER: -- REVISION: --- -- use dim; DROP TABLE IF EXISTS hb_ztlx; CREATE EXTERNAL TA...
true
9239c205dbf6be01a51936e6e18bece8cd470c21
SQL
QuesoTech/PhotoHunter
/src/sql/create_feedback_table.sql
UTF-8
257
3.109375
3
[]
no_license
CREATE TABLE feedback ( id serial PRIMARY KEY, user_id integer REFERENCES user (id), datapoint_id integer REFERENCES datapoint (id), subject_id integer REFERENCES subject (id), CONSTRAINT u_constraint UNIQUE (user_id, datapoint_id, subject_id) );
true
ea389b7b0422f94833827bc5b1238a66de643a50
SQL
RodrigoRoy/lais-audiovisual
/content/scripts/delete.sql
UTF-8
1,700
2.71875
3
[ "MIT" ]
permissive
# Indicar con que base de datos trabajar USE Audiovisuales; # Util para mostrar correctamente caracteres 'extraños' SET NAMES utf8; # Script para borrar documentales de la década 10 (1980) que aun no está definido su catalogación exacta: DELETE FROM area_de_identificacion WHERE codigo_de_referencia='MXIM-AV-1-10-48'; ...
true
603ecefdcd88ab0eed2f20e46c1c797132110019
SQL
RMLio/rmlmapper-java
/src/test/resources/test-cases/RMLTC0011a-SQLServer/resource.sql
UTF-8
1,142
3.671875
4
[ "MIT", "LGPL-3.0-only", "EPL-1.0", "MPL-2.0", "BSD-3-Clause", "LGPL-2.0-or-later", "GPL-2.0-only", "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
EXEC sp_msforeachtable 'ALTER TABLE ? NOCHECK CONSTRAINT all' EXEC sp_msforeachtable 'DROP TABLE ?' CREATE TABLE Student ( ID integer PRIMARY KEY, FirstName varchar(50), LastName varchar(50) ); CREATE TABLE Sport ( ID integer PRIMARY KEY, Description varchar(50) ); CREATE TABLE Student_Sport ( ID_Student integer, ID_S...
true
8f811e8e8bd7a9f204ec6c35c344dbdf1bcd2a8b
SQL
gcoronelc/PLSQL-2019-08
/Clase01/mod03.sql
ISO-8859-1
2,074
3.65625
4
[]
no_license
-- Habilitar las salidas set serveroutput on -- Bloque Annimo -- Ejemplo 01 declare v_msg varchar2(1000); begin v_msg := 'Bienvenidos al mundo oscuro de la programacin.'; dbms_output.put_line(v_msg); end; / -- Ejemplo 2 Declare sFecha Varchar2(50); Begin select to_char(sysdate,'dd/mm/yyyy hh24:mm:ss...
true
ed37c0745b389259fbb4ef244005d0d0d3e57cc8
SQL
jagadeeshramd/Faculty-Dashboard
/sqlscripts/feedbacks.sql
UTF-8
1,034
2.765625
3
[]
no_license
use facultydashboard; show tables; create table course_15CSE313_2018_CSE_A_feedback(question varchar(200) primary key, opt_a_val varchar(50) default null,opt_per_a float default 0.0, opt_b_val varchar(50) default null,opt_per_b float default 0.0, ...
true
7062257d8f34ea60cdc97177d1c31a2594d461bb
SQL
ThomasGaff/Year-3-Uni-Work
/Advanced Database Assignment/SQL/1.2.c.sql
UTF-8
154
3.140625
3
[]
no_license
select c.customer_name Name, c.cust_city City from customer c where not exists (select null from deposit d where c.customer_name = d.customer)
true
ca095bb5f5fdfbb39bf5b8918a373f43113ce256
SQL
NSV/codev
/install/codevtt_update_v9_v10.sql
UTF-8
2,556
3.515625
4
[]
no_license
-- this script is to be executed to update CodevTT DB v9 to v10. -- DB v9 is for CodevTT v0.99.18 (Sept 2012) -- DB v10 is for CodevTT v0.99.19 -- ----------------- -- WARN create "CodevTT_Type" customField in Mantis before executing this script INSERT INTO `codev_config_table` (`config_id`, `value`, `type`) VALU...
true
b0458243f8042df83202e3481d1345d65030f6ae
SQL
robertbrockie/shoretay
/sql/links.sql
UTF-8
983
2.78125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.3.10 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Jun 05, 2012 at 06:54 PM -- Server version: 5.1.49 -- PHP Version: 5.3.3-1ubuntu9.7 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD...
true
7b9b42ab684497c7a7c07881ab61151a9213c958
SQL
kng83/sql_training
/Sql_example/Case_IF/If_Table_Exists.sql
UTF-8
284
2.65625
3
[]
no_license
Select firstName , LastName Into #bobik from Person.Person; IF (EXISTS (SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'Person' AND TABLE_NAME = 'Address')) BEGIN Select * from Person.Person; Print 'some' END
true
e1293d6eb860e58b77820bde37e9e0b7841811a5
SQL
dreamingofdata/SampleSQL
/ItemMasterExtract.sql
UTF-8
3,396
3.734375
4
[]
no_license
WITH DATE_SENSITIVE_ITEMS (PW_Company, PW_Warehouse, Item, Shelf_Date, Expiraton_Type, Cases) as (SELECT WWHSPAT.PACP, WWHSPAT.PAWH, WWHSPAT.PAIT, (CASE WITMITM.ITEXF WHEN 'P' THEN WWHSPAT.PASLF WHEN 'E' THEN WWHSPAT.PASLF ELSE 0 ...
true
73559431083f53999e66b5c7d08cf27707b05a81
SQL
dkxltks25/ikmyeongshop
/ikmyeong_shoppingbag.sql
UTF-8
2,625
2.78125
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.12, for Win32 (AMD64) -- -- Host: 127.0.0.1 Database: ikmyeong -- ------------------------------------------------------ -- Server version 8.0.18 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!...
true
eedd9be0416447ba014d93146d2d522e31647582
SQL
BimberLab/DiscvrLabKeyModules
/SequenceAnalysis/resources/schemas/dbscripts/sqlserver/SequenceAnalysis-12.322-12.323.sql
UTF-8
496
2.78125
3
[]
no_license
UPDATE sequenceanalysis.quality_metrics SET metricname = 'Mean Read Length' WHERE metricname = 'Avg Read Length'; UPDATE sequenceanalysis.quality_metrics SET category = 'Readset' WHERE category IS NULL and metricname IN ( 'Total Reads', 'Min Read Length', 'Max Read Length', 'Mean Read Length', 'Total Bases',...
true
a94fd470b4d6743f9d26d9af04e89b478ad78888
SQL
alfredo-barron/ForceCRM
/app/views/Reglas.sql
UTF-8
3,465
3.46875
3
[]
no_license
16 Atributos: Campañas (Status): Activa, Inactiva, Finalizada Clientes (Status): Ninguno, Potencial, Actual Clientes (StatusActual): Activo, Inactivo Clientes (Edad): Niño, Joven, Adulto, Anciano Clientes (Genero): Hombre, Mujer Clientes (Educación): Ninguna, Primaria, Secundaria, Preparatoria o Bachillerat...
true
e19560d446701e94ebfad54968dc2d3a264703cf
SQL
datnguyendn96/DatNguyen
/DatNguyenQuoc_create.sql
UTF-8
1,414
3.65625
4
[]
no_license
-- Created by Vertabelo (http://vertabelo.com) -- Last modification date: 2016-08-24 06:27:40.511 -- tables -- Table: Book CREATE TABLE Book ( CategoryID int NOT NULL, BookID int NOT NULL, Title char(100) NOT NULL, ISBN char(20) NOT NULL, publisher_id int NOT NULL, publisher_date date NOT...
true
af3e3e8c8caddfc76c318945fa2f840d835d971a
SQL
ttobaegi/HackerRank_SQL
/5_HackerRank_Placements.sql
UTF-8
948
4.75
5
[]
no_license
/* 1. name of those students 2. whose best firends got offered a higher salary than them 3. order by salary amount offered to the friends : Descending 조건 없을 경우 디폴트인 ASC로 4. no two students got same salary */ # MY SOLUTION with a as ( select f.ID, p.Salary mine, Friend_ID from Friends f left join Packages p on ...
true
43550cc42e5f4ecfe10acf495fd3d048574cb5e3
SQL
gtoonstra/etl-with-airflow
/examples/etl-example/sql/select_product.sql
UTF-8
251
2.59375
3
[]
no_license
SELECT product_id , product_name , supplier_id , producttype_id , %(audit_id)s , %(window_start_date)s FROM product WHERE updated_dtm >= %(window_start_date)s AND updated_dtm < %(window_end_date)s
true
ff4b8b29518bd1c7a792c51f0246ee71a7bb4735
SQL
DrMoJones/node-server
/ServerSideScriptingDBopret.sql
UTF-8
539
2.71875
3
[]
no_license
Use master DROP DATABASE IF EXISTS SSprog; CREATE DATABASE SSprog; USE SSprog; CREATE TABLE Persons ( [Name] varchar(max), Birthdate DateTime, Email nvarchar(50) ); INSERT INTO Persons([Name], Birthdate, Email) VALUES ('Julie M. Kjeldsen', 13-02-1982, 'JulieMKjeldsen@armyspy.com'); INSERT INTO Persons...
true
83228eff3cec7e6c8fdb2917ed4b1dde921cee48
SQL
jabautista/GeniisysSCA
/src/main/resources/sql/procedures/copy_pol_wgroup_item.prc
UTF-8
2,438
2.734375
3
[]
no_license
DROP PROCEDURE CPI.COPY_POL_WGROUP_ITEM; CREATE OR REPLACE PROCEDURE CPI.copy_pol_wgroup_item( p_par_id IN GIPI_PARLIST.par_id%TYPE, p_policy_id IN GIPI_POLBASIC.policy_id%TYPE ) IS /* Revised to have conformity with the objects in the database; ** the columns in the policy table s...
true
bebd910851cb8e5a76054e9054a74ef6dceea991
SQL
elisemayo/CPSC408
/Final_Project/movies/schema.sql
UTF-8
3,533
3.3125
3
[]
no_license
CREATE TABLE IF NOT EXISTS StreamingService(StreamingServiceID INT PRIMARY KEY AUTO_INCREMENT, ServiceName VARCHAR(32)); CREATE TABLE IF NOT EXISTS Mood(MoodID INT PRIMARY KEY AUTO_INCREMENT, MoodTerm VARCHAR(32)); CREATE TABLE ...
true
2281f82ad463641618f76c0cc2a541a1a9b932e5
SQL
whatsnum/appservice
/database/defaults/countries.sql
UTF-8
13,106
2.671875
3
[]
no_license
-- -- Dumping data for table `countries` -- INSERT INTO `countries` (`id`, `sortname`, `name`, `phonecode`, `flag`, `currency_symbol`, `currency_code`) VALUES (1, 'AF', 'Afghanistan', 93, 'af.png', '؋', 'AFN'), (2, 'AL', 'Albania', 355, 'al.png', 'L', 'ALL'), (3, 'DZ', 'Algeria', 213, 'dz.png', 'د.ج', 'DZD'), (4, 'AS'...
true
63c89e93b95ebd40f0715a31de751ca0cf21c95f
SQL
gokhangirgin/LMS
/LMS_DBv6.sql
UTF-8
15,902
3.53125
4
[]
no_license
CREATE DATABASE IF NOT EXISTS `lms_db` /*!40100 DEFAULT CHARACTER SET utf8 */; USE `lms_db`; -- MySQL dump 10.13 Distrib 5.5.16, for Win32 (x86) -- -- Host: localhost Database: lms_db -- ------------------------------------------------------ -- Server version 5.5.25a /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARA...
true
f191bfb20cd870de43ae6981c442739464382a76
SQL
weinan003/TPCH
/lsp/workloads/TPCDS/queries/tpcds_query14a.sql
UTF-8
4,820
3.78125
4
[]
no_license
--@author guz4 --@description TPC-DS tpcds_query34 --@created 2013-03-06 18:02:02 --@created 2013-03-06 18:02:02 --@tags tpcds orca with cross_items as (select i_item_sk ss_item_sk from item_TABLESUFFIX, (select iss.i_brand_id brand_id ,iss.i_class_id class_id ,iss.i_category_id category_id from store_s...
true
2387cc5ee1ef09a95fda209df26e9ccbc42cad82
SQL
alejogo4/itm_grupo_8
/database.sql
UTF-8
11,123
2.84375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Servidor: 127.0.0.1 -- Tiempo de generación: 28-05-2019 a las 06:30:43 -- Versión del servidor: 10.1.35-MariaDB -- Versión de PHP: 7.2.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; ...
true
8c7a059db412637a913f5f555b5778d8c001cbf6
SQL
Enomartins/php-schoolApp
/loginsystem.sql
UTF-8
11,762
3.078125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Mar 29, 2021 at 09:14 AM -- Server version: 10.1.39-MariaDB -- PHP Version: 7.3.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
f288b539adceda3f8b4d5ecc1cebd7081932cad5
SQL
canorouscrocodiles/thesis
/server/db/sql/db-test.sql
UTF-8
9,060
3.34375
3
[]
no_license
DROP DATABASE IF EXISTS thesis_test; CREATE DATABASE thesis_test; \c thesis_test; CREATE EXTENSION postgis; CREATE TABLE IF NOT EXISTS users ( id BIGINT PRIMARY KEY, created_timestamp TIMESTAMP DEFAULT now() NOT NULL, username VARCHAR (50) NOT NULL, email VARCHAR (50) NOT NULL, img_url VARCHAR (200), bio...
true
4bc6987c416b530ab8a58e414b79a7df497cd8f7
SQL
cdesmarais/WebDB-Test
/WebDB/StoredProcedures/Common/dbo.Report_Company_Top10.PRC
UTF-8
1,057
3.953125
4
[]
no_license
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Report_Company_Top10]') and OBJECTPROPERTY(id, N'IsProcedure') = 1) drop procedure [dbo].[Report_Company_Top10] GO CREATE PROCEDURE dbo.Report_Company_Top10 ( @metroID int, @thrudate Datetime = Null ) AS SET NOCOUNT ON set transaction isolation ...
true
e7576e70d8be986410d7beeede247b1f4d49a5e8
SQL
echaves1/Banco
/Scripts/Aula2_2.sql
WINDOWS-1252
203
2.671875
3
[]
no_license
SET SERVEROUTPUT ON VARIABLE v_emp_salary number BEGIN SELECT SALARY INTO :v_emp_salary FROM EMPLOYEES WHERE EMPLOYEE_ID = 100; DBMS_OUTPUT.PUT_LINE('O salario :' || :v_emp_salary); END;
true
e1d1dd80059aa87fd9963353accc445d4641b006
SQL
jakovz/cocktail-world-backend
/SRC/CREATE-DB-SCRIPT.sql
UTF-8
2,385
3.65625
4
[]
no_license
CREATE TABLE 'cocktails_ingredients' ( 'cocktail_id' INT(5) NOT NULL, 'ingredient_name' VARCHAR(50) NOT NULL, 'measure' VARCHAR(50) NULL DEFAULT NULL, PRIMARY KEY ('cocktail_id', 'ingredient_name'), INDEX 'cocktailsIngredientsIndex' ('ingredient_name'), CONSTRAINT 'cocktail_id' FOREIGN KEY ('cocktail_id') R...
true
2a9d609004df628feeb1a986e3b1977fd019fa51
SQL
kuunal/AdvancedMySQL
/triggr.sql
UTF-8
889
3.046875
3
[]
no_license
--update trigger delimiter // create trigger update_trigger after update on dummy_table for each row begin insert into database_status(action) values('UPDATE'); end // delimiter ; ------------------------------------------------------------------------------------------------------------------- --insert trigger delim...
true
4f85d2113a7f6083c925d4d0a2f319f4022a76ff
SQL
UcgajjarPDI/Nicepak-PIMS
/PDI_SALESTRACING_DEV/TRC/Stored Procedures/spGET_DATA_OBJECTS.sql
UTF-8
1,297
3.828125
4
[]
no_license
CREATE PROCEDURE [TRC].[spGET_DATA_OBJECTS] WITH EXEC AS CALLER AS BEGIN -- ALL DATA OBJECTS SELECT SCHEMA_NAME(O.schema_id) as SCHEMA_NM, CASE WHEN O.type='U' THEN 'TABLE' WHEN O.type='P' THEN 'STROED PROC' WHEN O.type='FN' THEN 'FUNCTION' END AS OBJ_TYPE, O.name AS OBJ_NM ...
true
e1181c420c2b13cc25a0bf7df5be84e2b31749db
SQL
citenaresh/burgerace
/db/schema.sql
UTF-8
232
2.75
3
[ "MIT" ]
permissive
DROP DATABASE IF EXISTS burger_db; CREATE DATABASE burger_db; USE burger_db; CREATE TABLE burgers( id int NOT NULL AUTO_INCREMENT, burger_name varchar(255) NOT NULL, devoured BOOLEAN DEFAULT false, date TIMESTAMP, PRIMARY KEY (id) )
true
a5c8660e8d332d911f131c0b9ce243b094057376
SQL
nemanja-curcic-dev/default-answer-grpc
/initdb.sql
UTF-8
400
3.15625
3
[]
no_license
/* Ensures creation of database 'defaultanswerdb' and table 'default_answer' */ CREATE DATABASE IF NOT EXISTS defaultanswerdb; USE defaultanswerdb; CREATE TABLE IF NOT EXISTS default_answer( id INT NOT NULL AUTO_INCREMENT, advertid INT NOT NULL, type TINY...
true
6d2b2a9d145247626554f86c72916576d3cb06fe
SQL
ParkHyeonChae/Algorithm
/programmers/SQL/JOIN/보호소에서 중성화한 동물.sql
UTF-8
211
3.484375
3
[]
no_license
SELECT B.ANIMAL_ID, B.ANIMAL_TYPE, B.NAME FROM ANIMAL_OUTS B JOIN ANIMAL_INS A ON A.ANIMAL_ID = B.ANIMAL_ID WHERE A.SEX_UPON_INTAKE LIKE "%Intact%" AND B.SEX_UPON_OUTCOME NOT LIKE "%Intact%" ORDER BY B.ANIMAL_ID
true
0e849653b02e0be62033d9a84b4b393547b819cd
SQL
pedrolucasmr/TCC_CR
/Site_Administrativo/index_advogado/agenda/agenda.sql
UTF-8
1,881
3.1875
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.1.14 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: 05-Set-2018 às 17:16 -- Versão do servidor: 5.6.17 -- PHP Version: 5.5.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;...
true
99f4fb489d9b9330a4d58f8427c15d836079402d
SQL
shekhar700/Training-Feb-2021
/Modules/Project/Viral Gujarati/HotstarTable.sql
UTF-8
1,871
3.6875
4
[]
no_license
USE Hotstar -- PLAN Information CREATE TABLE "Plan"( PlanID INT PRIMARY KEY Identity(1,1), PlanName NVARCHAR(50) NOT NULL, SubscriptionPlan NVARCHAR(30) NOT NULL, Price money NOT NULL ) CREATE TABLE PlanFeatures( ID INT Primary Key, Features NVARCHAR(MAX), FREE BINARY, VIP BINARY, PREMIUM BINARY, Plan...
true
dd9e4136b07a75b6182ba4d781a02df1187cfcce
SQL
aiji42/botui-nx
/hasura/migrations/default/1626591202457_squashed/up.sql
UTF-8
442
3.15625
3
[]
no_license
alter table "public"."stories" rename to "talk_sctipts"; alter table "public"."talk_sctipts" drop column "story" cascade; alter table "public"."talk_sctipts" drop column "strategy" cascade; CREATE TABLE "public"."scripts" ("id" uuid NOT NULL DEFAULT gen_random_uuid(), "talk_script_id" uuid NOT NULL, "follow_script_...
true
6c1d0229c45a30d5acf36299d577911af249949c
SQL
saikiranchary/light
/MSSQLServerDMVsToExcel/src/java/SourceFiles/IndexFragmentation.sql
UTF-8
940
4.25
4
[]
no_license
SELECT top 100 percent dbschemas.[name] as 'Schema', dbtables.[name] as 'Table', dbindexes.[name] as 'Index', dbindexes.index_id as IdxID, cast(indexstats.avg_fragmentation_in_percent as decimal(6,2)) as Prcent, indexstats.page_count, replace(index_type_desc,' index','') as IndxType, fragment_count as Fragments, index...
true
2e8aea0d0666d82e6f4bbe1daa6cff7472260651
SQL
soechka/java-spring-jdbc-jpa-example
/target/test-classes/schema.sql
UTF-8
299
2.96875
3
[]
no_license
DROP TABLE IF EXISTS student; DROP TABLE IF EXISTS faculty; CREATE TABLE faculty( id serial PRIMARY KEY, name varchar UNIQUE NOT NULL ); CREATE TABLE student( id serial PRIMARY KEY, facId int, name varchar UNIQUE NOT NULL, year int NOT NULL CHECK (year > 0 AND year < 6) );
true
63775adde2ad42f2d96bcb95b14975926fd70b64
SQL
schrapps/risksur
/src/main/resources/MySQL/201510011040_RSKSR-82_Data.sql
UTF-8
1,377
2.78125
3
[]
no_license
INSERT INTO `permissions` (`id`, `name`, `description`, `controller`, `action`, `bizrule`) VALUES (111, 'actionIndex', 'C/A to list surveillance sections', 'adminsurveillancesections', 'index', ''), (112, 'actionHome', 'C/A to surveillance sections ADMIN home page', 'adminsurveillancesections', 'home', ''), (113,...
true
b2d8a712cbb7b71dab5f5ecdbf83b4746422a710
SQL
K-Ellis/Data-Engineering-Nanodegree
/1_Data_Modelling_with_PostgreSQL/src/__pycache__/clear_connections.sql
UTF-8
240
2.515625
3
[]
no_license
REVOKE CONNECT ON DATABASE sparkifydb FROM PUBLIC; SELECT pg_terminate_backend(pg_stat_activity.pid) FROM pg_stat_activity WHERE pg_stat_activity.datname = 'sparkifydb' --AND pid <> pg_backend_pid(); -- don't kill my own connection!
true
34f8b5bb050483da026a2f0511be9dadd1d0c603
SQL
AjayKadoula/Open_Source_Education_Platform_
/users-database (3).sql
UTF-8
17,706
3.140625
3
[ "Apache-2.0" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Feb 06, 2019 at 07:19 AM -- Server version: 5.7.19 -- PHP Version: 5.6.31 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CH...
true
e169d373b05de0f4bf8b4bb675c592fc79e5380b
SQL
sergey-didenko/spring-boot-testing
/src/main/resources/liquibase/changelog/structure/4-subject.sql
UTF-8
396
3.125
3
[ "Apache-2.0" ]
permissive
--liquibase formatted sql --changeset Svigelf:4 CREATE TABLE `subject` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `name` varchar(50) DEFAULT NULL, `student_id` bigint(20) DEFAULT NULL, PRIMARY KEY (`id`), CONSTRAINT `s_si` FOREIGN KEY (`student_id`) REFERENCES `student` (`id`) ON DELETE RESTRICT ON UPDATE R...
true
3674c770d94ab2a67b0baa525a9f050f55c521ce
SQL
ds2014/data-pipeline
/src/main/resources/sql/transformations/stock_dbxref/create_not_existing_stock_accessions_chado_dbxref_mv.sql
UTF-8
706
4
4
[]
no_license
DROP MATERIALIZED VIEW IF EXISTS staging.dbxref_not_existing_stock_accessions; CREATE materialized view staging.dbxref_not_existing_stock_accessions AS WITH source AS( SELECT distinct cast (g.stock_id as bigint) as accession, cast ( staging.get_tair_db_id_by_name( 'TAIR Stock') as int) db_id FROM staging.germ...
true
c30fa3bb2ddc1fda6f6499f6807ce8a73d36e489
SQL
Q-Adorable/TWS
/growth-note-app/backend/src/main/resources/db/migration/V1__create_growthNote_table.sql
UTF-8
365
2.859375
3
[]
no_license
CREATE TABLE `practiseDiary` ( `id` int(11) NOT NULL AUTO_INCREMENT, `createTime` TIMESTAMP default current_timestamp, `date` TIMESTAMP default current_timestamp, `content` VARCHAR(10000), `practiseDiaryId` int(11), `diaryAuthorId` int(11), `operationType` enum('CREATE', 'UPDATE', 'DELETE'), PRIMARY KEY...
true
a228d3e964114b5bde46aa953cb62abc6de3aec7
SQL
chaerun/epu
/src/main/resources/script.sql
UTF-8
1,291
2.65625
3
[]
no_license
CREATE DATABASE epu; USE epu; INSERT IGNORE INTO grade (id, name) VALUES ('e61d2929-59b8-4107-8939-975df1281f48', 'Penata Tk.1, Gol. III/d'), ('f19cd7c5-06ff-419e-98fc-f30ef903a6b4', 'Penata Muda Tk.1, Gol. III/b'); INSERT IGNORE INTO position (id, name) VALUES ('013ffa55-0888-4234-ac94-c4ff07924e4a', 'Kasub...
true
cfa0663a51b785c678718a1676027b5281806e7e
SQL
labatvalen/ApplicationCovid19
/BDD/Donnees/Adjacent.sql
UTF-8
310
2.59375
3
[]
no_license
-- -- Donnees de la table Adjacent; -- -- encodage des imporations en utf8 charset utf8; -- importation des donnees LOAD DATA LOCAL INFILE 'eclipse-workspace/ProjetTransverse/BDD/Donnees/Autre/communes_adjacentes_2018.csv' INTO TABLE Adjacent FIELDS TERMINATED BY "," LINES TERMINATED BY '\n'; SHOW WARNINGS;
true
76aeac840d69660b3d4673bc7588d503cffa2f29
SQL
AstroPlant/astroplant-api
/migrations/2020-004_peripheral-definitions-expected-quantity-types/up.sql
UTF-8
685
3.359375
3
[]
no_license
CREATE TABLE peripheral_definition_expected_quantity_types ( id serial4 NOT NULL, quantity_type_id int4 NOT NULL, peripheral_definition_id int4 NOT NULL, CONSTRAINT peripheral_definition_expected_quantity_types_pkey PRIMARY KEY (id) ); -- foreign keys ALTER TABLE public.peripheral_definition_expected_quantity_type...
true
19a7f19e97db5bab8919b5e35553d26a9a17f197
SQL
aminspicse/laraschoolsql
/table/studentregistrations.sql
UTF-8
1,098
3.296875
3
[]
no_license
CREATE TABLE studentregistrations ( registration_id INT NOT NULL PRIMARY KEY AUTO_INCREMENT, student_id VARCHAR(20) NOT NULL, class_id INT NOT NULL, semester_id INT NOT NULL, department_id INT NOT NULL, year_name VARCHAR(4) NOT NULL, user_id INT(11) NOT NULL, remarks VARCHAR(200) DEFAULT NULL, registr...
true
47f44a97902036bab2d46bd0dd68245d1b6243d9
SQL
Ariah-Group/Research
/db_scripts/current_mysql/5.0.1/dml/KC_DML_05_KRACOEUS-5636_B000.sql
UTF-8
216
2.53125
3
[ "Apache-2.0", "ECL-2.0" ]
permissive
DELIMITER / UPDATE QUESTIONNAIRE_USAGE SET QUESTIONNAIRE_LABEL='Grants.gov S2S Questionnaire' WHERE QUESTIONNAIRE_REF_ID_FK IN (SELECT QUESTIONNAIRE_REF_ID FROM QUESTIONNAIRE WHERE QUESTIONNAIRE_ID=5) / DELIMITER ;
true
31e3b45573a8e68e8d97977210f085330c081172
SQL
edjavu/Aplicaciones-moviles-para-contact-tracing-usando-bluetooth
/Testing caja blanca/Código Base de Datos del Backend/dpppt.sql
UTF-8
3,837
2.6875
3
[]
no_license
-- -- PostgreSQL database dump -- -- Dumped from database version 10.15 -- Dumped by pg_dump version 10.15 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', '', f...
true
d7b02db7b9ab18068a687b4ac4351fe64193ec90
SQL
billmcmillin/aahsl-title-count
/sql/aahsl_title_count_pass1.sql
UTF-8
4,575
3.46875
3
[]
no_license
/* PASS 1 - AAHSL title count query Full data set requires two queries: *pass1, *pass2. Run queries in pgAdmin3, output to .tsv, and combine files manually. ** Be sure to set the current fiscal year on line 96 ** */ SELECT DISTINCT ON (init.record_num) init.record_num, uni.field_content AS uniform, t.fi...
true
6befc9835aa7a86dd25410fd4e7f13087eea7638
SQL
Andresg95/custodiaBU
/database/custodiaonlineBase.sql
UTF-8
7,964
3.296875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.4 -- https://www.phpmyadmin.net/ -- -- Servidor: 127.0.0.1 -- Tiempo de generación: 26-03-2019 a las 09:58:34 -- Versión del servidor: 10.1.37-MariaDB -- Versión de PHP: 7.3.0 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone...
true