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
abfa37977cd6bb5291eb42fdc4010ecdd002f151
SQL
NachiMK/nodejs
/data-adhoc/postgressql/compare_benefits.sql
UTF-8
361
3.5625
4
[ "MIT" ]
permissive
SELECT t1."HiosPlanID", t1."Benefit", t1."CopayAmount", t2."Benefit", t2."CopayAmount" FROM "PlanBenefits" as t1 INNER JOIN "PlanBenefits" as t2 ON t1."Year" = t2."Year" AND t1."HiosPlanID" = t2."HiosPlanID" WHERE t1."Benefit" IN ('NonPreferredBrandDrugs') AND t2."Benefit" IN ('PreferredBrandDrugs') AND t1."Year" = 201...
true
3d50508a06374e549453152f00a9b18311645c73
SQL
nickzznl/MoveWithFriends
/MoveWithFriends.sql
UTF-8
830
3.78125
4
[]
no_license
DROP TABLE IF EXISTS `timeslot`, `Interest`, `customer` ; CREATE TABLE `Customer` ( CustomerID INT(10) NOT NULL PRIMARY KEY AUTO_INCREMENT, FirstName VARCHAR(255) NOT NULL, LastName VARCHAR(255) NOT NULL, SEX VARCHAR(6) NOT NULL, BirthDate DATE, PreferredSex VARCHAR(10) NO...
true
34a926c0535bee94a714e9ee2e4bdd414efd71c9
SQL
Rj-866/Data-Analyst-Portfolio-Project-1
/SQLQuery1.sql
UTF-8
5,191
4.34375
4
[]
no_license
/* Covid 19 Data Exploration Skills used: Joins, CTE's, Temp Tables, Windows Functions, Aggregate Functions, Creating Views, Converting Data Types */ Select * From [Portfolio Project]..CovidDeaths order by 1,2 --Select * --From [Portfolio Project]..CovidVaccinations --order by 3,4 -- Data that going to be used ...
true
dad358b934eb7cc6d5e1a2c22611420b817316a4
SQL
lmorchard/feedspool-rs
/migrations/2021-05-07-224917_add_etag_and_lastmod_to_history/down.sql
UTF-8
377
2.625
3
[]
no_license
CREATE TABLE tmp_feed_history ( id TEXT PRIMARY KEY, feed_id TEXT, created_at TEXT, updated_at TEXT, src TEXT, status TEXT, status_text TEXT ); INSERT INTO tmp_feed_history SELECT id, feed_id, created_at, updated_at, src, status, status_text FROM feed_history; DROP TABLE IF EXISTS feed_history...
true
19f90a18e1723380ea1329db37ed0fa317f53adb
SQL
tparveen/TF-DataScience
/10-SQL-foundations-II/10_SQL_II.sql
UTF-8
6,389
3.421875
3
[]
no_license
https://courses.thinkful.com/dsbc-sql-foundations-2-v1/checkpoint/4 select column_name,data_type from information_schema.columns where table_name = 'ksprojects'; "id" "integer" "name" "text" "category" "text" "main_category" "text" "deadline" "timestamp without time zone" "goal" "real" "launched" "timestamp witho...
true
05e76427dcf00fe126cb8a43d3001f74f462c218
SQL
jianminchen/LeetCode-30
/197 Rising Temperature.sql
UTF-8
162
3.109375
3
[]
no_license
# Write your MySQL query statement below select W2.Id from Weather W1, Weather W2 where W2.Temperature > W1.Temperature and DATEDIFF(W2.Date, W1.Date) = 1
true
df1df951da2f8951ee1ffe544a2024bda1b51a65
SQL
adityatechracers/project
/db/structure.sql
UTF-8
102,338
3.203125
3
[]
no_license
-- -- PostgreSQL database dump -- SET statement_timeout = 0; SET lock_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; SET check_function_bodies = false; SET client_min_messages = warning; -- -- Name: plpgsql; Type: EXTENSION; Schema: -; Owner: - -- CREATE EXTENSION IF NOT EXISTS plpg...
true
7d71ac96b5e14844d8cf484205d5aa47d8da14ff
SQL
George841221/WorkClothes
/target/classes/testWorkClothesDB.sql
UTF-8
968
2.703125
3
[]
no_license
DROP DATABASE IF EXISTS workClothesDB; CREATE DATABASE /*IF NOT EXISTS*/ workClothesDB; USE workClothesDB; CREATE TABLE IF NOT EXISTS workers ( worker_name VARCHAR(50), position ENUM ('office worker', 'mechanic', 'electrician', 'maintenance', 'indoor worker', 'unknown'), t_shirt_size VARCHAR(50...
true
00a0de0fc36d38e21c7c35164e9498f6093e1cef
SQL
aliaksandr-master/todo-api
/src/database/dump/listslider_test.sql
UTF-8
3,048
2.71875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.2.1deb1 -- http://www.phpmyadmin.net -- -- Хост: localhost -- Время создания: Июн 04 2014 г., 00:46 -- Версия сервера: 5.5.37-1 -- Версия PHP: 5.5.12-2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT *...
true
96fcce16935e06dc2de5774081cb9329cf54f3df
SQL
GabrielBFelix/ExerciciosSQL
/Tarefa 02 - Consultas Aninhadas/exercicio02.sql
UTF-8
178
2.78125
3
[]
no_license
-- Faça uma consulta que selecione o nome de todos os funcionários exceto o mais idoso. SELECT nome FROM funcionario WHERE dtnasc != ( SELECT MIN(dtnasc) FROM funcionario );
true
8804756438ad7dc9ea26604b7edae959cd11def2
SQL
Olga-kv/laboratory_works_sql
/lb_2/select_13-16.sql
UTF-8
896
3.5625
4
[]
no_license
--13.Вивести книги видані в 1999, 2001, 2003, 2005 р SELECT * from book where (select EXTRACT (YEAR from book_date) in (1999,2001,2003)) --14.Вивести книги назви яких починаються на літери А-К SELECT * from book where book_name between 'А' and 'К' --15.Вивести книги назви яких починаються на літери 'Апп', видані в 200...
true
510c54407819aa2ea6f5c450ea7e98d4c13db7fb
SQL
strogiyotec/J-Riddler
/src/test/resources/db/migration/V5__user_items.sql
UTF-8
146
2.953125
3
[ "Apache-2.0" ]
permissive
CREATE table user_to_item ( id serial primary key, user_id bigint references users (id), item_id bigint references items (id) );
true
8c0c44fa9db960d7cdbe79391bbb94d1ef5e180e
SQL
NamrataPalai/Database-Modelling-of-an-Art-Union
/mau_schema.sql
UTF-8
12,575
3.25
3
[]
no_license
-- Generated by Oracle SQL Developer Data Modeler 19.2.0.182.1216 -- at: 2020-05-12 21:39:24 AEST -- site: Oracle Database 11g -- type: Oracle Database 11g -- Student Name: Namrata Palai -- Student ID: 31002188 set echo on spool mau_schema_output.txt DROP TABLE artist CASCADE CONSTRAI...
true
3aa7c96245e20bb552ea18bdb9a1f91710b0f1a6
SQL
tkemps/hackage-analyzer
/sql/create_dependency.sql
UTF-8
1,440
3.671875
4
[ "BSD-2-Clause" ]
permissive
-- Table: hackage.dependency -- DROP TABLE hackage.dependency; CREATE TABLE hackage.dependency ( package_name character varying(255) COLLATE pg_catalog."default" NOT NULL, version character varying(100) COLLATE pg_catalog."default" NOT NULL, run_date date NOT NULL, package_name_dependency character va...
true
c60df1e7051b0f50960cfb4306e8392cb64b9843
SQL
juvygreen/splunk_p1_shift
/db/splunk-p1.sql
UTF-8
33,261
3.484375
3
[]
no_license
-- Splunk P1 Schema -- /Applications/MAMP/Library/bin/mysql -uroot -proot -- Additional Requirements: -- Reporting - engineers per month or date range -- Sorting - way to sort the engineer -- Content Management - Add/edit/remove shift zones ie AMER Cloud Shift A - AST 10am - 1pm | UK 2pm - 5pm | EST 9am - ...
true
fa9fa5d625d884761165c6ba482979b93e47a255
SQL
joanaferreira0011/DatingAPP
/src/int/int3.sql
UTF-8
493
3.984375
4
[]
no_license
.mode columns .headers on .nullvalue NULL Select Anunciante.nome,c, max(acceptance) as aceitacao from Anunciante, ( select Campanha.idAnunciante as a, Campanha.conteudo as c, 1.0*sum(AnuncioTemplate.click)/count(AnuncioTemplate.click) as acceptance from TipoAnuncio, AnuncioTemplate, Campanha where AnuncioTemplate.tipo...
true
c03db291f6c9986ab6d60a6557c76e15a13b5604
SQL
WangFan1007/python-learn
/mysql_mac/外键.sql
UTF-8
522
3.46875
3
[ "MIT" ]
permissive
create table userinfo ( id int primary key auto_increment, name varchar (15), email varchar (32) ) engine=InnoDB default charset=utf8; create table hostinfo ( id int primary key auto_increment, name char (64) ) engine=InnoDB default charset=utf8; create table user_host_r ( id int primary key auto_incr...
true
e06680c96eede970831d5aad740d03f5bc883491
SQL
leeneko/SQL
/급여지급명세서 프로시저.sql
UTF-8
2,432
4.09375
4
[]
no_license
DROP PROCEDURE APR_PAB0901; CREATE PROCEDURE APR_PAB0901( IN MON NVARCHAR(10), IN EMPNO NVARCHAR(20) ) LANGUAGE SQLSCRIPT SQL SECURITY INVOKER AS BEGIN DECLARE ROWCNT INT; DECLARE X INT; DECLARE Y INT; DECLARE Z INT; DECLARE I INT; CREATE LOCAL TEMPORARY TABLE #TMP1( SEQ INT, TMP1STR NVARCHAR(20), TMP1...
true
088256f47a882044b2296918e64b008879ae8069
SQL
tanmoy13/Online-Judge-Database-Project
/Online Judge Database.sql
UTF-8
13,480
3.796875
4
[]
no_license
DROP TABLE RANKLIST; DROP TABLE JUDGE_STATUS; DROP TABLE PROBLEMS; DROP TABLE CONTESTANT; DROP TABLE CONTEST; CREATE TABLE CONTESTANT ( USER_ID NUMBER(5), USER_NAME VARCHAR(30) NOT NULL, PASSWORD VARCHAR(10), GENDER VARCHAR(10) DEFAULT 'MALE', LANGUAGE VARCHAR(10) ); CREATE TABLE CONTEST ( CO...
true
45fb226b8e943da420f9952691b673931b4c3272
SQL
eduardocpacheco99/ICAIL
/wikimunicipios.sql
UTF-8
5,762
3.1875
3
[]
no_license
a ideia é tirar os TRs TIREI UM </TD> </a><br /> -> </a><br /></TD> use icail; create table controleprocessamento (id int auto_increment primary key, identifier varchar(32)) drop table teste; create table teste(id int auto_increment primary key, teste varchar(200000)) select * from cabecalho; select * fro...
true
04ca0706da44815ed8bedc16df67e7048320671a
SQL
sudarshanvm/QuizPortal
/qp.sql
UTF-8
8,804
3.09375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Apr 11, 2020 at 02:25 PM -- Server version: 10.4.11-MariaDB -- PHP Version: 7.4.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
3a0a2105124ce31da9a168b06238547aebaa4c76
SQL
sandianyiyuan/Artificial2B
/Artificial2B-model/src/main/resources/schema.sql
UTF-8
713
3.28125
3
[]
no_license
-- ---------------------------- -- Table structure for UserInfo -- ---------------------------- DROP TABLE IF EXISTS `UserInfo`; -- 创建一个表,指定了4个属性:id、年龄、身高、体重。最后指定了id是唯一不能重复的键值 CREATE TABLE IF NOT EXISTS `UserInfo` ( `id` varchar(20) NOT NULL, `age` int DEFAULT NULL, `height` int DEFAULT NULL, `weight` int DEFAULT ...
true
c4962848e6d30e7dc44501c3ead7e42edb8814a4
SQL
zhangshengrui/solid
/old.sql
UTF-8
9,101
3.015625
3
[]
no_license
/* SQLyog Ultimate v12.08 (64 bit) MySQL - 5.5.28 : Database - solid ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@...
true
c51d3c14c909a517be17359f0748913e9431fe94
SQL
DiKust/HomeWork-Goit
/resources/4.sql
UTF-8
648
2.765625
3
[]
no_license
ALTER TABLE mysqlhomework.projects ADD Cost DECIMAL NOT NULL ; UPDATE projects SET Cost = 35000.00 WHERE Name = 'Earth'; UPDATE projects SET Cost = 30000.00 WHERE Name = 'Mercury'; UPDATE projects SET Cost = 15000.00 WHERE Name = 'Venera'; UPDATE projects SET Cost = 25000.00 WHERE Name = 'Mars'; UPDATE projects SET Co...
true
6cf193680c2eef1ad5bf3cc731c9049aeb4f875d
SQL
marchiore/projeto_clientes
/script.sql
UTF-8
3,235
3.359375
3
[]
no_license
-- MySQL Script generated by MySQL Workbench -- 02/25/16 15:17:42 -- 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='TRADITION...
true
d125c235d5e935a3b87a77f2df45bcfb3d516e42
SQL
hashgraph/hedera-mirror-node
/hedera-mirror-importer/src/main/resources/db/migration/v1/V1.54.2__evm_address.sql
UTF-8
287
2.75
3
[ "Apache-2.0" ]
permissive
-- add evm_address to tables contract and contract_history alter table contract add column evm_address bytea null; create index if not exists contract__evm_address on contract (evm_address) where evm_address is not null; alter table contract_history add column evm_address bytea null;
true
bbb5de13857f8dd680cddd6a49ad78e38abea5a9
SQL
IvonkaK/CS50ProblemSets
/SQL/10.sql
UTF-8
174
3.375
3
[]
no_license
SELECT people.name FROM people WHERE id IN (SELECT DISTINCT(person_id) FROM directors WHERE directors.movie_id IN (SELECT movie_id FROM ratings WHERE ratings.rating >= 9.0));
true
ca3502df53c75458018748db2bc538ffadba9f4a
SQL
gabrielos307/BasesDatosAvanzadas
/BDA/tema4/ejercicio03/s-01-redo-log-buffer.sql
UTF-8
1,059
3.453125
3
[]
no_license
--@Autor: Herrera Gandarela Gabriel Alejandro --@Fecha creación: 02/01/2021 --@Descripción: Creación de la tabla Redo Log Buffer whenever sqlerror exit rollback set serveroutput on connect sys/system2 as sysdba declare v_count number; v_username varchar2(30) := 'ALE0403'; v_table varchar2(30) := 'T0...
true
f494ed0c2a4576d8422b4feff56f66a5c6f8dd7c
SQL
SabraAS/Senai-MySQL
/ex1_2015286.sql
UTF-8
5,067
2.859375
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.12, for Win64 (x86_64) -- -- Host: localhost Database: ex1_2015286 -- ------------------------------------------------------ -- Server version 5.7.15-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_...
true
62fd1d2c5c34d71b9e94939e549acfd2c698fafc
SQL
DpadamsX/DpadamsX
/views/api/push_log_domo.sql
UTF-8
1,101
2.828125
3
[]
no_license
CREATE OR REPLACE VIEW api.push_log_domo AS SELECT push_log.id, push_log.data_file_id, data_file_info.server_name_, push_log.ib_table_name, push_log.ib_table_number, push_log.records_count, push_log.push_dts, age(now(), push_log.push_dts) AS age, minutes_old(push_log.push_dts) AS minutes_old, data_file_inf...
true
ef8c5559dbf763182d57fb11f36543b995fdf296
SQL
judgementine/Zoo_Managment_Database
/animal_shop/backstage/database.sql
UTF-8
8,222
3.125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- 主机: localhost -- 生成日期: 2021-04-16 21:06:23 -- 服务器版本: 5.7.26 -- PHP 版本: 7.3.4 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLI...
true
c257282c059d64c37f941b9a5efe62741f22c29a
SQL
ponsea/nb-dev-training-sql
/theme-a/29.sql
UTF-8
146
2.78125
3
[]
no_license
SELECT T.口座番号 FROM ( SELECT 口座番号 FROM 口座 UNION ALL SELECT 口座番号 FROM 廃止口座) AS T ORDER BY T.口座番号;
true
0b619f438b4d2318fcc3eb7990aae4e30969ca2a
SQL
mblaettler/TSM_DataMgmt
/sql_code/json_operators.sql
UTF-8
544
3.421875
3
[]
no_license
-- ->> gets it as text SELECT '[1,2,3]'::json->>2; -- use cast to get another type SELECT CAST('[1,2,3]'::json->>2 AS INTEGER); -- -> gets it as json SELECT '{"a":1,"b":2}'::json->'b'; -- JSON object at specified path as json SELECT '{"a":[1,2,3],"b":[4,5,6]}'::json#>'{a,2}'; -- JSON object at specified path as text ...
true
585878a37f9010d25ceb6f3f6054d17414455ca8
SQL
dmironov1993/sqlex
/sqlex/019.sql
UTF-8
310
3.90625
4
[]
no_license
/*http://www.sql-ex.ru/learn_exercises.php?LN=19*/ /*For each maker having models in the Laptop table, find out the average screen size of the laptops he produces. Result set: maker, average screen size.*/ SELECT maker, AVG(screen) FROM product p INNER JOIN laptop l ON p.model = l.model GROUP BY p.maker
true
9665139bac76a7d004643b7507e8d98bf41dbfc3
SQL
emiliano-sangoi/capacitacion-plsql
/clase3/test_vendedor_existe.sql
UTF-8
384
2.671875
3
[]
no_license
DECLARE mensaje VARCHAR(60) DEFAULT ''; BEGIN FOR i IN -5..25 LOOP mensaje := 'El vendedor con ID ' || i; IF(VENDEDOR_EXISTE(i)) THEN mensaje := mensaje || ' EXISTE'; ELSE mensaje := mensaje || ' NO EXISTE'; END IF; ...
true
fdb37f0e6231aa118cbec2c7540aa34d3991303f
SQL
NicolasGerhardt/GC_Lab_13.1
/Extended Challenge/SQLQuery24.sql
UTF-8
251
3.6875
4
[]
no_license
/* Show the first name and last name for the employee with the highest salary. */ select FirstName, LastName from Employees where EmployeeID = (select max(EmployeeID) from Employees) /* Since Salary is not lised in the DB I'm using EmplyeeID instead*/
true
7f06509a5d5949e3fc26ed101b6e232bb0bbba87
SQL
aoaojiao1602/1602Demo
/file/src/main/resources/db/fileManger.sql
UTF-8
2,162
3.21875
3
[]
no_license
/* SQLyog 企业版 - MySQL GUI v8.14 MySQL - 5.7.20-log : Database - springcloudfile ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN...
true
d75f5f41027fb0fb43b5f3dace17ca1dbf31cc32
SQL
xgh9/shiro_jwt
/src/main/resources/sql/main.sql
UTF-8
2,403
3.390625
3
[]
no_license
/* SQLyog Community v13.1.6 (64 bit) MySQL - 5.7.31-log : Database - network ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOR...
true
83906396daf758ab2f1c020219a31d61b93dca94
SQL
katooshka/sqlex
/054.sql
UTF-8
458
3.890625
4
[]
no_license
-- Schema: Ships -- With a precision of two decimal places, determine the average number of guns for all battleships -- (including the ones in the Outcomes table). WITH aux_table AS (SELECT name, numGuns FROM ships JOIN classes ON classes.class = ships.class WHERE type = 'bb' UNION SELECT ship, numGuns FROM ou...
true
97f1d0aac58de806c7e98e6e8cdd8d3ee2f1b7ac
SQL
matteoredaelli/moodle-reporting
/R/sqlfiles/resources_by_country_type.sql
UTF-8
194
3.453125
3
[]
no_license
SELECT substring_index(c.fullname, '_', 1) as country, r.type FROM mdl_course c, mdl_resource r WHERE r.course = c.id and c.fullname like '__\_%'
true
28d9e155bf391ef04c34c214e4d148489e5e958f
SQL
nmrada/Grupo-660678-Trimestre-5
/MySQL/Sentencias SQL/actualizarSubtotalesPedidos.sql
UTF-8
3,830
2.828125
3
[]
no_license
-- Actualiza los subtotales, impuestos y total de Pedido update tiendaenlinea.pedido p set p.subtotal = (SELECT sum(i.costoTotal) FROM tiendaenlinea.item i where i.Pedido_Factura_idFactura=1),p.impuestos = (SELECT sum(i.costoTotal) FROM tiendaenlinea.item i where i.Pedido_Factura_idFactura=1)*0.16,p.total =(SELECT su...
true
3406e74fca2fe5ca14984dd09d5e3370842d90c2
SQL
inertiabeer/graduation
/sql/按照时间段分组.sql
UTF-8
1,383
3.34375
3
[ "BSD-2-Clause" ]
permissive
CREATE TABLE `分段2` AS SELECT *, CASE WHEN Date_format(time2, "%k") IN (0, 1, 2, 3, 4, 5, 6, 7) THEN 8 WHEN Date_format(time2, "%k") IN (8) and Date_format(time2, "%i") between 0 and 29 THEN "8.30" WHEN Date_format(time2, "%k") IN (8) and Date_format(time2, "%i") between 30 and 59 ...
true
4626b2f0ceddb66c63b1ab9abedc625dcebde09e
SQL
liquid-atmo/CredOrgParser
/src/main/resources/schema.sql
UTF-8
1,119
2.90625
3
[]
no_license
-- -- Table structure for organisations -- DROP TABLE IF EXISTS `organisation`; CREATE TABLE `organisation` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(45) DEFAULT NULL, `bic` varchar(9) DEFAULT NULL, `rn` varchar(5) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSE...
true
87f53fdc8db8501f1340ca142d6a78023f92d975
SQL
leemsxu/ElectronicStoreToolFX
/src/com/laynezcoder/estfx/database/DBElectronicStoreToolFX.sql
UTF-8
2,799
3.34375
3
[ "Apache-2.0" ]
permissive
/* * Copyright 2020-2021 LaynezCode * * 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 applicable law or agree...
true
71ca6ba267a38414f6ff46b7fa12937914007a55
SQL
o-rumiantsev/big-data-etl
/prisma/migrations/20210928145043_add_more_sources/migration.sql
UTF-8
807
2.609375
3
[]
no_license
-- CreateTable CREATE TABLE "OpenJDKEvents" ( "id" UUID NOT NULL, "data" JSONB NOT NULL, "createdAt" TIMESTAMP(3) NOT NULL, CONSTRAINT "OpenJDKEvents_pkey" PRIMARY KEY ("id") ); -- CreateTable CREATE TABLE "MockingBirdEvents" ( "id" UUID NOT NULL, "data" JSONB NOT NULL, "createdAt" TIMESTA...
true
bda5fbeb8643ca5932cd6570307d807c8d9cbcd7
SQL
yakicoconut/Jupiter
/Batch/Create/ExecSql/OutputTableValues.sql
SHIFT_JIS
436
2.6875
3
[]
no_license
/* * e[uf[^o̓XNvg * Eob`t@Cs * EΏۃe[uoƂĕ\ꍇ́uSELECT ovgp */ /* ݒ */ -- un܂Bv̔\ݒ set nocount on /* f[^擾 */ -- hogeMaster SELECT 'hogeMaster' SELECT * FROM hogeMaster WHERE ABC = 'abc' AND DEF = 'def'
true
3a51e852ff19bf99120daa5867661d308c9e3671
SQL
rocks-shivam/GUVI-Day2-Assignment
/Day 1 Assignment done correctly after Discussion in Day 2 Class.sql
UTF-8
3,321
4.46875
4
[]
no_license
-- Doing Day 1 assignment correctly after class of Day 2 create database chubb; show databases; use chubb; -- 1.Creating Tables -- a. Users table create table Users (Id int NOT NULL PRIMARY KEY,User_Name varchar(50)); -- b. Codekata table create table Codekata (Id int NOT NULL PRIMARY KEY,problems_solved int); -- c. ...
true
03c71b1f06415570bb2761ed5d1a1949d3ac2378
SQL
Wowsaruss/personal-project-simulation
/db/seed.sql
UTF-8
3,208
3.28125
3
[]
no_license
SELECT * FROM users; select * from houses; insert into houses (img, loan, name, description, desiredrent, address, zip, city, state) values ( 'https://i.pinimg.com/originals/24/cd/f1/24cdf158b74c9698150655782a4ddb12.jpg', 2347.89, 'school bus', 'bus motor home converion', 0, 'Anywhere I Want', '0', 'home', 'parks' ); ...
true
0576fb0c984cc32ed2bf9f994d9cce450c48a893
SQL
theafghan/softwareProject
/comments.sql
UTF-8
286
3.3125
3
[]
no_license
CREATE TABLE IF NOT EXISTS comments ( course_data_id int not null, comment text not null, when_posted datetime not null, constraint foreign key (course_data_id) references course_data (id) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
true
d577d80cb6583826a778127483b9d10a47d1bc5f
SQL
Ultingg/ManualConnectionREST
/src/main/resources/schema.sql
UTF-8
1,791
2.953125
3
[]
no_license
-- Host: mysql.hostinger.ro -- DB name: u574849695_25 /*!40030 SET NAMES UTF8 */; /*!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 */; /*!40103 SET @OLD_TIME_ZONE = @...
true
a82e9e8a29f59bbbcfa5450a681ac8a62de1837d
SQL
ojmakhura/andromda
/andromda-documentation/samples/timetracker/core/src/main/sql/schema.sql
UTF-8
3,388
3.578125
4
[ "Apache-1.1", "BSD-3-Clause", "Apache-2.0", "LicenseRef-scancode-public-domain" ]
permissive
alter table ROLES_USER drop constraint FK_ebw58iagjenlqywsv77hd06s6 if exists; alter table ROLES_USER drop constraint FK_1sfp0uflxi1alf1kppnp5p4wr if exists; alter table TIMECARD drop constraint FK_sdc0np556eya269aqdlgpm4e0 if exists; alter table TIMECARD drop con...
true
f04f81151eda40a2763f67d788d324d5cd2d47d6
SQL
darthShana/azure-ebean-encryption
/src/main/resources/dbmigration/1.0__initial.sql
UTF-8
389
2.546875
3
[]
no_license
-- apply changes create table customer ( id bigserial not null, name varchar(255) not null, registered date, version bigint not null, when_created timestamptz not null, when_modified ...
true
3d42c699a2d123948c4227bcc73d04a1976e067a
SQL
chrissb7/CRUD-MySql-Form
/USERS.sql
UTF-8
2,132
2.859375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.4 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Apr 05, 2021 at 12:44 PM -- Server version: 10.4.17-MariaDB -- PHP Version: 7.4.15 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
ac4b76341dc5b38a1740869bf0e42c3d031ce3d2
SQL
EduardoFRRZ/EngComp_TCC
/Aplicacao web/banco/funcionarios.sql
UTF-8
3,767
3.28125
3
[]
no_license
-- MySQL Script generated by MySQL Workbench -- qui 02 abr 2020 13:39:06 -- 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
bcbc27f86c5760d382dd8dad785bf12bafbe98cf
SQL
ErmaSwartz/Pewlett-Hackard-Analysis
/Deliverables/mentorship_eligibility.sql
UTF-8
551
3.828125
4
[]
no_license
select emp_no, first_name, last_name, birth_date from employees select from_date, to_date from dept_emp select title from titles SELECT DISTINCT ON (emp_no) emp_no FROM employees ORDER BY emp_no; SELECT employees.emp_no, employees.first_name, employees.last_name, dept_emp.from_date, dept_emp.to_date...
true
6e541a9b9a38c1c838181acf4777d1f270567733
SQL
peytonychen7/mids706w4
/class/dewey_cheatham_howe.sql
UTF-8
4,971
3.234375
3
[]
no_license
-- MySQL dump 10.14 Distrib 5.5.65-MariaDB, for Linux (x86_64) -- -- Host: localhost Database: test5 -- ------------------------------------------------------ -- Server version 5.5.65-MariaDB /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_R...
true
df964182d260da723f01a3539ba3ef43886e9ef1
SQL
ronothnay/ricknmorty
/sql_objects/tables/residents_in_locations.sql
UTF-8
492
3.484375
3
[]
no_license
CREATE TABLE IF NOT EXISTS storefirst.residents_in_locations ( location_id character(50) NOT NULL, character_id character(50) NOT NULL, insertion_time date NOT NULL DEFAULT CURRENT_DATE, PRIMARY KEY (location_id, character_id), CONSTRAINT fk_location FOREIGN KEY (location_id) REFERENCES stor...
true
84ad9c68593779ba0098185790bae0adaaa36e63
SQL
anandeka/my-project
/DBScripts/EODScripts/127_DDL_EODDB_ALTER_SCRIPT.sql
UTF-8
2,397
2.890625
3
[]
no_license
CREATE TABLE ART_ARRIVAL_REPORT_TEMP( GMR_REF_NO VARCHAR2(30), INTERNAL_GMR_REF_NO VARCHAR2(15), INTERNAL_GRD_REF_NO VARCHAR2(15), INTERNAL_STOCK_REF_NO VARCHAR2(30), CORPORATE_ID VARCHAR2(15), WAREHOUSE_PROFILE_ID VARCHAR2(15), WAREHOUSE_NAME ...
true
2e1e305c346929ba31eba920773b229bd7d7e2fb
SQL
juhuage/myproject
/catsic-framework/cats-web-project/src/main/resources/sql/oracle.sql
UTF-8
1,137
3.390625
3
[]
no_license
/*第1步:创建临时表空间 */ CREATE TEMPORARY TABLESPACE CATSIC_TEMP TEMPFILE 'catsic_temp.dbf' SIZE 1024m AUTOEXTEND ON NEXT 1024M MAXSIZE 2048M EXTENT MANAGEMENT LOCAL; /*第2步:创建数据表空间 */ CREATE TABLESPACE CATSIC_DATA DATAFILE 'catsic_data.dbf' SIZE 1024m AUTOEXTEND ON NEXT 1024M MAXSIZE UNLIMITED ONLINE LOGGING FORCE LO...
true
7070da0ab0e91a1e9752b124f1036cc7257669cc
SQL
caseyisonit/Bulleted
/models/schema.sql
UTF-8
924
3.515625
4
[]
no_license
### Schema DROP DATABASE IF EXISTS database_development; CREATE DATABASE database_development; USE database_development; CREATE TABLE todays ( id int NOT NULL AUTO_INCREMENT, todo VARCHAR (255) NOT NULL, PRIMARY KEY (id) ); SELECT * FROM todays; CREATE TABLE weeks ( id int NOT NULL AUTO_INCREMENT, todo VAR...
true
db399e03d471432a9a0fb6036f1ee75bbc547efe
SQL
divineflatus/PAN
/06.sql
UTF-8
294
3.28125
3
[]
no_license
SELECT Title, Last, Cphone, DonDate, Sum(Amount) TotalDonation, MAX(DonDate) Recent From ((person natural join Contact) natural join Donor) natural join donation Where isAnonymous = 1 and MailList = 0 and isPrimary = 1 Group by Title, Last, Cphone, DonDate Order by TotalDonation DESC;
true
1a3d74cde0660a21b499df3cd71f51e827f60c24
SQL
jmp5095/storeVueJs
/mysql.sql
UTF-8
1,144
3.875
4
[]
no_license
CREATE TABLE users( id int(11) primary key auto_increment, name varchar(50) not null, email varchar(100) not null unique, phone varchar(30) ); CREATE TABLE categories( id int(4) primary key auto_increment, name varchar(50) not null, ); CREATE TABLE products( id int(11) primary key auto_increment, na...
true
015ce414b9058cfad0fb074d4f0683609f44be95
SQL
fabriciofmsilva/labs
/alura/banco-de-dados/sql-server-1/aula.sql
UTF-8
4,368
3.734375
4
[ "MIT" ]
permissive
# Aula 1 create database controle_compras; use controle_compras; create table compras ( id int primary key identity not null, valor decimal(18, 2) null, data date null, observacoes nvarchar(200) null, recebida bit null ); sp_help compras; insert into compras (valor, data, observacoes, recebida) values (20...
true
340ebe5cd63686c0271cfa653fc77c06799c0ef3
SQL
Hadden-Industries/oracle
/USERS/RD/TABLES/ABPERSON.sql
UTF-8
4,021
3.140625
3
[ "MIT", "Apache-2.0" ]
permissive
--DROP TABLE ABPERSON PURGE; CREATE TABLE ABPERSON ( ROWID_ INTEGER, FIRST_ VARCHAR2(4000 BYTE), LAST VARCHAR2(4000 BYTE), MIDDLE VARCHAR2(4000 BYTE), FIRSTPHONETIC VARCHAR2(4000 BYTE), MIDDLEPHONETIC VARCHAR2(4000 BYTE), LASTPHONETIC VARCHAR2(4000 BYTE), ORGANIZATION VARCHAR2(4000 BYTE)...
true
31bb213882c4c44878406484dec98067184b9003
SQL
ps-group/ps_judge
/scripts/backend_sandbox_data.sql
UTF-8
1,597
3.5
4
[ "MIT" ]
permissive
 USE `psjudge_frontend`; -- testPasswordHash keeps hash of '2018' string. SET @testPasswordHash = '4476d6a3edee189e699ca3c2cfd80905abc8d999954a08d1c504e6ae437cc28dd4194a1051d84bf5cb2cfc19e09e339ce7f2ff83fec56b07ee39ec2205c2adba'; -- adminPasswordHash keeps hash of 'ej19g72d' string. SET @adminPasswordHash = 'ee17183...
true
487011c64633b8ec85300789ec28c1fe49157ac3
SQL
uchinokot/sql_writing_drill
/2/2-12/3.sql
UTF-8
134
3.0625
3
[]
no_license
SELECT ProductID AS 商品ID , COUNT( * ) AS 売上レコード数 FROM Sales GROUP BY ProductID HAVING COUNT( * ) >= 10 ;
true
4ebbf1a7e3618a0f8d4b02d338aa73d2645c210e
SQL
stokesy56/SQL-Project
/q1.6.sql
UTF-8
588
4.375
4
[]
no_license
--Sales total per region listed if above 1000000 using four joins and the GROUP BY clause to sum total sales per region SELECT t.RegionID, r.RegionDescription, FORMAT(SUM(od.UnitPrice*od.Quantity*(1-od.Discount)),'#######') AS 'Sales Total' FROM Territories t JOIN Region r ON r.RegionID = t.RegionID JOIN EmployeeTerrit...
true
08e25cefbd1fc7be027c305118f1eab4a95d2302
SQL
taerimmk/gridblog
/jpa/db/mysql.sql
UTF-8
1,419
2.875
3
[]
no_license
create database jpa; USE jpa; CREATE TABLE BBS ( ID middleint not null auto_increment primary key, BBS_ID char(20) NOT NULL, NTT_NO decimal(20,0) DEFAULT NULL, NTT_SJ varchar(2000) DEFAULT NULL, NTT_CN mediumtext, NTT_LK varchar(2000) DEFAULT NULL, ANSWER_AT char(1) DEFAULT NULL, PARNTSCTT_NO decimal(...
true
e004377ac77da4ca02a606a30f9307248bd58a9a
SQL
Brettzen/min-cs313-php
/db/technique_images.sql
UTF-8
439
2.90625
3
[]
no_license
-- This will house image information for techniques CREATE TABLE technique_images ( imgId serial NOT NULL PRIMARY KEY, techniqueId int NOT NULL REFERENCES techniques(techniqueId), techniqueTitle varchar(100) DEFAULT NULL, imgDesc text, imgSrc varchar(255) NOT NULL, imgWidth int DEFAULT NULL, imgHeight int...
true
51805d826f1e2388399f857d9c1b13c3b4654ee3
SQL
rodrigocatalan/blank
/schema.sql
UTF-8
3,341
3.78125
4
[ "Apache-2.0" ]
permissive
alter table InstalledSoftware drop foreign key FKB0732321D91B5D10 alter table InstalledSoftware drop foreign key FKB07323216046DD10 alter table Project drop foreign key FK50C8E2F9410275A8 alter table Project_Server drop foreign ...
true
28b8f9dd8089da571e48a09b9b533e68a5cadc96
SQL
murongyouyang/ORACLE_SQL
/PL_SQL/CREATE_TRIGGER_LINEITEMS_TRIGGER.SQL
UTF-8
785
3.890625
4
[]
no_license
CREATE TABLE ORDERS ( ORDER_ID NUMBER PRIMARY KEY, /* OTHER ATTRIBUTES */ LINE_ITEMS_COUNT NUMBER DEFAULT 0 ); CREATE TABLE LINE_ITEMS ( ORDER_ID REFERENCES ORDERS, SEQ_NO NUMBER, /* OTHER ATTRIBUTES */ CONSTRAINT LINEITEMS PRIMARY KEY (ORDER_ID, SEQ_NO...
true
709dce552309ed1c31f96974105751a3a6a8821f
SQL
Mabrural/perpustakaan-update-
/PERPUSTAKAAN(update)/db_perpustakaan1(fix).sql
UTF-8
209,711
2.890625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 28, 2019 at 11:30 AM -- Server version: 10.1.38-MariaDB -- PHP Version: 5.6.40 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
ec7edd66b555933e7758452908c32cf49d973d87
SQL
NayanaMadhuwantha/ecorner-nayanajith
/Database Backup/ecorner_old.sql
UTF-8
5,642
2.953125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Apr 05, 2020 at 01:34 PM -- Server version: 10.4.11-MariaDB -- PHP Version: 7.4.3 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
22ca8c01c4b8a09c4b76d0c94b41d2c52e58ba32
SQL
jmfrazier/lesson-1-files
/1.2.4.1.sql
UTF-8
448
4.09375
4
[]
no_license
with rainy as ( select date from weather where events like 'rain' group by date ) --doesnt work --select -- trip_id, -- duration, -- start_date <-- need to extract date, use date function --from -- trips --join -- rainy --on -- rainy.date = trips.start_date --order by duration desc --limit 3 select tri...
true
22df31706c21ca75f3cef894f4657c9c2609cc5a
SQL
zafinjatovo/Pointage_Salaire
/Base/view.sql
UTF-8
794
3.4375
3
[]
no_license
-------------- VIEW CREATE VIEW ADMIN AS select *,token(id) from t_admin; CREATE VIEW USERS AS select *,coalesce(tokenuser(id),'not valid') as token from t_user; CREATE VIEW V_USER_NOVALID AS select * from t_USER where isValid=0; CREATE VIEW EMPLOYEE AS select * from t_employee where isdeleted=0; CREATE VIEW EMPL...
true
2cddf47027072e461ad58fdbaa779141c313db14
SQL
achillesrasquinha/fluxviz
/src/fluxviz/data/bootstrap.sql
UTF-8
673
2.84375
3
[ "MIT" ]
permissive
PRAGMA foreign_keys = ON; CREATE TABLE IF NOT EXISTS `tabSettings` ( `version` TEXT NOT NULL ); CREATE TABLE IF NOT EXISTS `tabProxies` ( `host` TEXT NOT NULL, `port` INTEGER NOT NULL, `secure` INTEGER NOT NULL, `anon...
true
60aea78274a76f1d0a396b71a62966545f4515ed
SQL
em-rich3/java-web-dev-techjobs-persistent
/queries.sql
UTF-8
425
3.765625
4
[]
no_license
## Part 1: Test it with SQL SELECT * FROM techjobs.job; ## Columns: id, employer, name, skill ## Part 2: Test it with SQL SELECT * from techjobs.employer where Location = 'St. Louis City'; ## Part 3: Test it with SQL DROP TABLE `techjobs`.`job` ## Part 4: Test it with SQL Select skill.name, skill.description from sk...
true
68983017df63eeaa955481a219371afa61dde456
SQL
zyj866955/flask-demo
/db.sql
UTF-8
5,683
3.375
3
[]
no_license
CREATE TABLE `user_basic` ( `user_id` bigint(20) unsigned NOT NULL AUTO_INCREMENT COMMENT '用户ID', `account` varchar(20) COMMENT '账号', `email` varchar(20) COMMENT '邮箱', `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '状态,是否可用,0-不可用,1-可用', `mobile` char(11) NOT NULL COMMENT '手机号', `password` varchar(93) NULL...
true
4220e4db3e79e840f4d1ea73f97583a876e9f946
SQL
allmp13/IWSSQL
/Passerelle OCS/Logiciels.sql
UTF-8
1,801
3.59375
4
[]
no_license
SELECT CAT.I_CAT_LOGOCS, CASE WHEN (( L.VERSION COLLATE French_CS_AS ) IS NOT NULL) AND (( L.NAME COLLATE French_CS_AS ) NOT LIKE '%[0-9]' ) THEN ( L.NAME COLLATE French_CS_AS ) + ' ' + ( L.VERSION COLLATE French_CS_AS ) ELSE L.NAME COLLATE French_CS_AS ...
true
0b73d692633c3ea81ba1fa27a6b27b03b825deda
SQL
ColetonS/Library-App
/db/seed.sql
UTF-8
678
3.265625
3
[]
no_license
CREATE TABLE books ( id SERIAL PRIMARY KEY, title VARCHAR, author VARCHAR, description VARCHAR, img VARCHAR ); SELECT * FROM books; INSERT INTO books (title, author, description, img) VALUES('Train Dreams', 'Dennis Johnson', 'Recommended by Adrien', 'https://images-na.ssl-images-amazon.com/images/I/91cR7SY43SL.jpg'),...
true
d1f0a8a16e8bb276be97f95876113fe7cb6e2939
SQL
hanaa-hajj/mifosx
/mifosng-db/patchesPutOnDemoServer20121001/patch-0001-add-deposit_account_id-for-m_note.sql
UTF-8
288
2.921875
3
[]
no_license
ALTER TABLE `m_note` ADD COLUMN `deposit_account_id` bigint(20) DEFAULT NULL AFTER `loan_transaction_id`, ADD KEY `FK_m_note_m_deposit_account` (`deposit_account_id`), ADD CONSTRAINT `FK_m_note_m_deposit_account` FOREIGN KEY (`deposit_account_id`) REFERENCES `m_deposit_account` (`id`);
true
dcfbc216861ab4bb6ef22ca1bd9dd81aacd0634d
SQL
riemann1859/Queries-and-Visualizations-on-Northwind-database
/T3.orders_with_min_orderID_for_each_employee.sql
UTF-8
747
3.765625
4
[]
no_license
select * from orders where "OrderID" in ( select min("OrderID") as min_ from orders group by "EmployeeID" ) -- use 'any' predicate select * from orders as o1 where not "OrderID" > any ( select ...
true
4c9a399da2bb6556a4daa1eece727181ef4ca9a6
SQL
Ameeeer/JavaLabV2.0-19-20
/InformPara/src/main/java/com/company/servlets/createDB.sql
UTF-8
497
2.953125
3
[]
no_license
create table mySiteUsers( id INTEGER, Email varchar(255) not null primary key, Login varchar(255) not null , Password varchar(255) not null, country varchar (100) not null, infoAboutUser varchar(255), userRole varchar(10) default null ); delete from mySiteUsers where id >= 1; create sequence id_seq minv...
true
35aa7513e942f820a4d02cee7c4646ab13e15e7f
SQL
dsteven12/mysql_bootcamp
/book_shop_db/book_exercises.sql
UTF-8
675
3.59375
4
[]
no_license
SELECT UPPER(CONCAT('my favorite author is ', CONCAT(author_fname, ' ', author_lname), '!')) AS 'Yell' FROM books ORDER BY author_lname; -- SELECT title, author_lname -- FROM books -- ORDER BY author_lname, title; -- SELECT title, released_year, stock_quantity -- FROM books -- ORDER BY stock_quantity ASC -- LIMIT ...
true
56bb3f20093a471066c30368a1f11d2f0d490c40
SQL
pavetw17/Data-warehouse-and-Big-Data
/week7.sql
UTF-8
5,438
4.28125
4
[ "MIT" ]
permissive
--1. Write a query to count the number of customers with a customer balance over $500 SELECT COUNT(*) FROM CUSTOMER WHERE CUS_BALANCE > 500; --2. Write a query to list all products (only columns Product code and Description should be displayed) for which no --vendor code has been specified. SELECT * FROM PRODUC...
true
ec021ad0343605211e3baa03b82d67a69d4c67a6
SQL
Admiralsourav/Training-Assignments
/Spring Data JPA/hands on 3/orm-learn/ormlearn.sql
UTF-8
965
3.6875
4
[]
no_license
show databases; create database ormlearn; use ormlearn; show tables; create table department (dp_id INT NOT NULL auto_increment primary key , dp_name VARCHAR(45)); create table employee (em_id INTEGER NOT NULL auto_increment, em_name VARCHAR(45), em_salary DOUBLE, em_permanent BOOLEAN, em_date_of_birth...
true
9ca9abe322ba492cf4315c7dd9936acb8b6680d4
SQL
kuhcaktyerdna/sqlTasks
/part2/5.sql
UTF-8
411
3.359375
3
[]
no_license
--5. Напишите запрос, использующий ANY или ALL, который бы находил всех продавцов, которые не имеют никаких заказчиков, -- размещенных в их городе. select * from salespeople where city != all (select city from customers); select * from salespeople where not (city = any (select city from customers));
true
61c9ede197defeed9cdcc2a9fae36dc8641ac35a
SQL
Pranav2724/LEARN-DATA-SCIENCE
/SQL/basic sql-2.sql
UTF-8
1,109
3.421875
3
[]
no_license
create database University; show databases; use University; show tables; cReate table student(RollNumber int Primary Key, name varchar(100), Address varchar(500), ContactNumber bigint); creaTE table faculties(facultyid int Primary Key, name varchar(100) Not NULL, class varchar(500), emailid varchar(500)); insert into s...
true
8967187687ce6b62cb8d6acb4228dea0a6ec020d
SQL
PosTracker/VuejsApp1
/VuejsApp1/db/getFavorites.sql
UTF-8
192
3.015625
3
[]
no_license
SELECT favorite.user_id, products.title, products.price, products.product_img, favorite.product_id FROM favorite FULL OUTER JOIN products ON favorite.product_id=products.id WHERE user_id = $1;
true
d8f02ef55c3363fe3d9d0a55e3949947bbc72c83
SQL
Irwankurniawan/lavaresto
/e-order.sql
UTF-8
7,261
3.171875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 11 Mar 2021 pada 09.45 -- Versi server: 10.4.11-MariaDB -- Versi PHP: 7.4.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CH...
true
ce292c4b97b4c30866a6ac638f62347064ace07f
SQL
staser/country-list
/country/cldr/ga/language.mysql.sql
UTF-8
9,725
2.53125
3
[ "MIT" ]
permissive
CREATE TABLE country (id VARCHAR(2) NOT NULL, name VARCHAR(64) NOT NULL, PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE = InnoDB; INSERT INTO `country` (`id`, `name`) VALUES ('ab', 'Abcáisis'); INSERT INTO `country` (`id`, `name`) VALUES ('af', 'Afracáinis'); INSERT INTO `country` (`id`, `n...
true
324da336badbb635b63941ec808d01f2501f29a9
SQL
radtek/abs3
/sql/mmfo/bars/Table/dpu_types_freq.sql
WINDOWS-1251
4,194
3.328125
3
[]
no_license
PROMPT ===================================================================================== PROMPT *** Run *** ========== Scripts /Sql/BARS/Table/DPU_TYPES_FREQ.sql =========*** Run ** PROMPT ===================================================================================== PROMPT *** ALTER_POLICY_INFO...
true
22f829f68f6496037e5d130783475a036dbe948e
SQL
dozz1e/Prueba-Skate-Park
/database.sql
UTF-8
469
2.515625
3
[]
no_license
CREATE DATABASE skatepark; CREATE TABLE skaters (id SERIAL PRIMARY KEY, email VARCHAR(50) PRIMARY KEY, nombre VARCHAR(25) NOT NULL, password VARCHAR(100) NOT NULL, anos_experiencia INT NOT NULL, especialidad VARCHAR(50) NOT NULL, foto VARCHAR(255) NOT NULL, estado BOOLEAN NOT NULL); INSERT INTO skaters (email,nombre,...
true
0ea91545a702f2ea5cae2fadc91fe84e48c692e0
SQL
Er-DhruvMishra/webo
/MySQLscript.sql
UTF-8
4,774
3.046875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.5.2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Aug 07, 2018 at 01:42 PM -- Server version: 5.5.25a -- PHP Version: 5.4.4 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_...
true
6beb0a887be1c69a5a65316b9a9119db51a4b884
SQL
TaikiFnit/json-cms
/sql/setup.sql
UTF-8
469
3.421875
3
[ "Apache-2.0", "MIT" ]
permissive
create table `news` ( `news_id` int not null primary key unique, `title` text, `content` text, `author` text, `created` date, index(`news_id`) ) CHARACTER SET 'utf8' ENGINE=InnoDB; create table `images` ( `image_id` int not null auto_increment primary key unique, `news_id` int, `ima...
true
5e087126d05ee2648f20b79eb9f21c74d16bf398
SQL
madhurivaishnav/SALTWEB
/SALT_NewDesign/Database/Procedure/dbo.prcQuiz_GetModuleIDBySessionID.PRC
UTF-8
1,193
3.671875
4
[]
no_license
SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[prcQuiz_GetModuleIDBySessionID]') AND type in (N'P', N'PC')) BEGIN EXEC dbo.sp_executesql @statement = N' /* Summary: Parameters: @ToolbookID varchar(50) Returns: integer Called By: ToolbookListener...
true
6f53a91100241b515d43f7804776db7880276998
SQL
zzz0906/LeetCode
/Scripts/196.sql
UTF-8
80
2.609375
3
[ "MIT" ]
permissive
DELETE p2 FROM Person p1, Person p2 WHERE p1.Email = p2.Email AND p2.Id > p1.Id;
true
be7e01557359d1c21e61605d12b249671fee2ea4
SQL
CUBRID/cubrid-testcases
/sql/_26_features_920/issue_10161_partition_collate/cases/list_006.sql
UTF-8
5,298
2.515625
3
[ "BSD-3-Clause" ]
permissive
set names euckr; CREATE TABLE t1 (a VARCHAR (30) collate utf8_en_ci) PARTITION BY LIST (a) ( PARTITION a1 VALUES IN ('A') ); insert into t1 values ('a'), ('A'); select * from t1 order by 1; drop table t1; CREATE TABLE t1 (a VARCHAR (30) collate euckr_bin) PARTITION BY LIST (a) ( PARTITION a1 VALUES IN ('A') ...
true
ca9dc19e52a4c6b3ce753dc87f509b5f783446f3
SQL
ffxdigital/influencers
/install/dump.sql
UTF-8
26,830
3.25
3
[ "Apache-2.0" ]
permissive
CREATE TABLE `plugins` ( `identifier` varchar(32) COLLATE utf8mb4_unicode_ci DEFAULT NULL, `name` varchar(32) COLLATE utf8mb4_unicode_ci DEFAULT NULL, `color` varchar(7) COLLATE utf8mb4_unicode_ci DEFAULT 'black', `status` int(11) DEFAULT '0', UNIQUE KEY `identifier` (`identifier`) ) ENGINE=InnoDB D...
true
da3736029927bd5612d5c713cce8c7fd572cef0e
SQL
aaqib1992-gmail-com/PHP_test
/sql.sql
UTF-8
3,849
3.09375
3
[ "MIT" ]
permissive
DROP DATABASE IF EXISTS races; CREATE DATABASE races; USE races; CREATE TABLE races ( id int not null AUTO_INCREMENT, name VARCHAR(255), number int, start_date DATETIME, meeting_name VARCHAR(255), distance int, status_id INT, PRIMARY KEY (id) ); CREATE TABLE runners ( id int not n...
true