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
9bd423f35e2c62523fc1aba3ad14468816e32701
SQL
hongyouqin/ppms
/ppms/ppms-admin/src/main/resources/db/schema.sql
UTF-8
247
2.6875
3
[]
no_license
-- 用户信息表 CREATE TABLE user_info ( id BIGINT IDENTITY PRIMARY KEY , email VARCHAR(20) NOT NULL, pwd VARCHAR(20) NOT NULL, user_name VARCHAR(20) NOT NULL, created_time DATETIME, login_time DATETIME ); -- 收入表
true
af265ab9158f37355a3a4a7e7b92c4baa175876f
SQL
jkyjustin/TeamTree
/start.sql
UTF-8
4,989
4.0625
4
[]
no_license
DROP TABLE Accounts CASCADE CONSTRAINTS; DROP TABLE Students CASCADE CONSTRAINTS; DROP TABLE Employers CASCADE CONSTRAINTS; DROP TABLE Schools CASCADE CONSTRAINTS; DROP TABLE Courses CASCADE CONSTRAINTS; DROP TABLE Companies CASCADE CONSTRAINTS; DROP TABLE Endorsements CASCADE CONSTRAINTS; DROP TABLE Reviews CAS...
true
2b172e4f06b4b10eda29d0827710cb148de4ea53
SQL
vkscorpio3/atg_training
/workspace/modules/ClothingStore/build/atgsql/DCS/sql/db_components/db2/contracts_ddl.sql
UTF-8
1,051
3.140625
3
[]
no_license
-- @version $Id: //product/DCS/version/11.2/templates/DCS/sql/contracts_ddl.xml#1 $$Change: 946917 $ -- Normally, catalog_id and price_list_id would reference the appropriate table it is possible not to use those tables though, which is why the reference is not included create table dbc_contract ( contract_id var...
true
ee4b900ff0a8674aa65ff8b34b86bd56f4162c6e
SQL
amrit1996/mounty-backend-test
/productform.sql
UTF-8
2,630
3.265625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.7 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Mar 14, 2019 at 04:23 PM -- Server version: 10.1.30-MariaDB -- PHP Version: 7.2.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
1894d21181afc6e57d331de49f28618e5acebab8
SQL
jiangqianghua/seckill
/schema.sql
UTF-8
1,747
3.96875
4
[]
no_license
-- 数据库初始化脚本 -- 创建数据库 CREATE database IF NOT EXISTS seckill default charset utf8 COLLATE utf8_general_ci; --使用数据库 use seckill ; -- 创建秒杀库存表 CREATE TABLE `seckill`( `seckill_id` bigint NOT null AUTO_INCREMENT COMMENT'商品库存id', `name` varchar(120) NOT NULL COMMENT '商品名称', `number` int NOT NULL COMMENT '库存数量', ...
true
a70d218bedee589ba468f3f22ddc8646c3903b93
SQL
USLabs/SpartanFlix
/database_design/schema/Scripts/testedByUmang/28. GetAdsForAdvertiser.sql
UTF-8
750
3.28125
3
[]
no_license
use CMPE226_SPARTAN_FLIX; drop procedure if exists prc_get_ads_for_advertiser; delimiter // create procedure prc_get_ads_for_advertiser(in advertiser_id int unsigned, in _search VARCHAR(128), in _title VARCHAR(128)) begin declare searchT varchar(128); declare titleT varchar(128); set searchT = coalesce(_search...
true
3f96829a97b4c3f65e5b120fa4d666f4c165c0ec
SQL
topfreegames/mqtt-history
/scripts/create.cql
UTF-8
309
2.9375
3
[ "MIT" ]
permissive
CREATE KEYSPACE IF NOT EXISTS chat WITH REPLICATION = { 'class': 'SimpleStrategy', 'replication_factor': 1 }; CREATE TABLE IF NOT EXISTS chat.messages ( id timeuuid, topic varchar, payload varchar, bucket int, PRIMARY KEY ((topic, bucket), id) ) WITH CLUSTERING ORDER BY (id DESC);
true
e5e3b939fc617b644e4461ba669fee88b8652bb5
SQL
sprokushev/Delphi
/MASTER/_DATABASE/Tables/KLS_VOZN_RST.sql
WINDOWS-1251
1,578
3.28125
3
[]
no_license
-- -- KLS_VOZN_RST (Table) -- CREATE TABLE MASTER.KLS_VOZN_RST ( ID NUMBER(10) NOT NULL, IS_AGENT NUMBER(10) DEFAULT NULL, BEGIN_DATE DATE, END_DATE DATE, ID_GROUP_NPR VARCHAR2(5 BYTE), PROD_ID_NPR VARCHAR2(5 BYTE), VAGOWN_TYP_ID ...
true
a4ed8179316efe17bfaa643e76c7bed4c9bae653
SQL
alialaghbandrad/Warehouse-Management-System
/SQLQuery-Warehouse.sql
UTF-8
3,937
4.21875
4
[]
no_license
use warehouse; CREATE TABLE Customer ( CustomersID int identity(1,1) NOT NULL, CompanyName nvarchar(45) NOT NULL, ContactName nvarchar(45) NOT NULL, Address nvarchar(45) NOT NULL, City nvarchar(45) NOT NULL, Province nvarchar(45) NOT NULL, Country nvarchar(45) NOT NULL, Phone nvarchar(45) NOT NULL, ...
true
e203a2ce00cc4c6005a655327e0f45f33be64d2f
SQL
ksmerwin/TravelAgency-CIS560
/DataModeling/SQL/Reports/Agency.AgeReport.sql
UTF-8
1,007
4.3125
4
[]
no_license
/* Report query: Aggregates customers into three age categories, "Young Adult," "Middle Aged", and "Senior." */ CREATE OR ALTER PROC Agency.AgeReport AS SELECT CASE WHEN C.Age BETWEEN 16 AND 29 THEN 'Young Adult' WHEN C.Age BETWEEN 30 AND 60 THEN 'Middle Aged' WHEN C.Age > 60 THEN 'Senior' END AS AgeGroup, ...
true
bd3e8b45cd4bf6513d6aeca8e0638d567fa00953
SQL
France-ioi/bebras-platform
/dbv_data/revisions/428/translations.sql
UTF-8
400
3.046875
3
[ "MIT" ]
permissive
CREATE TABLE `translations` ( `ID` int(11) NOT NULL AUTO_INCREMENT, `languageID` int(11) NOT NULL, `category` varchar(50) CHARACTER SET utf8 NOT NULL, `key` varchar(50) CHARACTER SET utf8 NOT NULL, `translation` text CHARACTER SET utf8 NOT NULL, PRIMARY KEY (`ID`), UNIQUE KEY `id_in_template` (`category`,...
true
91e4159b4f7082b1f1a7fa311645e6e6ed47e06a
SQL
hashgraph/hedera-mirror-node
/hedera-mirror-importer/src/main/resources/db/migration/v1/V1.46.9__smart_contracts_children.sql
UTF-8
5,952
4
4
[ "Apache-2.0" ]
permissive
-- Fixes up the smart contract tables after normalizing the contract result raw protobuf into discrete columns alter table if exists contract add column if not exists parent_id bigint null, alter column memo set default ''; alter table if exists contract_history add column if not exists parent_id bigint n...
true
a2172f0c7ccfdd31c2fa1a6ccca2266f8a6e962e
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day18/select1653.sql
UTF-8
178
2.65625
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-17T16:53:00Z' AND timestamp<'2017-11-18T16:53:00Z' AND temperature>=22 AND temperature<=70
true
d785246f77f7e41e8b32788178fae825fd3e3c5e
SQL
BG30/eHealth
/smarthealth.sql
UTF-8
6,375
3.390625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Nov 11, 2018 at 06:06 AM -- Server version: 10.1.36-MariaDB -- PHP Version: 7.2.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
95256e6c7d2c1aa42fd24426530cb2ce487e373b
SQL
Lundalogik/LimeBootstrapAppStore
/businessOverview/install/scp_BusinessOverviewTranslation.sql
ISO-8859-1
2,170
2.828125
3
[]
no_license
insert into localize ([status], createduser, updateduser, [timestamp], createdtime, [owner], code, sv, [no], en_us, context, lookupcode) VALUES (0, 1, 1, GETDATE(), GETDATE(), 'app_businessoverview', 'lasthistorie', 'dag sedan sista kontakten', 'dag siden sist kontakt', 'day since last contact', 'Translation for ...
true
ed09db617caaeb6a6b07de1e12712ec9c6123fbd
SQL
SF-Felling7/new-pet_hotel
/pet_hotel_db.sql
UTF-8
924
3.65625
4
[]
no_license
CREATE TABLE owners ( owner_id SERIAL PRIMARY KEY NOT NULL, owner_name VARCHAR(12), address VARCHAR(25), phone VARCHAR(13) ); CREATE TABLE pets ( pet_id SERIAL PRIMARY KEY NOT NULL, pet_name VARCHAR(20), color VARCHAR(13), Breed VARCHAR(20) ); CREATE TABLE visits ( visit_id SERIAL ...
true
f6f3007cf375a44ce924b08c1326364b88d1ca19
SQL
MarceloData/apiPHP
/apiMySql.sql
UTF-8
1,862
3.53125
4
[]
no_license
CREATE TABLE `users` ( `id` int PRIMARY KEY AUTO_INCREMENT, `id_groups` int UNIQUE, `name` varchar(255) NOT NULL, `email` varchar(255) NOT NULL, `avatar` varchar(255), `birthday` timestamp, `password` varchar(255) NOT NULL, `token` varchar(255), `created_at` timestamp DEFAULT (now()), `updated_at` t...
true
4d913a2232c98c9e4cf8811d9a9748e0723caa95
SQL
FahadAminShovon/SQLZOO_solutions
/solves/solve3.sql
UTF-8
2,579
4.46875
4
[]
no_license
--1. --Change the query shown so that it displays Nobel prizes for 1950. SELECT yr, subject, winner FROM nobel WHERE yr = 1950 --2. --Show who won the 1962 prize for Literature. SELECT winner FROM nobel WHERE yr = 1962 AND subject = 'Literature' --3. --Show the year and subject that won 'Albert Einstei...
true
fd2d88292fe8ce37501539bf016b27719b59e405
SQL
naomiwhidden/innovation_challenge_testing
/redonkulator_app/db/demo.sql
UTF-8
5,295
3.734375
4
[]
no_license
-- User logs into the website for the first time, creates self in users table insert into users (email, edipi, display_name, phone) VALUES ('christopher.breen@usmc.mil', '1111111111', 'Breen MGySgt Christopher P', '619-701-2017'); -- User creates a a new exercise insert into exercises (exercise, evolution, start_date,...
true
b407db3993ea1c32b0acfa64713a040aabe65b56
SQL
TheChanec/mcs.repository
/Database/dbo/Stored Procedures/Procs2/mcs_ResetInvoiceToBeResentToNewInvoiceByWorkOrderNum.sql
UTF-8
396
2.984375
3
[]
no_license
create procedure dbo.mcs_ResetInvoiceToBeResentToNewInvoiceByWorkOrderNum @work_order_num bigint as update mcs_output_files set mcs_output_files.new_inv_extract_flag = null from mcs_output_files inner join wo_invc on wo_invc.wo_invc_id = mcs_output_files.wo_invc_id inner join work_orders on work_orders.w...
true
7c1b143c7edcece7748afae1aec6d27868d508bd
SQL
pablobergna/TPDATOS
/PRACTICA/Gestion de Datos - Ejercicios/PracticaSQL/08.sql
ISO-8859-1
599
3.96875
4
[]
no_license
SELECT e.d_elemento, (SELECT TOP 1 SUM(s.canitdad) FROM dbo.STOCK s JOIN dbo.DEPOSITO d ON d.id_deposito = s.id_deposito WHERE s.id_elemento = e.id_elemento GROUP BY d.id_deposito ORDER BY SUM(s.canitdad) DESC) AS 'Stock en el depsito que ms tiene' FROM dbo.ELEMENTO e JOIN dbo.PRODUCTO p ON ...
true
833ed6b31e901be54cf4bac896b631c104b11a88
SQL
ParsianInsuranceGIT/sanam
/queries/Delete Karmozd.sql
UTF-8
1,267
3.234375
3
[]
no_license
-------------------------------------Report------------------------------------- --select count(kargst.karmozd_amount),sum(kargst.karmozd_amount), -- krnama.namayande_id,krnama.amount , -- crdbt.amount_long as credebit_amount,krnama.id as karmozd_namayande_id, crdbt.id as credebit_id --from tbl_karmozd_ghes...
true
f4039d49966ccd0a87da5e11e26daf3175ad9a3b
SQL
wsigma21/sql_exercises
/introduction/question46.sql
UTF-8
391
3.390625
3
[]
no_license
-- 副問い合わせを使って全体の平均身長と各ポジションの平均身長を抽出する。 -- select (select position,avg(height) from players group by position) -- ans -- 2列目はavg(height)でないと各ポジションの平均身長にならないよね? select position,avg(height), (select avg(height) from players) as avg_height from players group by position ;
true
25b657faa789e83ccb6e79121462f3bceacda8e0
SQL
hkq325800/book
/book_empty.sql
UTF-8
9,129
3.359375
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : apartment Source Server Version : 50620 Source Host : localhost:3306 Source Database : book Target Server Type : MYSQL Target Server Version : 50620 File Encoding : 65001 Date: 2014-12-29 08:38:20 */ SET FOREIGN_KEY_CHECKS=0; -- ----...
true
00cd97f4ed0b53e814c984559c8c14ec772c3832
SQL
polarbears-xzf/xzfgit
/zoeMonitor/checkup_report/content_project_info.sql
UTF-8
2,157
2.828125
3
[]
no_license
-- Created in 2018.10.11 by polarbears -- Copyright (c) 20xx, CHINA and/or affiliates. -- All rights reserved. -- Name: -- content_project_info.sql -- Description: -- 基本说明 -- Relation: -- 对象关联 -- Notes: -- 基本注意事项 -- 修改 - (年-月-日) - 描述 -- -- ======================================= -- 项目基本信息 -- ==============...
true
e4b1270db0d34a54698287480a7087ca50921b69
SQL
jmakine/Tsoha-Bootstrap
/sql/add_test_data.sql
UTF-8
1,423
3.28125
3
[]
no_license
-- Lisää INSERT INTO lauseet tähän tiedostoon --Kayttaja -taulun testi-data INSERT INTO Kayttaja(tunnus, salasana) VALUES ('jenni', 'penninenn'); --Luokka -taulun testi-data INSERT INTO Luokka(nimi, luotu_pvm, kuvaus, luokka_id, kayttaja_id) VALUES ('Arkiaskareet', NOW(), 'Tänne perus kotihommia, mm. siivoiluja...
true
39fc2bff2ddbb965f6d80625a0c3ee506463fb55
SQL
AbidRaza1/Querying-Adventure-works-database
/SQLQuery11.sql
UTF-8
1,419
3.546875
4
[]
no_license
SELECT MAX(UnitPrice) FROM SalesLT.SalesOrderDetail SELECT * FROM SalesLT.Product WHERE ListPrice > (SELECT MAX(UnitPrice) FROM SalesLT.SalesOrderDetail) SELECT CustomerID, SalesOrderID FROM SalesLT.SalesOrderHeader AS S01 ORDER BY CustomerID, SalesOrderID SELECT CustomerID, SalesOrderID, OrderDat...
true
f0ccf930aa1130ed6dab40d1a59c5b08ff22b0e8
SQL
heartbeat007/sql_prac
/thirtythree.sql
UTF-8
415
3.65625
4
[]
no_license
/* Enter your query here. THE CODE IS TRICKY LET ME EXPLAIN THE QUESTION IS Query the Western Longitude (LONG_W) for the largest Northern Latitude (LAT_N) in STATION that is less than 137.2345. SELECT THE LONG_W FROM THE MAXIMUM VALUE OF THE LIST ,THE LIST WHICH IS LESS THAN 137.2345; WE NEED A SUB QUARY */ SELECT ROU...
true
4d541c1915462d962aca8907adfb0ff0d3799f8f
SQL
nip3o/tddd43
/lab1/lab1-contents.sql
UTF-8
547
2.921875
3
[]
no_license
INSERT INTO `Expert` (`id`, `name`, `email`) VALUES (1,'Niclas Olofsson','nicol271@student.liu.se'), (2,'Holger Grenquist','holger@grenquist.se'); (3,'Arne Anka','arne@anka.se'); INSERT INTO `ExpertArea` (`id`, `description`, `parent`) VALUES (1,'Computer Science',NULL), (2,'Databases',1), (3,'SQL',2), (4,...
true
02780558227a9bacf2bd9c249ab2f0072bcd9a43
SQL
SandipDankhra/SQL
/Module_5/Exercise_1(Solution).sql
UTF-8
484
2.96875
3
[]
no_license
use AdventureWorks CREATE TABLE SALES.MEDIAOUTLET ( MEDIAOUTLETID INT NOT NULL PRIMARY KEY IDENTITY(1,1), MEDIAOUTLETNAME NVARCHAR(40), PRIMARYCONTACT NVARCHAR (50), CITY NVARCHAR (50) ); DROP TABLE SALES.MEDIAOUTLET; CREATE TABLE SALES.PRINTMEDIAPLACEMENT( PRINTMEDIAPLACEMENTID INT NOT NULL PRIMARY KEY IDENTITY(1,...
true
e52981662412e0f32fc2a55017d84d85f6f5e88e
SQL
Peadz/MEDAS_1_19-20
/TRAN Octavia/modele.sql
UTF-8
5,900
3.234375
3
[ "CC0-1.0" ]
permissive
-- MySQL Script generated by MySQL Workbench -- Wed Apr 22 21:58:41 2020 -- 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
dbf3aabf949f732d2c0842a40dc48a3ca8c9d114
SQL
vltsu/spring_crud
/src/main/resources/db/migration/V1__create_user_table.sql
UTF-8
322
2.546875
3
[]
no_license
CREATE TABLE users ( email varchar(100) not null primary key, name varchar(100) DEFAULT ''::character varying, password varchar(100) not null, image text, enabled boolean NOT NULL DEFAULT false, created_at timestamp(0) with time zone NOT NULL, updated_at timestamp(0) with time zone NOT NULL ...
true
0b5604e3c0875d8db9d18fd3bcec0ac8e3b83cf4
SQL
fagoner/japser-demo-report
/db/sql/V1_0__init.sql
UTF-8
315
3
3
[]
no_license
USE back; CREATE TABLE IF NOT EXISTS `back`.`category`( id INT UNSIGNED NOT NULL AUTO_INCREMENT, name VARCHAR(100) NOT NULL, created_at DATETIME NOT NULL, active BOOLEAN NOT NULL, PRIMARY KEY(id) ); INSERT INTO back.category(name, created_at, active) VALUES ("Demo Category", NOW(), 1);
true
d22ff7f74c6cadca2917cc30ce81067c86ab25d3
SQL
KeishawnJohnson/projectTwo
/clothingtable.sql
UTF-8
1,100
3.84375
4
[]
no_license
### Schema drop database outfits_db; CREATE DATABASE outfits_db; USE outfits_db; #Table for outfits #User has the ability to add up to 4 seasons for a specific item (Only the first one is mandatory) #User is able to add up 4 occasions (fomral, work, athletic, casual) #User can choose one of the following clothing typ...
true
cc144a67b2e568eae76445efbc2abd0098c96b39
SQL
naichadadui/trivial-git
/src/main/resources/db/migration/V2__20180107_insert_questions.sql
UTF-8
1,444
2.703125
3
[]
no_license
INSERT INTO `questions` VALUES (1, 1, '从抹香鲸体内提炼出的香料是', '龙涎香', '百里香', '沉水香', '麝香'); INSERT INTO `questions` VALUES (2, 1, '血管破裂时,血液中的什么物质会凝结成块,堵住破裂部分以止血?', '血小板', '红血球', '白血球', '血清'); INSERT INTO `questions` VALUES (3, 1, '在所有巨大的猛兽中,哪种动物的心脏最小?', '狮子', '老虎', '野猪', '猎豹'); INSERT INTO `questions` VALUES (4, 1, '鲸的心脏每小时跳动多少...
true
c594df70db2a63f09f9a0d97a74eb018b8a4efcd
SQL
brunarafaela/aulas_laboratorio_banco_de_dados
/atividade05_correcao.sql
UTF-8
5,808
4
4
[]
no_license
/****************************************************************************************** Atividade 05 - Escreva a instrução em SQL para responder às seguintes consultas: 1) Mostre o nome, e-mail dos alunos, nome do curso e turma, para os alunos que fizeram cursos em que não se matricularam homens; **************...
true
759a71b01d7084558ff489230bf97fb152a21496
SQL
jimmyjzemoso/test_scripts
/script2.sql
UTF-8
1,614
4.09375
4
[]
no_license
INSERT INT0 udm_product SELECT ${:udm_s_product::s.%1$s AS %1&S}, SELECT ${columns:udm_s_product:~Availability: COALESCE(dw.%1&s,sparse.%1&s AS %1&s}, CASE WHEN COALESCE(sparse.Availability,0) > 0 THEN "Available" ELSE "No" END AS Availability, CASE WHEN (CASE WHEN COALESCE(sparse.Availability,...
true
45a6f1f655eaa78910ad1706d0ba19a8d28a156d
SQL
ypfedotov/user-registry
/backend/src/main/resources/db/migration/V2__user_table.sql
UTF-8
312
2.734375
3
[]
no_license
CREATE TYPE gender_type AS ENUM ('MALE', 'FEMALE'); CREATE TABLE userregistry.user ( id UUID PRIMARY KEY, full_name VARCHAR(255) NOT NULL, email VARCHAR(255) NOT NULL UNIQUE, username VARCHAR(255) NOT NULL UNIQUE, date_of_birth DATE NULL, gender gender_type NULL, photo TEXT NULL );
true
7b5da1efb1bd6c339fd3f6abe5f5ae03d22c39c1
SQL
vinoth12940/StallionsCCNewSite
/src/main/resources/sqlScripts/scorecard-details.sql
UTF-8
3,378
3.46875
3
[]
no_license
-- -- Table structure for Score card Details-- -- -- Stallions Score Card -- -- USE `stallionc_cricket_club`; DROP TABLE IF EXISTS `stallions_scorecard`; CREATE TABLE `stallions_scorecard` ( `score_card_id` int(11) NOT NULL, `tournament_id` varchar(50) NOT NULL, `playersSk` int(11) NOT NULL, `match_id` varch...
true
019fb6902ebbde2f1bdcf44bf826a86f26c525e4
SQL
Falmmer/juke-swgoh-bot
/data/struct-update.sql
UTF-8
289
2.546875
3
[ "Apache-2.0" ]
permissive
ALTER TABLE `alliances` ADD `creation_date` DATE NULL DEFAULT NULL AFTER `name`, ADD `update_ts` TIMESTAMP on update CURRENT_TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP AFTER `creation_date`; ALTER TABLE `guilds` ADD `officerCount` INT(1) UNSIGNED NULL DEFAULT NULL AFTER `memberCount`;
true
c3779b6b3741de6149c80e62bffbb7a49588345b
SQL
livelykitten/ccc2019fasting
/create.sql
UTF-8
2,797
4
4
[]
no_license
DROP DATABASE IF EXISTS 18fasting; CREATE DATABASE 18fasting; USE 18fasting; SET FOREIGN_KEY_CHECKS=0; DROP TABLE IF EXISTS Classes; DROP TABLE IF EXISTS Users; DROP TABLE If EXISTS Bible; SET FOREIGN_KEY_CHECKS=1; CREATE TABLE Bible_lecture_time ( blt_id int not null auto_increment, start_time timestamp not null de...
true
66f4d0e467e3834dbd8028a38aa241b9d607e22c
SQL
markkimsal/cognifty
/setup/upgrades/0006_0007/03_change_defaults.mysql.sql
UTF-8
2,202
3.1875
3
[ "BSD-3-Clause" ]
permissive
# MySQL Diff 1.3.3 # # http://www.mysqldiff.com # (c) 2001-2003 Lippe-Net Online-Service # # Create time: 13.01.2008 23:20 # # -------------------------------------------------------- # Source info # Host: localhost # Database: cgn_006 # -------------------------------------------------------- # Target info # Host: lo...
true
e866214808d911e6a666f4b5a286d4e5dd2a7884
SQL
Beachwhale13/DojoAssignments
/SQL/erd_lessons/Untitled.sql
UTF-8
205
3.3125
3
[]
no_license
SELECT countries.name, government_form FROM countries JOIN cities ON countries.id = cities.country_id WHERE government_form = "Constitutional Monarchy" AND life_expectancy > 75 AND countries.capital > 200
true
31a0d436ea133e8efff67c7d65ed9ca9efcb9e43
SQL
andrewajlouny/cosc4800
/COMPANY.sql
UTF-8
4,206
3.25
3
[]
no_license
CREATE TABLE EMPLOYEE (Fname varchar, Minit CHAR, Lname varchar, Ssn int, Bdate DATE, Address varchar, Sex CHAr, Salary INT, Sup...
true
8bda7e816723042076833c67a563d4354abc1fea
SQL
tekkosu/TheBusyBeavers
/ddl/ethicalEating.sql
UTF-8
1,622
3.90625
4
[]
no_license
DROP TABLE IF EXISTS Users, Recipes, Recipes_Users, Recipes_Ingredients, Ingredients, EthicalIngredients, Ingredients_EthicalIngredients; CREATE TABLE Users( userID INT(50) NOT NULL AUTO_INCREMENT PRIMARY KEY, userName varchar(70) NOT NULL, userPassword varchar(70) NOT NULL, CONSTRAINT UNIQUE (userName) ) ENGINE=INNOD...
true
2fd4e07e6af5fef628a31388ae459a0e39f4a351
SQL
os94/MadCamp-Projects
/Week4_Gdvbs/Gdvbs_Gdvbs/Cart/product.sql
UTF-8
1,459
3
3
[]
no_license
CREATE TABLE IF NOT EXISTS `tbl_product` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(255) NOT NULL, `image` varchar(255) NOT NULL, `price` double(10,2) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=4 ; -- -- Dumping data for table `tbl_produ...
true
194422f553fc0eba710a7d0ece20da05f6a9b597
SQL
sekrarange/mediaplayer
/database.sql
UTF-8
1,482
3.390625
3
[ "MIT" ]
permissive
DROP DATABASE IF EXISTS mediaplayer; CREATE DATABASE mediaplayer; -- luo tietokanta USE mediaplayer; -- käytä tietokantaa CREATE TABLE kayttaja (id INT PRIMARY KEY, tunnus VARCHAR(60), salasanatiiviste VARCHAR(60)); CREATE TABLE kappale (id INT PRIMARY KEY, pituus VARCHAR(20), artisti VARCHAR(50), genre VARCHAR(20),...
true
b6d2a927f6234eab4566674a2d80d6b08bc084db
SQL
hyunsiks/mySQL
/SQL/20_뷰.sql
UHC
1,556
3.921875
4
[]
no_license
/* # (View) - ⺻ ̺ ̿ ̺ - ⺻ ̺ Ļ DBü - 並 () ⺻ ̺ Ҽ ֵ ִ # ϱ CREATE [OR REPLACE] VIEW ̸ AS [WITH CHECK OPTION | [WITH READ ONLY]]; - CREATE OR REPLACE : ̹ ϴ Ѵ. ٸ Ѵ. - WITH CHECK OPTION : ش ϴ DML .(DML) - WITH READ ONLY : ش ...
true
6d625dbeff76395afe9e5cb42357ed4ef608548d
SQL
juanmvm1331/Sensores1
/SQL/EJERCICIOS_SELECT.sql
UTF-8
1,111
3.921875
4
[]
no_license
use PACKT_ONLINE_SHOP; SELECT * FROM ProductCategories; -- use PACKT_ONLINE_SHOP; SELECT ProductCategoryID, ProductCategoryName FROM ProductCategories; --Apodar las columnas SELECT ProductCategoryName AS CATEGORY, ProductCategoryID AS ID FROM ProductCategories; -- Ordenar la consulta SELECT ProductCategoryNam...
true
3ebc2858b7cd6db4e194128af98cb941e81f88bb
SQL
dbeatty10/dbt-sqlite
/dbt/include/sqlite/macros/core_overrides.sql
UTF-8
443
2.640625
3
[ "LicenseRef-scancode-warranty-disclaimer", "Apache-2.0" ]
permissive
{% macro ref(model_name) %} {# override to strip off database, and return only schema.table #} {% set rel = builtins.ref(model_name) %} {% do return(rel.include(database=False)) %} {% endmacro %} {% macro source(source_name, model_name) %} {# override to strip off database, and return only schema.table #}...
true
427201271707af0104eb689a95b1297dd9aa1490
SQL
yesgosu/DataBase_hospital
/201412425_1113.sql
UTF-8
1,667
3.78125
4
[]
no_license
SELECT name,sum(saleprice) from customer, orders where customer.custid=orders.custid group by name order by name; alter table orders add foreign KEY(bookid) REFERENCES book(bookid); SELECT name,bookname,orderdate from customer cu,orders od, book bk where cu.custid=od.custid and od.bookid=bk.bookid and pr...
true
cd7e14ad0ad0fc10e6cfaf4fc9ad5a8b91f030f7
SQL
Tal-Four/SmartTimetable
/newdb.sql
UTF-8
21,265
3.0625
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 5.7.19-log - MySQL Community Server (GPL) -- Server OS: Win32 -- HeidiSQL Version: 9.3.0.4984 -- ---------------------------------------------------...
true
629b393ba9c776644a7f59f4b2cb2141d30932a1
SQL
hbopereira/Anp-Api
/src/main/resources/db/migration/V16__criar_e_registrar_grupo_subgrupo.sql
UTF-8
923
2.765625
3
[]
no_license
CREATE TABLE grupo ( id BIGINT(20) PRIMARY KEY AUTO_INCREMENT, nome VARCHAR(50) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8; INSERT INTO grupo (id, nome) VALUES(1, 'Acessorios'); INSERT INTO grupo (id, nome) VALUES(2, 'Bebidas'); INSERT INTO grupo (id, nome) VALUES(3, 'Lanches'); CREATE TABLE subgrupo ( id BIGI...
true
60d9eda8a52a9a5bffc6311c3c8d45ca493dde03
SQL
syn-RussellFord/SynProjects
/A3MySQL/MySql.sql
UTF-8
6,358
3.65625
4
[]
no_license
CREATE SCHEMA IF NOT EXISTS pcdb DEFAULT CHARACTER SET utf8; USE pcdb; /* ====== Create Tables ====== */ CREATE TABLE IF NOT EXISTS cond ( condID INT NOT NULL AUTO_INCREMENT, condName CHAR(20) NULL, PRIMARY KEY (condID) ); CREATE TABLE IF NOT EXISTS era ( eraID INT NOT NULL AUTO_INCREMENT, eraName CHAR(...
true
7fc9240eee072d2b86cf8721ca6bbf99e0c92d96
SQL
tetsu0329/morada
/payment/_transaction_withdata_tc_db.sql
UTF-8
5,310
3
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Nov 14, 2017 at 05:05 PM -- 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
725541b76107670abd7ca437f6f942ff83571162
SQL
imanelahrach/javaJbdc
/comptebanquedb.sql
UTF-8
293
2.734375
3
[]
no_license
create table compte ( id int auto_increment primary key, personne_id int default 0 not null, solde double null ); create table personne ( cin int auto_increment primary key, nom varchar(50) null, prenom varchar(50) null );
true
8148e2f19639079b052c884cc301a1697cb8e3fc
SQL
QPC-github/oss-analysis-census2-prototype
/load_runtime_counts.sql
UTF-8
528
3.59375
4
[ "CC-BY-4.0", "MIT", "CC-BY-3.0", "CC0-1.0" ]
permissive
DROP TABLE IF EXISTS runtime_counts; CREATE TABLE runtime_counts ( ID serial, dep_count int, dep_id int, dep_name text, platform text, PRIMARY KEY(id) ); CREATE INDEX ON runtime_counts (dep_count); CREATE INDEX ON runtime_counts (dep_id, dep_name); \copy runtime_counts(dep_count, dep_id, d...
true
b060a122f145e7c26eb9c630bae4954e2f73e230
SQL
FJiayang/VANTEN_for_Oracle
/Oracle.sql
GB18030
78,490
2.703125
3
[]
no_license
-------------------------------------------------------- -- ļѴ - ڶ-ʮ-19-2017 -------------------------------------------------------- -------------------------------------------------------- -- DDL for Table ADMINISTRATOR_JOB -------------------------------------------------------- CREATE TABLE "C##ROOT"."ADMIN...
true
ffe119756bc5c3cd27369e0afe4687e3d9f39f05
SQL
cgallego/getdata_getInfo
/testdatabase/SQLbiomatrix/test.sql
UTF-8
1,949
2.625
3
[]
no_license
SELECT tbl_pt_mri_cad_record.cad_pt_no_txt, tbl_pt_mri_cad_record.latest_mutation_status_int, tbl_pt_mri_cad_record.pt_id, tbl_pt_exam.exam_dt_datetime, tbl_pt_exam.a_number_txt, tbl_pt_exam.mri_cad_status_txt, tbl_pt_procedure.proc_dt_datetime, tbl_pt_procedure.proc_side_int, tbl_pt_procedu...
true
c71b6117a7c7ad0f8483ff8180e972b4ef85acde
SQL
ggjyp/CMSDemo
/src/main/resources/sql/cms.sql
UTF-8
939
3.25
3
[]
no_license
/* Source Host : localhost:3306 Source Database : cms */ -- ---------------------------- -- Table structure for user -- ---------------------------- create table user ( id int not null primary key auto_increment, username varchar(30) not null unique, password char(20) not null, status int not null ...
true
a01e87304345c50b2bcfd85928b4f4d7db8980e8
SQL
bravers/Ushimitsu
/lesson8/8_2.sql
UTF-8
1,709
2.921875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.6.6deb5 -- https://www.phpmyadmin.net/ -- -- Хост: localhost:3306 -- Время создания: Июл 18 2019 г., 05:34 -- Версия сервера: 5.7.26-0ubuntu0.18.04.1 -- Версия PHP: 7.2.19-0ubuntu0.18.04.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTE...
true
28df1a126d3bcae761ae1407ca045c19708c0eb4
SQL
oehrlis/oradba
/sql/tvd_hr/tvd_hr_popul.sql
UTF-8
12,124
2.953125
3
[ "Apache-2.0", "UPL-1.0" ]
permissive
-------------------------------------------------------------------------------- -- OraDBA - Oracle Database Infrastructur and Security, 5630 Muri, Switzerland -------------------------------------------------------------------------------- -- Name......: tvd_hr_popul.sql -- Author....: Stefan Oehrli (oes) stefan.oe...
true
68ebef9555662a1ff33455ebcb2f9e878d984e67
SQL
tronhammer/satanbarbara.com
/resources/db/mysql/sb.events.sql
UTF-8
1,725
3.375
3
[]
no_license
CREATE TABLE IF NOT EXISTS `satanbarbara`.`events` ( `id` INT(11) NOT NULL AUTO_INCREMENT, `created` TIMESTAMP NOT NULL DEFAULT NOW(), `creator_id` INT(11) NOT NULL, `type_id` INT(11) NOT NULL, `title` VARCHAR(255) NOT NULL, `subtitle` VARCHAR(255) NOT NULL DEFAULT "", `description` TEXT ...
true
9d9291216a3998ec4d2401eae62d0da1ed3c99bd
SQL
Joaquin6/vw-stripe
/common/libs/db/scripts/includePrivateLabelItems.sql
UTF-8
648
2.890625
3
[]
no_license
SELECT * FROM public.item WHERE (TYPE IN ('wheel', 'tire', 'accessory') AND specification ->> 'private_label_item' = '0') UNION SELECT * FROM public.item WHERE (TYPE IN ('wheel', 'tire', 'accessory') AND specification ->> 'private_label_item'...
true
4cb24428df751b022ce1245575e392af7285a015
SQL
tahmaz/c
/Components/components.sql
UTF-8
362
2.890625
3
[]
no_license
CREATE TABLE test.components( ID INT NOT NULL AUTO_INCREMENT, NAME VARCHAR(30), TYPE VARCHAR(20), COUNT smallint(15), LOCATION VARCHAR(20), LINK VARCHAR(200), DESCRIPTION mediumtext, PRIMARY KEY(ID) ); drop table components; TRUNCATE TABLE components; Insert into test.components(NAME,TYPE,COUNT) VALUES('2N5551S','T...
true
bda66f499443c93d05f6b0c09966705a09ab3d28
SQL
christopher-kwon/codetech
/src/main/resources/sql/table/user_report.sql
UTF-8
2,099
3.84375
4
[]
no_license
drop table user_report cascade constraints; create table user_report ( user_report_id number(6) primary key, report_subject varchar2(50) not null, report_content varchar2(200) not null, created_at date default sysdate, updated_at date default sysdate, report_status...
true
708b91b2da42d549af30bdf134574914d02ea262
SQL
minervaliste/Project-Week-2-Barcelona
/your-project/Queries_extract_tables_per_district_and_year.sql
UTF-8
1,124
3.953125
4
[]
no_license
USE p2_population; -- Immigrant age ranges per district and year (percentage) SELECT a.year, sub_q.district_name, a.age, ((sum(a.immigrants)/sub_q.total_immigrants)*100) AS immigrants_percentage FROM age AS a JOIN (SELECT a1.year, d.neig_code, d.district_name, sum(a1.immigrants) as total_immigrants FROM age AS a1 LEFT...
true
114c019865b3e3ee1bbda9022e6024723c1c3ba8
SQL
comeRodriguez/relational-databases-project
/VIEWS.sql
UTF-8
3,838
3.984375
4
[]
no_license
DROP VIEW IF EXISTS MauvaisEtat; DROP VIEW IF EXISTS LivresDispo; DROP VIEW IF EXISTS FilmsDispo; DROP VIEW IF EXISTS EnregistrementsDispo; DROP VIEW IF EXISTS EmpruntEnCours; DROP VIEW IF EXISTS LivresLesPlusEmpruntes; DROP VIEW IF EXISTS GrandsRetardataires; DROP VIEW IF EXISTS retard; /*Lors de notre passage au JSO...
true
b31e32862c542a867affb828d0e387b06429520e
SQL
RevaLipton/TEWork
/java-final-capstone-team-brewery-finder/final-capstone/back-end/java/database/beersBrewsBattlestarGalactica.sql
UTF-8
5,086
3.34375
3
[]
no_license
DROP TABLE IF EXISTS beers cascade; DROP TABLE IF EXISTS beerbrewery cascade; DROP TABLE IF EXISTS beertypes cascade; DROP TABLE IF EXISTS beertyperelator cascade; DROP TABLE IF EXISTS reviews cascade; DROP TABLE IF EXISTS beersreviews cascade; DROP TABLE IF EXISTS usersbreweries cascade; DROP TABLE IF EXISTS breweries...
true
37ed8fe169522f409ce2bd293f6cd94de2d542de
SQL
3omar3allam/Movies-Database-Model
/script.sql
UTF-8
5,774
3.546875
4
[]
no_license
-- MySQL Script generated by MySQL Workbench -- Mon 10 Dec 2018 04:19:52 PM EET -- 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
bf67bbec4ebc758ceeeba72266fb404024d4d15b
SQL
knuber/hc_comp
/SQL/DB2/DB2 for i/FFSBGLR1_GJ.sql
UTF-8
6,309
3.390625
3
[]
no_license
CREATE OR REPLACE PROCEDURE RLARP.SB_GJ_R1 ( IN vPERD VARCHAR(4) ) DYNAMIC RESULT SETS 1 LANGUAGE SQL SPECIFIC RLARP.SB_GJ_R1 NOT DETERMINISTIC MODIFIES SQL DATA CALLED ON NULL INPUT SET OPTION ALWBLK = *ALLREAD , ALWCPYDTA = *OPTIMIZE , COMMIT = *NONE , DECRESULT = (31, 31, 00) , DFTRDBCOL = *N...
true
5801da24d58676e3fb8c437302ad0911e6b5346d
SQL
arnielcasile/todolist
/todolist.sql
UTF-8
4,326
3.203125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 25, 2021 at 09:53 AM -- Server version: 10.4.17-MariaDB -- PHP Version: 7.3.25 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
ce0ba90dcda07a4524d25f9d5cf7718c5d0ab8f9
SQL
tncrazvan/php_socket_io
/utils/database/dump/glorep_shared.sql
UTF-8
16,301
3.171875
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Versione server: 10.1.33-MariaDB - mariadb.org binary distribution -- S.O. server: Win32 -- HeidiSQL Versione: 9.5.0.5196 -- ------------------------------------------------...
true
1a6238466bb45688dd047df001226e2e922d5c20
SQL
khidji/finalproject
/database/create_db.sql
UTF-8
1,947
3.5
4
[]
no_license
USE `finalproject`; CREATE TABLE `users` ( `pseudo` VARCHAR(60) UNIQUE NOT NULL PRIMARY KEY, `first_name` VARCHAR(60) NOT NULL, `last_name` VARCHAR(100) NOT NULL, `phone` VARCHAR(10) NOT NULL, `address` VARCHAR(255) NOT NULL, `city` VARCHAR(100) NOT NULL, `country` VARCHAR(70) NOT NULL, `postal_code` VARCHAR(...
true
02cd63ce42b71230db7fffba9a48b0a84ef1b94f
SQL
bourn404/foundation-framework
/sql/db-setup.sql
UTF-8
2,947
3.703125
4
[]
no_license
drop table if exists perms cascade; create table perms ( id serial not null primary key ,category varchar(60) ,slug varchar(255) not null unique ,name varchar(60) not null ,description TEXT ,parent int references perms(id) on delete cascade ); insert into perms (category, slug, name, description) values ('Administrat...
true
2b0809dfde3cd2335956644220a3fa96cb36c9d0
SQL
Esteban131197/Proyecto-3_D2
/restapi/mysql/db.sql
UTF-8
410
2.875
3
[]
no_license
CREATE DATABASE IF NOT EXISTS Got ; USE Got; CREATE TABLE usuarios ( id INT (11) NOT NULL AUTO_INCREMENT, name VARCHAR(45) DEFAULT NULL, repositorio VARCHAR(45) DEFAULT NULL, commitdescripcion VARCHAR(45) DEFAULT NULL, visualizaciondocumento longblob, PRIMARY KEY(id) ); SELECT * FROM usuar...
true
9e7174f36189c74385bba188dca32277c507c7aa
SQL
ashminbhandari/resource_mgmt
/src/main/resources/initializeDB.sql
UTF-8
3,756
3.59375
4
[]
no_license
CREATE DATABASE IF NOT EXISTS `resource_mgmt`; USE `resource_mgmt`; SET FOREIGN_KEY_CHECKS = 0; DROP TABLE IF EXISTS `resource`; SET FOREIGN_KEY_CHECKS = 1; CREATE TABLE `resource` ( `resource_id` int NOT NULL AUTO_INCREMENT, `resource_name` TEXT, `resource_code` int, PRIMARY KEY (`resource_id`) ) E...
true
5c5a7f505faab28728f9769110bcaa3ec34a183b
SQL
kprzekwas/project_bd
/init_tables.sql
UTF-8
3,529
3.765625
4
[]
no_license
use kprzekwas CREATE TABLE pojazd ( id_pojazdu int IDENTITY(1,1) PRIMARY KEY, id_modelu int, id_rodzaju int, id_koloru int, rok_produkcji int, nr_vin varchar(25) UNIQUE not null, przebieg BIGINT not null, data_przyjecia date not null, cena MONEY not null, ) CREATE TABLE marki ( id_marki int IDENTITY(1,1) ...
true
e9ab84a8566d9d6c33cf2c38b800209bec09401f
SQL
tavo1981/phpbar
/libs/scripts/concursospub.sql
UTF-8
2,321
3.375
3
[]
no_license
----------------------------------------------------- ----- Tabela concursos_publicos --------------------- ----------------------------------------------------- create table concursos_publicos ( con_id serial not null primary key, con_nome varchar(75) not null, con_edital varchar not null, con_valor decim...
true
671da0cc2d499e08392ccdf419e4be3546a311b1
SQL
SAKET1102/SQL_Interview_Query
/Nth_Highest_Salary.sql
UTF-8
1,813
4.4375
4
[]
no_license
create Database students; use students; CREATE TABLE sales ( employee VARCHAR(50), "date" DATE, sale INT ); INSERT INTO sales VALUES ('odin', '2017-03-01', 200), ('odin', '2017-04-01', 300), ('odin', '2017-05-01', 400), ('thor', ...
true
354e839b4d02e9a1fa6c28e745c16369d26b8280
SQL
saratonite/PDO_Tuts
/src/SQL_Files/users.sql
UTF-8
1,992
2.84375
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 3.5.2.2 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: May 19, 2014 at 06:10 PM -- Server version: 5.5.27 -- PHP Version: 5.4.7 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /...
true
8745e3d0de8a5326762e99b7183b745773388d92
SQL
sid77320/Projet_Immo
/database/immo.sql
UTF-8
8,192
3.015625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.4.12 -- http://www.phpmyadmin.net -- -- Client : 127.0.0.1 -- Généré le : Mar 08 Décembre 2015 à 16:15 -- Version du serveur : 5.6.25 -- Version de PHP : 5.6.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER...
true
81afa9d6fdb8ba201d7be0b56296840de146847a
SQL
WiduriComputerCommunity/workshop-2018-extensions
/wcc_workshop_2018.sql
UTF-8
1,104
2.875
3
[ "MIT" ]
permissive
-- Adminer 4.7.5 MySQL dump SET NAMES utf8; SET time_zone = '+00:00'; SET foreign_key_checks = 0; SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO'; DROP TABLE IF EXISTS `pengajar`; CREATE TABLE `pengajar` ( `id` int(11) NOT NULL AUTO_INCREMENT, `nama` varchar(30) NOT NULL, `email` varchar(30) NOT NULL, `no_hp` varchar(...
true
9bb5b4ed613409dc490c053a37c625fac285c23e
SQL
andrewp-as-is/sqlite-examples
/SQL/UPDATE/WHERE EXISTS.sql
UTF-8
351
3.421875
3
[ "Unlicense" ]
permissive
CREATE TABLE t1 (id TEXT PRIMARY KEY,value TEXT); CREATE TABLE t2 (id TEXT PRIMARY KEY,value TEXT); INSERT INTO t1 VALUES (1,'value1'), (2,'value2'); INSERT INTO t2 VALUES (1,'new_value1'), (2,'new_value2'); UPDATE t1 SET value = (SELECT t2.value FROM t2 WHERE t2.id = t1.id ) WHERE EXISTS (SELECT * FROM t2 WHERE t2.i...
true
65b3fd27a8b13819e9a8f32f9834a464d6ce9c87
SQL
UCLALibrary/sql-scripts
/ArchivistsToolkit/Haynes Finding Aid AT-35.sql
UTF-8
5,389
4.21875
4
[]
no_license
create view AT35_Report as -- Top level resource data, with extra fields to allow unions with lower-level component data with level0 as ( select r.resourceId , null as resourceComponentId , null as parentResourceComponentId , r.title , r.dateExpression , r.resourceLevel , 0 as sequenceNumber , r.resourceident...
true
54a581f6de2fbfd453b6a38d5a94cccf615d94fe
SQL
panne027/CSCI5715
/Lab/lab3/Part A, B, _ C/lab3_partB.sql
UTF-8
1,778
4.09375
4
[]
no_license
/* CSCI 5715 Fall 2020 */ /* Lab 3 11/16/2020 */ /* Group 1: Matthew Eagon Harish Panneer Selvam */ /*---------------------------------------------------------------------------*/ /* Output Options */ set echo on set trimspool on set pagesize 24 set linesize 100 /* Part B: Recursi...
true
248e58b6f752b5c0983915639d50900f7b8c7de1
SQL
g1165713/cellfish-lite
/config/schema.sql
UTF-8
704
3.25
3
[]
no_license
CREATE TABLE messages ( id TEXT PRIMARY KEY, name TEXT, email TEXT, subject TEXT, message TEXT, created_at INTEGER ); CREATE TABLE users ( username TEXT PRIMARY KEY, password TEXT ); CREATE TABLE images ( hash TEXT PRIMARY KEY, dataurl TEXT ); CREATE TABLE posts ( id TEXT...
true
0a77642fe47a0636bc8ebf7b2df95504eb0e4599
SQL
lai3d/Oracle_PLSQL_Learning
/SQL_for_Beginners_07_the-group-by-clause-and-having-clause.sql
UTF-8
5,251
3.71875
4
[]
no_license
-- https://oracle-base.com/articles/misc/sql-for-beginners-the-group-by-clause-and-having-clause -------------------------------------- GROUP BY Clause ------------------------------------------ SELECT COUNT(*) AS employee_count, AVG(e.salary) AS avg_salary, SUM(e.salary) AS sum_salary FROM employees ...
true
62ed232e2cfd893029560aeedf8171014933125f
SQL
Zakinator123/Gear-Tracker
/database-migrations/sql/V0__baseline_schema_migration.sql
UTF-8
4,350
3.28125
3
[ "MIT" ]
permissive
-- MySQL dump 10.13 Distrib 5.7.23, for Linux (x86_64) -- -- Host: mysql Database: inventory -- ------------------------------------------------------ -- Server version 5.7.23 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40...
true
8bf7934f60932c2a5d334075e68b8751392cbf01
SQL
NicolasRomeroF/TareaDBD
/consultas.sql
UTF-8
2,666
4.0625
4
[]
no_license
--CONSULTA 1 SELECT ars.id_sello, count(*) FROM artista_sello ars, artista a, generos_artista ga, genero g WHERE ars.id_artista = a.id_artista AND ars.fecha_termino > '01-01-2017' AND ga.id_genero = g.id_genero AND ga.id_artista = a.id_artista AND g.nombre = 'Indie' GROUP BY ars.id_sello; --CONSULTA 2 DROP VIEW IF E...
true
954e18f164c4ac8e77bf90c384575e472fb619cb
SQL
magrai/URBAN-MV-VIE_UniBw_Study2_DB
/v_q_pasa_t1_vs_t2.sql
UTF-8
1,280
3.1875
3
[]
no_license
DROP VIEW IF EXISTS v_q_pasa_t1_vs_t2 CASCADE; CREATE VIEW v_q_pasa_t1_vs_t2 AS SELECT "public".v_condfinder.subid, "public".v_condfinder.cond, "public".v_q_pasa_t1_scores.pasa_threat as pasa_threat_t1, "public".v_q_pasa_t2_scores.pasa_threat as pasa_threat_t2, "public".v_q_pasa_t1_scores.pasa_challenge as pasa_challe...
true
8561809b04f2379117992f3db9d4afada7e51407
SQL
fazalul92/crowd-requirements
/src/main/resources/insert_static_data.sql
UTF-8
4,694
3.5
4
[]
no_license
/*insert into spotcheck_question(name, question, options, options_type, answer) values ('which_not_sns', 'Which of the following is not a social network site?', 'Facebook,Google Plus,Windows,Twitter', 'radio', 'Windows'), ('which_not_browser', 'Which of the following is not a Web browser?', 'PowerPoint,Chrome,Inter...
true
70055708ba796ec869f5a94cf8fad2bdee15caf1
SQL
shaneconn860/sql-fpl
/joins.sql
UTF-8
161
2.90625
3
[]
no_license
#Basicjoin select a.player_name, a.team, b.assists from player_basics a inner join player_stats b on a.player_name = b.player_name where position = 'Defender';
true
8a0ade61b752f0774b920379dfb6b5f318e9f384
SQL
kiosowski/Database
/Projects/DatabaseBasics/BuiltInFunctions/BuiltInFunction/3.sql
UTF-8
109
2.78125
3
[]
no_license
SELECT FirstName FROM Employees WHERE DepartmentID IN(3,10) AND DATEPART(YEAR,HireDate) BETWEEN 1995 AND 2005
true
c9bdef00d50908c59491e0f48bbaa0cc1abf2f6e
SQL
jsheridanwells/chinook-sql-practice
/top_agent.sql
UTF-8
372
3.875
4
[]
no_license
-- Which sales agent made the most in sales over all? SELECT FirstName, LastName, MAX(TotalSales) FROM ( SELECT Employee.FirstName AS FirstName, Employee.LastName AS LastName, SUM (Invoice.Total) AS TotalSales FROM Employee JOIN Customer ON Customer.SupportRepId = Employee.EmployeeId JOIN Invoice ON Customer.CustomerId...
true
a587441255804d370d393e5bb989e8a6fc2881b9
SQL
hernan-alperin/urbix
/trilenium/2015-1er-cuat.sql
UTF-8
2,285
3.609375
4
[]
no_license
create or replace function dia_semana(date) returns text as' select case extract(dow from $1) when 1 then ''Lunes'' when 2 then ''Martes'' when 3 then ''Miercoles'' when 4 then ''Jueves'' when 5 then ''Viernes'' when 6 then ''Sabado'' e...
true
c545faa5be7dcc2b0b9297368bb7884c07c56053
SQL
kalkanli/321_1
/q8.sql
UTF-8
748
4.625
5
[]
no_license
SELECT team.team_id, team.short_name, team.full_name, ROUND(SUM(CAST(track.clim AS float)*track.total_laps/1000), 3) AS total_driven FROM Teams team, Drivers driver, Tracks track WHERE ((track.lap_recorder=team.driver_one AND driver.driver_id=team.driver_one AND driver.country_of_birth<>"England") OR (track.lap...
true
f882d8592e8776bbb21d63b19e7e4d4862692849
SQL
rkammer/production-sql
/views/location_type_get_list.sql
UTF-8
940
3.359375
3
[]
no_license
CREATE OR REPLACE VIEW location_type_get_list( location_type_id, location_type_name, location_type_created, location_type_created_by, location_type_updated, location_type_updated_by, location_type_status ) AS SELECT location_type.id AS location_ty...
true
80760a4c07f27297da079e2fca2a57fa50bc88b5
SQL
paramorel/propet-backend
/resources/db/migration/V1_1__create_animal_type_table.sql
UTF-8
180
2.546875
3
[]
no_license
CREATE TABLE "Animal Type" ( "type_id" serial NOT NULL, "type_name" VARCHAR(30) NOT NULL, CONSTRAINT "Animal Type_pk" PRIMARY KEY ("type_id") ) WITH ( OIDS=FALSE );
true
7651b7f94bec9126df38e58dd4a8495a3f0c294d
SQL
microcomet/readcore
/backend/doc/sql_operate.sql
UTF-8
608
3.21875
3
[ "MIT" ]
permissive
# 创建数据库 create database if not exists clean_read_toggle character set utf8 collate utf8_general_ci; # 将某一数据库上的所有权限都赋给某一用户 grant all on clean_read_toggle.* to 'cleaner'@'%'; # 查询当前数据库支持的所有character set和配套对应字符集的默认collate(排序规则) # show charset; create database if not exists clean_read character set utf8 collate utf8_gen...
true