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
1bd7fa84a980a812440386cf0bb538e76349c983
SQL
tabby336/CoLiW
/Before/CoLiW_create.sql
UTF-8
1,388
3.625
4
[]
no_license
-- tables -- Table Auth CREATE TABLE Auth ( oauth_provider varchar(255) NOT NULL, Username_username varchar(32) NOT NULL, oauth_token text NOT NULL, oauth_secret text NOT NULL, CONSTRAINT Auth_pk PRIMARY KEY (oauth_provider,Username_username) ); -- Table History CREATE TABLE History ( Usern...
true
6a782162638dfaeec4e95b727655cc38d4c959ca
SQL
NYPL-Simplified/circulation
/core/migration/20171208-add-lane-size.sql
UTF-8
255
3.203125
3
[ "Apache-2.0" ]
permissive
DO $$ BEGIN BEGIN ALTER TABLE lanes ADD COLUMN size integer not null default 0; EXCEPTION WHEN duplicate_column THEN RAISE NOTICE 'column lanes.size already exists, not creating it.'; END; END $$;
true
e31f17843735c2e6bf6648392c731aa914569227
SQL
DpadamsX/DpadamsX
/views/api/before_clearout/analytic_sterilizer_load_domo.sql
UTF-8
10,168
3.140625
3
[]
no_license
DROP VIEW IF EXISTS api.analytic_sterilizer_load_domo; CREATE VIEW api.analytic_sterilizer_load_domo AS WITH expanded_data AS ( SELECT hsys.name_ AS "HsysName", facility.name_ ...
true
3c363d9360dddba24066f35508439958d602359b
SQL
carbon8/Sportscar-Standings
/App_Data/Install/SQL Folder/Objects/Newsletter_OpenedEmail.sql
UTF-8
967
3.53125
4
[]
no_license
CREATE TABLE [Newsletter_OpenedEmail] ( [SubscriberID] [int] NOT NULL, [IssueID] [int] NOT NULL, [OpenedWhen] [datetime] NULL ) ALTER TABLE [Newsletter_OpenedEmail] ADD CONSTRAINT [PK__Newsletter_OpenedEmail] PRIMARY KEY CLUSTERED ([SubscriberID], [IssueID]) ALTER TABLE [New...
true
074372c83eccfd39b5e2109921cbf6bec8f7e866
SQL
151115/test_01
/team_test_01/WebContent/sql.sql
UHC
525
2.65625
3
[]
no_license
// ~ create table Review_test_01 ( memberId varchar(10) not null, memberPw varchar(10) not null, review_text varchar(500) not null ) drop table Review_test_01 create table member_test_01 ( memberId varchar(10) primary key , memberPw varchar(10) not null ) insert into member_test_01 ...
true
ff6b7b1eab572bde947591811ce7d71a5582d4ba
SQL
quguoxin/all_study
/mysql/mysql_demo/MySQL题目基础数据.sql
UTF-8
18,711
3.15625
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : localhost_wampserver Source Server Version : 50520 Source Host : localhost:3306 Source Database : mystudentdb Target Server Type : MYSQL Target Server Version : 50520 File Encoding : 65001 Date: 2016-08-17 00:43:14 */ SET FOREIGN_KEY_...
true
d9e2878e01f69e4edaf8690ad63ed4d1ccb55927
SQL
Vasil-Hadzhiev/CSharp-DB-Fundamentals
/Databases Basics - MS SQL Server/Exams/Exam - 19.02.2017/Bakery/Bakery/09. Negative Feedback.sql
UTF-8
225
3.515625
4
[]
no_license
SELECT f.ProductId, f.Rate, f.Description, f.CustomerId, c.Age, c.Gender FROM Feedbacks AS f INNER JOIN Customers AS c ON c.Id = f.CustomerId WHERE f.Rate < 5 ORDER BY f.ProductId DESC, f.Rate
true
2ef4c31ac8f6c66fe80a98ce129f8ad848dd8c10
SQL
apinSoftware/extrationtool
/sqlQueries/LAB Script BETA latests.sql
UTF-8
28,745
3.671875
4
[]
no_license
@where SELECT pid1.identifier AS pepid, DATE(encounter.encounter_datetime) AS visitdate, "Viral Load" AS "tests", ob.value_numeric AS "results", DATE(MAX(IF(obs.concept_id= 162078, obs.value_datetime, NULL))) AS `orderdate` , DATE(MAX(IF(obs.concept_id= 165414, obs.value_datetime, NULL))) AS `re...
true
cffda0ba0ff6c98c8c302a0694ad9b0164947f7c
SQL
onlyten/weimei
/sql数据/weimei_warn.sql
UTF-8
1,491
2.671875
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : serv2 Source Server Version : 50148 Source Host : qdm102668679.my3w.com:3306 Source Database : qdm102668679_db Target Server Type : MYSQL Target Server Version : 50148 File Encoding : 65001 Date: 2016-01-20 10:32:39 */ SET FOREIGN_KEY...
true
6f2829667990172aa91c938b72e262cd01521e08
SQL
Polina-MD80/JavaDB
/TableReations/TableRelationsLab.sql
UTF-8
1,421
4.3125
4
[]
no_license
#1 CREATE SCHEMA `mountains_andPeaks`; USE mountains_andPeaks; CREATE TABLE `mountains` ( `id` INT NOT NULL AUTO_INCREMENT, `name` VARCHAR(45) NOT NULL, PRIMARY KEY (`id`) ); CREATE TABLE `peaks` ( `id` INT PRIMARY KEY NOT NULL AUTO_INCREMENT, `name` VARCHAR(45) NOT NULL, `mountain_id` INT NOT...
true
fc8fca7c4b7cfdbdb8033226c1e55e261de83bd1
SQL
StefanosMichalacos/quiz-app
/src/main/resources/queries/user_queries/query_select_users_by_role.sql
UTF-8
108
2.65625
3
[]
no_license
select * from "user" inner join "user_role" on "user".id = "user_role".id where "value" = 'ADMINISTRATOR';
true
57d180d234073309b6145c7fe1effe61d68cd393
SQL
FaithMandela/QuestionThree
/projects/chama/database/old/33.data.defaults.sql
UTF-8
2,825
3.390625
3
[]
no_license
--- Data INSERT INTO currency (currency_id, currency_name, currency_symbol) VALUES (5, 'US Dollar', 'USD'); INSERT INTO orgs (org_id, org_name, org_sufix, currency_id, logo) VALUES (1, 'Default', 'df', 5, 'logo.png'); UPDATE currency SET org_id = 1 WHERE currency_id = 5; SELECT pg_catalog.setval('orgs_org_id_seq', 1,...
true
d11da79aa7cd430a0de7c75bcfa29f1ac612c309
SQL
OHDSI/Vocabulary-v5.0
/SOPT/manual_work/specific_qa/manual_checks_after_generic.sql
UTF-8
340
3.546875
4
[ "Unlicense" ]
permissive
--01 check names correctness/consistency SELECT s.concept_code, c.concept_name as old_name, s.concept_name as new_name, devv5.similarity (c.concept_name, s.concept_name) FROM sources.sopt_source s JOIN concept c ON c.concept_code = s.concept_code AND c.vocabulary_id = 'SOPT' WHERE devv5.similarity (c.concept_name, s.c...
true
c2083b08fd549f2a21c1065f63105a7c551f0bc8
SQL
IndustrialMojo/OTTR
/src/main/db/scripts/ntt_tables/002.CREATE_NTT_NAME_TABLE.sql
UTF-8
768
2.984375
3
[]
no_license
DROP TABLE IF EXISTS ebdb.NTT_NAME; CREATE TABLE ebdb.NTT_NAME ( ID INT UNSIGNED NOT NULL UNIQUE AUTO_INCREMENT, FIRST VARCHAR(45) CHARACTER SET 'utf8' COLLATE 'utf8_general_ci' NOT NULL, MIDDLE VARCHAR(45) CHARACTER SET 'utf8' COLLATE 'utf8_general_ci' DEFAULT '', LAST VARCHAR(45) CHARACTER SET 'utf8' COLLATE 'utf...
true
1dc2d2f4714aa001b34fc38e6111446c7e3b569a
SQL
clint317/micom
/updates/V5to6update/MS-SQL Scripts/3_renamekeys_indexes.sql
UTF-8
14,879
2.65625
3
[]
no_license
-- These statements will add some additional defaults to the columns already in the store -- These SQL statements will drop all the old foreign keys and update with new keys as needed and with a standard naming protocol -- It also renames the primary keys to the new naming protocol -- These are the constraint names...
true
169717e1dd5187100f0bc9cfafdea8cfba963a84
SQL
gKStGt/DB_work
/05_SQL_SELECT_stocks/05_6d_que_avg.sql
UTF-8
785
3.828125
4
[]
no_license
/* Aggregationen AVG() */ use stocks; system clear: -- Durchschnittspreis einer Aktie / Banken ?? /* SELECT AVG(price) "Durchschnittspreis" FROM stocks.ccc_list WHERE industry = "Banks" LIMIT 20; */ -- KOMBINATION Preis/ Dividenden SELECT DISTINCT sector AS "Industriesektor", ROUND (AVG(price),2) AS "D...
true
8be23629a23c7e2cf7a645d0ac9e08e9e48eda24
SQL
moyses-oliveira/mysql-functions
/fnGeoLocationRadius.sql
UTF-8
503
3.390625
3
[]
no_license
# Get Geolocation Radius based on latitude / longitude pints (using Km metric) DELIMITER $$ CREATE FUNCTION `fnGeoLocationRadius`( x1 DECIMAL(13,7), y1 DECIMAL(13,7), x2 DECIMAL(13,7), y2 DECIMAL(13,7) ) RETURNS decimal(10,2) BEGIN DECLARE c DECIMAL(13, 12); DECLARE z DECIMAL(13, 6); RETURN ...
true
2c4b24679b4221fe97a4bca90b021a31e10f7a59
SQL
ViniciusOkaeda/Banco-de-Dados
/A01/DQL2.sql
ISO-8859-1
1,250
3.984375
4
[]
no_license
/*Na linha de comando abaixo ir acontecer a seleo da entidade(tabela) Usuario e ir acontecer um filtro para aparecer somente as informaes do IdUsuario 1*/ SELECT * FROM Usuario WHERE IdUsuario = 1; /*Na linha de comando abaixo ir acontecer a seleo da entidade(tabela) Usuario e ir acontecer um filtro ordenado para apa...
true
5eb0ae045fd42ad31c4f5a9ac0404036e8efea33
SQL
Josue0619/Tarea-3
/Tarea#3/js/MySql-Typescript-app/sql/database.sql
UTF-8
565
2.90625
3
[]
no_license
create database estudiantes; create table DatosEstudiantes() { id int(12) NOT NULL AUTO_INCREMENT PRIMARY KEY; nombre VARCHAR(300) NOT NULL, carrera VARCHAR(300) NOT NULL, } create table Materias() { id int(12) NOT NULL AUTO_INCREMENT PRIMARY KEY; nombre VARCHAR(300) NOT NULL, } creat...
true
11c0f02933400d1049cf8596f492831f3eb3e014
SQL
kyleruss/cablecity-db
/triggers/ProductIdentity.sql
UTF-8
438
2.859375
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
----------------------------------- -- Name: Kyle Russell -- ID: 13831056 -- Physical database design ----------------------------------- -- Creates an identity/AI trigger for Product CREATE OR REPLACE TRIGGER ProductIdentityTR BEFORE INSERT ON Product FOR EACH ROW DECLARE next_id Product.Prod_id%TYPE; BEGIN SELEC...
true
b3e8b4e5c8c13c26920998feda4a08e4f12576f5
SQL
virajkulkarni14/sqlscripts
/searchtext.sql
UTF-8
329
3.5
4
[]
no_license
-- Search for Text Inside All the SQL Procedures -- You have 20-30 sql procedures in your database and you need to find the procedure that contains a certain word. SELECT DISTINCT o.name AS Object_Name,o.type_desc FROM sys.sql_modules m INNER JOIN sys.objects o ON m.object_id=o.object_id WHERE m.definition Like '%searc...
true
c78f69a1b78b20db95cd338d3416d1cc268b4e34
SQL
vccolombo/URI-SQL-solutions
/solutions/3001.sql
UTF-8
157
2.96875
3
[]
no_license
SELECT name, CAST(CASE type WHEN 'A' THEN 20.0 WHEN 'B' THEN 70 WHEN 'C' THEN 530.5 END AS DECIMAL(10, 1)) AS price FROM products ORDER BY type, id DESC;
true
eef7414f973a88ed9bef0645919d307b35179fae
SQL
green-fox-academy/Jirinka
/week-12/Databases/src/main/java/com/example/databases/commands.sql
UTF-8
188
3.4375
3
[]
no_license
USE movies; select title FROM movie WHERE director LIKE 'Steven Spielberg'; SELECT DISTINCT year FROM movie INNER JOIN rating ON movie.mID = rating.mID WHERE stars > 3 ORDER BY year;
true
0cc3d368a919cfbfdd4ee1700c8eddc32bc74096
SQL
Leocadio94/PrjSGV
/sql/Antigo/bd_vac_teste.sql
UTF-8
12,359
3.34375
3
[]
no_license
CREATE SCHEMA IF NOT EXISTS vacinacao; CREATE SEQUENCE vacinacao.dm_dependence_type_id_dependence_type_seq_1; CREATE TABLE vacinacao.dm_dependence_type ( id_dependence_type INTEGER NOT NULL DEFAULT nextval('vacinacao.dm_dependence_type_id_dependence_type_seq_1'), description VARCHAR N...
true
818d8061def16727881c95bc93369ce26696115c
SQL
Kexin-Tang/Student_Info_Sys
/SQL/stu_info_sys_question.sql
UTF-8
3,341
2.84375
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.20, for Win64 (x86_64) -- -- Host: localhost Database: stu_info_sys -- ------------------------------------------------------ -- Server version 8.0.20 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */...
true
7fa914caa93263ac6299262b88fa0454d29ee1fe
SQL
NadineKammermann/DigitalData
/Homework5/problem_4.sql
UTF-8
704
3.609375
4
[]
no_license
DROP DATABASE IF EXISTS problem_4; CREATE DATABASE problem_4; USE problem_4; CREATE TABLE submitted_articles ( id INTEGER NOT NULL PRIMARY KEY AUTO_INCREMENT, title VARCHAR(200) NOT NULL, publication BOOLEAN NOT NULL, issue DATE ); CREATE TABLE people ( id INTEGER NOT NULL PRIMARY KEY AUTO_INCREMENT, name VARCHA...
true
1262247194642c7d013ec253399462cfff6007af
SQL
felipemoz/oracle-toolkit
/find_command_type.sql
UTF-8
1,643
3.859375
4
[]
no_license
SET VERIFY OFF ACCEPT pBegin PROMPT "Type begin date (ddmmyyyy)[01012016]: " ACCEPT pEnd PROMPT "Type end date (ddmmyyyy)[SYSDATE]:" ACCEPT pTableName PROMPT "Type table_name LIKE:" SELECT DISTINCT DECODE(c.command_type,1,'CREATE TABLE' ,2,'INSERT' ...
true
526afde4a648440debd00b8193c42e8489a8c493
SQL
svetlanakryukova/SQL-local-database-Transport
/Project_DB.sql
UTF-8
9,337
3.25
3
[]
no_license
--Project Data Bases. Kryukova Svetlana --PART I/ create tables and put data to insert : --1. table City: create table city (city_id number(3) constraint Pk_city_id primary key,city_name varchar2(20)); --2. table Pilot: create table pilot (pilot_id number(3) constraint pilot_id_pk primary key, last_name ...
true
66dd6a44c0121566ddbd1c4decc5c36e74a77ccb
SQL
pgcristian/ostocket
/install/sql/upgrade_stock.sql
UTF-8
16,592
3.390625
3
[]
no_license
SET SQL_SAFE_UPDATES=0$ CREATE TABLE IF NOT EXISTS `%TABLE_PREFIX%Stock_ticket_recurring` ( `id` int(11) NOT NULL AUTO_INCREMENT, `Stock_id` int(11) NOT NULL, `last_opened` datetime DEFAULT NULL, `next_date` datetime DEFAULT NULL, `interval` double NOT NULL, `ticket_id` int(11) NOT NULL, `active` tinyint...
true
12b64b0a80fec3aefe258c2991c81a79a337dcce
SQL
vikram-raj/SocialCalulator
/passportparking.sql
UTF-8
1,397
2.65625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.5.2.2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Apr 19, 2014 at 10:38 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
dba8042e4c081200a7f8d415ee91649bccc8ecc8
SQL
saminb/Real-Estate-Management-System
/Bahizad_Samin_Queries.sql
UTF-8
568
3.234375
3
[]
no_license
SELECT * FROM Properties; SELECT * FROM Agents; SELECT * FROM Price; INSERT INTO Properties " + "VALUES(?,?,?,?,?,?,?,?,?,?,?); DELETE FROM Properties WHERE Property_ID =?; UPDATE properties SET Square_feet=?,Property_TypeID=?,Property_StatusID=?, Year_Built=?, Price_ID=?,Property_Addr=?, bedrooms=?,bathrooms=?,Lo...
true
6c600506f9b52cd80eab03ca80a99ecd2e0a317c
SQL
avaz7791/SanDiegoCountyPotholeAnalysis
/resources/database/ddl/pothole_cy.sql
UTF-8
738
2.859375
3
[]
no_license
-- Table: public.pothole_cy DROP TABLE if exists public.pothole_cy; CREATE TABLE public.pothole_cy ( "yearRequest" integer, "monthRequest" character varying(10) COLLATE pg_catalog."default", "dateRequest" date, "yearClosed" integer, "monthClosed" character varying(10) COLLATE pg_catalog."default",...
true
2aef7c6abade76b39294d185ce803c0a9f8b81b5
SQL
radtek/Database-3
/oracle/admin/scripts/db_link_dbms_sys_sql.parse_as_user.sql
UTF-8
540
2.515625
3
[]
no_license
declare uid number; pass varchar(50) := '05BE3869C7C6812D21BAE482717B98242B'; host varchar(50) := 'CDWDEV'; sqltext varchar2(1000) :='CREATE DATABASE LINK "CORDW.DCS.CITICORP.COM" CONNECT TO "EXT$CO_AML" IDENTIFIED BY VALUES '''||pass||''' USING '''||host||''''; myint integer; begin select user_id into uid f...
true
1f4358390b10771199db1d34465af2f32559e619
SQL
tracywang359943/learn
/sql/learn-shop.sql
UTF-8
37,551
2.71875
3
[ "Apache-2.0" ]
permissive
/* Navicat Premium Data Transfer Source Server : 119.23.27.78 Source Server Type : MySQL Source Server Version : 80011 Source Host : 119.23.27.78:3306 Source Schema : learn Target Server Type : MySQL Target Server Version : 80011 File Encoding : 65001 Date: 03/08/201...
true
e76d2422e045f774886ecc5863fee932cac2c351
SQL
DumitriuAdelina/Fmi-DB
/lab9/lab6 2-11.sql
UTF-8
5,214
4
4
[]
no_license
--lab 6 --2 select * from project -- avem toate proiectele where project_id in ( select project_id from works_on -- selectam toate proiectele la care au lucrat angajatii, unde angajatul e printre cei cu alte 2 posturi in firma where employee_id in ...
true
1417ff26656d23bbf63dc76e4329637314a64929
SQL
alec-patterson/revature_repository
/test.sql
UTF-8
4,251
3.8125
4
[]
no_license
--select * from customer_accounts ca; --select * from customer_bank_information cbi ; --select * from customer_personal_information cpi ; --select * from login_information li ; --delete from "BankingSystem".customer_personal_information where account_id = 11; --delete from "BankingSystem".customer_bank_information whe...
true
13a6c71c741e20f3009d1730c13a4c632b82e003
SQL
sanju1098/CyberCafe
/ccmsdb.sql
UTF-8
7,559
2.890625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 23, 2019 at 04:51 PM -- Server version: 10.1.36-MariaDB -- PHP Version: 5.6.38 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
61cfca36efb95b7f7c9d4f0fe6895d648ccf8ec3
SQL
ShannenGrimes/bamazon
/schema.sql
UTF-8
1,793
3.234375
3
[]
no_license
DROP DATABASE IF EXISTS bamazon_db; -- creates the database CREATE database bamazon_db; USE bamazon_db; -- creates the products table CREATE TABLE products ( itemid INTEGER AUTO_INCREMENT NOT NULL, productname VARCHAR(45) NULL, departmentname VARCHAR(45) NULL, price DECIMAL(10,2) NULL, stockquantity INT NUL...
true
3c2886019a829250b4aaa4e92f1dce5ce514a597
SQL
chaesiong/rtp-database
/production/PIBICSDM2/procedures/p_fs_feesdetail.prc
UTF-8
4,781
3.4375
3
[]
no_license
CREATE OR REPLACE EDITIONABLE PROCEDURE "PIBICSDM2"."P_FS_FEESDETAIL" IS v_dstart VARCHAR2 (15); v_dend VARCHAR2 (15); var_rows NUMBER; vstdate DATE; veddate DATE; BEGIN /* Create date : 27-01-2018 */ --No.2 v_dstart := TO_CHAR (TRUNC (SYSDATE) - 1, 'yyyymmdd'); ...
true
d2672a54e0676236d616ceac055ec0d50eafd107
SQL
cbarca/VectorH-sigmod2016
/impala/queries/q6.sql
UTF-8
198
2.9375
3
[]
no_license
select sum(l_extendedprice * l_discount) as revenue from lineitem where l_shipdate >= '1995-01-01' and l_shipdate < '1996-01-01' and l_discount between 0.01 and 0.03 and l_quantity < 24
true
58bedcbd8572276f5df15d1af881ab27eda5dfc1
SQL
fwu313/garuda
/etc/garuda.sql
UTF-8
3,331
2.609375
3
[ "BSD-2-Clause" ]
permissive
-- MySQL dump 8.22 -- -- Host: localhost Database: garuda --------------------------------------------------------- -- Server version 3.23.54 -- -- Table structure for table 'detect' -- CREATE TABLE detect ( did int(11) NOT NULL auto_increment, first_seen datetime default '0000-00-00 00:00:00', hostname varc...
true
70d908c74d32c9c271555e06b1e5a342f8784425
SQL
djmcgill/dominions-5-status
/src/db/sql/insert_server_player.sql
UTF-8
188
2.96875
3
[ "MIT" ]
permissive
INSERT INTO server_players (server_id, player_id, nation_id, custom_nation_name) SELECT g.id, p.id, ?1, ?2 FROM game_servers g JOIN players p ON p.discord_user_id = ?3 WHERE g.alias = ?4;
true
35c577edc79411a1c95d92363e8c7032954d7e98
SQL
lucita287/matic-as02
/base_datos/DDL/TablasScript.sql
UTF-8
1,542
3.40625
3
[]
no_license
CREATE TABLE MATIC_CLIENTE ( USUARIO varchar(50) NOT NULL, NOMBRE varchar(150) NOT NULL, APELLIDO varchar(150) NOT NULL, PASSWORD varchar(30) DEFAULT NULL, EMAIL varchar(90) NOT NULL, PRIMARY KEY (USUARIO) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; / CREATE TABLE MATIC_CUENTA( USUARIO varchar(50) NOT...
true
17af3a69880c3c6b275a3e535af1c14a91a161de
SQL
Sargatanas/ember-gvk
/public/resources/db/ember_gvk_select_1.sql
UTF-8
463
3.828125
4
[]
no_license
SELECT 'ул. ' || addresses.street || ', д. ' || addresses.house|| ', корп. ' || addresses.build || ', эт. ' || addresses.floor|| ', кв. ' || addresses.flat AS "Адрес", COUNT(requests.task) AS "Количество вызовов" FROM public.addresses JOIN public.requests ON requests.address=addresses.id GROUP BY addresses.street,...
true
9aedf31972521bd15e62deb81f8951babae97a9f
SQL
GeorgiBarbutov/SoftUni
/C#ProfessionalModules/C#DBFundamentals/C#DatabaseBasics/Exercises/DataDefinitionAndDatatypes-Exercise/13.MoviesDatabase.sql
UTF-8
1,413
3.703125
4
[]
no_license
CREATE TABLE Directors ( Id INT PRIMARY KEY IDENTITY, [Name] NVARCHAR(50) NOT NULL, Notes NVARCHAR(MAX) ) INSERT INTO Directors VALUES ('Director1', NULL), ('Director2', 'Hello there'), ('Director3', NULL), ('Director4', NULL), ('Director5', NULL) CREATE TABLE Genres ( Id INT PRIMARY KEY IDENTITY, [Name] NVARCH...
true
f6c49c9500098aba1f335cf8c68a14bd660c0dfe
SQL
OpenDRR/model-factory
/scripts/psra_6a2.eqri_calculation_hexgrid_1km_uc.sql
UTF-8
11,978
3.265625
3
[ "MIT" ]
permissive
-- script to test new PSRA calculation -- hg 1km level -- calculate social fabric hg 1km uc aggregation DROP TABLE IF EXISTS results_psra_national.psra_sri_social_fabric_score_hg_1km_uc CASCADE; CREATE TABLE results_psra_national.psra_sri_social_fabric_score_hg_1km_uc AS ( SELECT b.gridid_1, AVG("SVlt_Score" * b.area_...
true
1bc88cc0767775cba41390aeb75ec56355d49050
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/low/day21/select1331.sql
UTF-8
191
2.78125
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerObservation WHERE timestamp>'2017-11-20T13:31:00Z' AND timestamp<'2017-11-21T13:31:00Z' AND SENSOR_ID='bd242f0f_ddce_4256_bacc_3a208b4d1dd3'
true
8385f31d5ccc232678fb7c93cfdf3b07484204f7
SQL
ducclv/Quizlet
/quizletbackend/quizlet db.sql
UTF-8
4,331
3.265625
3
[]
no_license
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 10.4.13-MariaDB - mariadb.org binary distribution -- Server OS: Win64 -- HeidiSQL Version: 10.1.0.5464 -- -----------------------------------------------...
true
78e1778315fc4d4f5a3c67ac976a2658ec8dc013
SQL
Eric-programming/MySQLTutorial
/SQL_Tutorial/7-MySQL (Unique Constraint).sql
UTF-8
597
3.671875
4
[]
no_license
#Unique Constraint is used when we want to prevent duplicate data in a given field CREATE TABLE customers( customer_id INT NOT NULL PRIMARY KEY AUTO_INCREMENT, customer_email VARCHAR(255) NOT NULL UNIQUE, customer_name VARCHAR(255) NOT NULL ); INSERT INTO customers (customer_email, customer_name) VALUES ("...
true
a909e759f1f9cdeaae15f7f4cbcc90300495ee14
SQL
petrlevin/rostu
/Sbor/Scripts/4620.sql
UTF-8
1,911
2.65625
3
[]
no_license
IF EXISTS (SELECT * FROM dbo.sysobjects WHERE name = 'DEFAULT_StateProgramGoalIndicatorValue_byApproved' AND type = 'D') BEGIN ALTER TABLE [rep].[StateProgramGoalIndicatorValue] DROP CONSTRAINT [DEFAULT_StateProgramGoalIndicatorValue_byApproved] END; IF EXISTS (SELECT * FROM dbo.sysobjects WHERE name = 'DEFAULT_Sta...
true
426282196dc9a825ad8a17b33c59653ed07507b3
SQL
JcGaara/SGA-PLSQL-OPE
/SGA-OPERACION/Procedures/PROMOCIONES_DTH_AUTOMATICO.SQL
UTF-8
2,144
3.15625
3
[]
no_license
create or replace procedure operacion.PROMOCIONES_DTH_AUTOMATICO IS /*Proceso de alineacion promociones*/ v_fecha_inicio_vigencia date; v_idpromocion number; v_dias_vigencia_bouquet number; v_control number; cursor x is select a.* from v_fac_aplicacion_promocion_rep a where a.idcupon ...
true
bc75d60af59e753e5a6e9539d531e7f43f67c707
SQL
shju0317/Biz_506_2020_DBMS
/오라클/USER1(2020-07-17-SELECT).sql
UTF-8
11,775
4.3125
4
[]
no_license
-- 여기는 user1화면입니다. ------------------------------------------------------------------------------- -- [ PROJECTION, SELECTION ] ------------------------------------------------------------------------------- -- DB공학에서 논리적인 차원의 DB관련용어 -- 실무에서는 별로 사용하지 않는 단어이기도 하다. SELECT * FROM tbl_dept; -- [ PROJECTION ] SELECT d_co...
true
21d2ea56c7f5586a02f8d36e3b8f3e12c57d0e86
SQL
okumurakengo/redux-task-manager
/ddl/trigger_task_tbl.sql
UTF-8
177
2.796875
3
[]
no_license
CREATE TRIGGER IF NOT EXISTS task_tbl_updated AFTER UPDATE on task_tbl BEGIN UPDATE task_tbl SET updated = DATETIME('now','+9 hours') WHERE task_id = old.task_id; END;
true
fda7187a4be7e4cceb81bdc4620b15e6feb26c11
SQL
ltbird259/SQL-challenge
/EmployeeSQL/createTables.sql
UTF-8
736
3.609375
4
[]
no_license
create table departments ( dept_no varchar(20), dept_name varchar(30), constraint departmentKey PRIMARY KEY (dept_no) ) create table dept_emp ( emp_no int, dept_no varchar(20), from_date date, to_date date, constraint emp_no foreign key (emp_no) references (employees.emp_no) ) create table dept_manager ( d...
true
0bd31dc7a84ca9b05fa901be8db63119b4b1626b
SQL
AlexCD7/BASE-DE-DATOS-VISTAS-RECURSIVIDAD-TRIGGERS-OPERACIONES-
/recursividad.sql
UTF-8
663
3.3125
3
[]
no_license
CREATE TABLE mundo( id Serial PRIMARY KEY, detalle text NOT NULL, padre int ); ALTER TABLE mundo ADD FOREIGN KEY (padre) REFERENCES mundo(id); INSERT INTO mundo(detalle) VALUES ('America' ); INSERT INTO mundo(detalle) VALUES ('Asia' ); INSERT INTO mundo(detalle) VALUES ('Europa' ); INSERT ...
true
238aee7422f885ebcca64223d050ab661ef7ad6f
SQL
noelladsa/birds
/db_ops/deploy_sql/taxonomy.sql
UTF-8
535
3.1875
3
[]
no_license
CREATE TABLE taxonomy( SCI_NAME text UNIQUE, TAXON_ORDER text, PRIMARY_COM_NAME text UNIQUE, CATEGORY text, ORDER_NAME text, FAMILY_NAME text, SUBFAMILY_NAME text, GENUS_NAME text, SPECIES_NAME text ); ALTER TABLE taxonomy ADD IMG_FILE text; create materialized view birds_with_data_...
true
b0467d8496115bb4e57eef8d3d85ee9a37049db0
SQL
zeidalidiez/notefulAPI2
/seeds/seed.noteful.sql
UTF-8
713
2.796875
3
[]
no_license
TRUNCATE noteful_folders, noteful_notes RESTART IDENTITY CASCADE; INSERT INTO noteful_folders (id, foldername) VALUES ( 1, 'Super' ), ( 2, 'Spangley' ), ( 3, 'Important' ); INSERT INTO noteful_notes (id, notename, modified, folderid, co...
true
5de3c4991af421fd3a0a958a189b9615bf8d8838
SQL
HaoJun0823/Civ6Fate-Iskandar
/Fate Zero - Iskandar/Iskandar_Governors.sql
UTF-8
4,443
3
3
[]
no_license
-- Iskandar_Governors -- Author: HaoJun0823 -- DateCreated: 2019/2/15 15:58:17 -------------------------------------------------------------- CREATE TABLE "FateIskandarGovernorPromotionModifiers" ( "GovernorPromotionType" TEXT NOT NULL, "ModifierId" TEXT NOT NULL, PRIMARY KEY(GovernorPromotionType, ModifierId), ...
true
5de72b26d764a7326b0f941652e5f11cd1290dc4
SQL
Stratio/cassandra-lucene-index
/doc/resources/test-users-create.cql
UTF-8
6,934
3.5625
4
[ "Apache-2.0" ]
permissive
-- Create keyspace CREATE KEYSPACE IF NOT EXISTS test WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor': 1 }; USE test; -- Create table CREATE TABLE IF NOT EXISTS test.users ( name varchar, gender varchar, animal varchar, age int, food varchar, latitude float, long...
true
f7de2ecd7598f9e7baa189e9ea4d1128c88bd85b
SQL
plsql/oracledba.net
/website/05-materials/OracleByExamplesSeries/bidw/partition/files/create_hist_newsales.sql
UTF-8
1,404
3.171875
3
[]
no_license
set echo off REM RUDIMENTARY PARTITIONING OBE REM REM v0.1 REM REM mwiel 10/18/06 - initial creation REM hbaer 02/07/07 - first adjustments and extensions REM REM REM REM set pagesize 2000 set long 10000 set linesize 200 set feedback on column partition_name format a25 column high_value format a85 REM REM Interval Part...
true
78d58d20ebb0bb2ec69b69d292dc98d143422687
SQL
John-Ryan-Johnson/Chinook
/Chinook/top_3_artists.sql
UTF-8
354
4.0625
4
[]
no_license
--26. Provide a query that shows the top 3 best selling artists. SELECT TOP(3) Artist.Name, COUNT(*) AS [Tracks Sold] FROM InvoiceLine JOIN Track ON InvoiceLine.TrackId = Track.TrackId JOIN Album ON Album.AlbumId = Track.AlbumId JOIN Artist ON Album.ArtistId = Artist.ArtistId GROUP BY Artist.N...
true
95badd62ed7a5a16b6c05e3e8e81359f176bf6b8
SQL
jarviscanada/jarvis_data_eng_BrejvinderDhillon
/linux_sql/sql/ddl.sql
UTF-8
900
3.40625
3
[]
no_license
--Switch to host_agent database assuming it has already been created \c host_agent; --Create the following tables if they don't already exist CREATE TABLE IF NOT EXISTS PUBLIC.host_info ( id SERIAL NOT NULL PRIMARY KEY, hostname VARCHAR NOT NULL UNIQUE, cpu_number SMALLINT NOT N...
true
a45c7827b72a15e615ee095510cb79319a64338a
SQL
MariusCodeAcademy/books-mysql-async-type1
/src/db/moviesGenres.sql
UTF-8
2,935
3.09375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.7 -- https://www.phpmyadmin.net/ -- -- Host: localhost:8889 -- Generation Time: Oct 04, 2021 at 07:39 AM -- Server version: 5.7.32 -- PHP Version: 7.4.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Database: `sql` -- -- -------------------------------...
true
5b731052365ea0634b969789a51a3729e89eb6dd
SQL
MusienkoYuriy97/test-project
/src/main/resources/db/migration/postgres/V2_1_0__Form.sql
UTF-8
263
3.125
3
[]
no_license
CREATE TABLE IF NOT EXISTS form( uuid UUID DEFAULT gen_random_uuid(), user_name VARCHAR (20) NOT NULL, category_uuid UUID NOT NULL, agree_to_terms BOOLEAN, PRIMARY KEY (uuid), FOREIGN KEY (category_uuid) REFERENCES category(uuid));
true
59a853a7ee4aaa3c9c5644b456b6ea37506b9353
SQL
sshillyer/poli-race-2016
/sql/polirace.sql
UTF-8
3,992
3.78125
4
[]
no_license
-- TODO: -- * Indices where needed -- -------------------------------------------------------------------------------------------------- -- Create the tables for the database -- -------------------------------------------------------------------------------------------------- -- See list of states at wikipeida.org...
true
b2cc30af6a1d92d7a9155e73a3816acef1b5e9dd
SQL
fkfkfk9/HYUNDAI
/2017/oracle/10_26/inlineview_sub_query.sql
UTF-8
848
4.125
4
[]
no_license
------------------------------------ 인라인 뷰 ---------------------------------- --from절에 사용하는 서브쿼리를 인라인 뷰 라고한다. -- 인라인뷰 select c.st_code, c.st_name, d.dep_code, d.DEP_NAME--학점이 4.2보다 큰행의 학생정보 from classes c, department d, ( select round(avg(c2.st_grade),1) as avg_grade from department d2, classes c2--연관없는 서...
true
ba9161525a7a60c67e3c999318cc00755e6d5552
SQL
jgarzonext/plsql-testing
/script_plsql/bd_iaxis/script/tables/SGT_SUBTABS.sql
ISO-8859-1
1,580
3.03125
3
[]
no_license
-------------------------------------------------------- -- DDL for Table SGT_SUBTABS -------------------------------------------------------- CREATE TABLE "AXIS"."SGT_SUBTABS" ( "CEMPRES" NUMBER(5,0), "CSUBTABLA" NUMBER(9,0), "FALTA" DATE, "FBAJA" DATE, "CUSUALT" VARCHAR2(32 BYTE), "FMODIFI" DATE, ...
true
dbc3c25bf93db169539008effecb24924d1be1b4
SQL
anik112/Experimental_Project_with_Oracle_-_Java
/HospitalManagement/database/hospital.sql
UTF-8
35,145
3.25
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Dec 08, 2022 at 06:28 AM -- Server version: 10.1.26-MariaDB -- PHP Version: 7.1.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
56ae9f1b83dddd96e5865786b7b6b95524eb7498
SQL
cjbj/db-sample-schemas
/sales_history/sh_hiera.sql
UTF-8
6,340
2.984375
3
[ "MIT" ]
permissive
Rem Rem $Header: sh_hiera.sql 02-feb-2007.11:50:58 gssmith Exp $ Rem Rem sh_hiera.sql Rem Rem Copyright (c) 2001, 2015, Oracle. All rights reserved. Rem Rem Permission is hereby granted, free of charge, to any person obtaining Rem a copy of this software and associated documentation files (the Rem "Software"), to de...
true
6d7f798712c5de18de7e1bb3f3f4739a01e82595
SQL
FreedomBitsTeam/alicization
/sql/lingvo/commands.sql
UTF-8
3,569
2.765625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.1.12 -- http://www.phpmyadmin.net -- -- Хост: 127.0.0.1 -- Время создания: Апр 02 2016 г., 15:25 -- Версия сервера: 5.6.16 -- Версия PHP: 5.5.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!4...
true
124f7197bf34260cb3aab25fd404b4457fe6a036
SQL
B-R-H/Particle-swarm-op
/services/mysql/create_tables.sql
UTF-8
637
3.171875
3
[]
no_license
CREATE TABLE run_state( flag VARCHAR(100), state BOOLEAN, PRIMARY KEY (flag) ); INSERT INTO run_state (flag,state) VALUES ('running particles',false); CREATE TABLE functions ( id INT, function VARCHAR(1000), PRIMARY KEY (id) ); INSERT INTO functions (id,function) VALUES (1,'Z = (5.*sin(X./10)+5*cos(Y./10)+5.*s...
true
aa1ad6a34519333d951a3cf541bf97996703e929
SQL
gldeleon/red
/scripts/convenios.sql
UTF-8
2,158
3.9375
4
[]
no_license
/*ACTUALIZA TABLA company*/ DELETE FROM kobemxco_red.company; INSERT INTO kobemxco_red.company( SELECT com.com_id, com.usr_id, com.com_name, com.com_rfc, CONCAT_WS(' ',a.calle,a.no_exterior,a.no_interior,z.zpc_colonia,CONCAT('C.P. ',LPAD(z.zpc_code,5,0)),z.zpc_local,s.stt_name) AS com_address, NULL AS com_tel, cct.c...
true
b823c4f8f8d2ea4a292e399f1369d6dcd966e18a
SQL
ArisKots1992/Applied-Databases
/assignment1/queries.sql
UTF-8
1,388
4.4375
4
[]
no_license
-- 1 ( 13422 ) select count(*) from ( select userID from Sellers UNION select userID from Bidders ) as users; -- 2 ( 103 rows ) select count(*) from Items where BINARY location = "New York"; -- 3 ( 8365 rows ) select count(*) from ( select itemID from ItemHasCategory group by itemID having count(*) = 4 ) as auctions;...
true
0334330ec0ba287425877a13de6f1617e935d157
SQL
lovechuck/leetcode
/src/00196.sql
UTF-8
232
3.859375
4
[]
no_license
delete a from Person a, (select min(Id), Email from Person group by Email having count(Email) > 1 order by id desc) b where a.Id <> b.Id and a.Email = b.Email delete a from Person a,Person b where a.Email = b.Email and a.Id > b.Id
true
44e66b2df95be97b78bbdb9ceb42024eb20e17db
SQL
AdamLJohnson/Amendment
/src/Amendment.Repository/Migrations/20230406030236_AddBodyAmendLangUniqueIndex.sql
UTF-8
834
3.03125
3
[]
no_license
START TRANSACTION; DO $EF$ BEGIN IF NOT EXISTS(SELECT 1 FROM "__EFMigrationsHistory" WHERE "MigrationId" = '20230406030236_AddBodyAmendLangUniqueIndex') THEN DROP INDEX "IX_AmendmentBody_AmendId_LanguageId"; END IF; END $EF$; DO $EF$ BEGIN IF NOT EXISTS(SELECT 1 FROM "__EFMigrationsHistory" WHERE "M...
true
bd9d5b516b9e737f48443b02b5a5b4597e78d2c2
SQL
alesancor1/IISSI-AutoescuelaTrafico
/core/sql/PruebasPaquetesVdef.sql
ISO-8859-1
52,131
3.015625
3
[ "MIT" ]
permissive
--PRUEBAS DE LOS PAQUETES SET SERVEROUTPUT ON; BEGIN /********************************************************************************************************* PRUEBAS DE LAS OPERACIONES SOBRE LA TABLA WEBTESTS ***************************************************************************************...
true
29920b6aa9f414a49d8c4dd21d14aa3603023354
SQL
Karaya-12/Database-System-Concepts
/Teach Yourself SQL in 10 Minutes 4th Edition/MySQL Files/L6 Using Wildcard Filtering.sql
UTF-8
659
3.5
4
[]
no_license
-- Using the LIKE Operator SELECT prod_id, prod_name FROM Products WHERE prod_name LIKE 'Fish%' -- Any Characters After The Word 'Fish' Will Be Retrieved SELECT prod_id, prod_name FROM Products WHERE prod_name LIKE '%bean bag%' -- Any Value That Contains The Text 'bean bag' Anywhere Within It Will Be Retrieved SELECT...
true
01f09a8b401f41a9a12cec6340cb8229abd6c66e
SQL
Bhaskers-Blu-Org1/FHIR
/fhir-persistence-schema/src/test/resources/set_tenant_unittest.sql
UTF-8
5,720
3.328125
3
[ "Apache-2.0" ]
permissive
------------------------------------------------------------------------------- -- (C) Copyright IBM Corp. 2020 -- -- SPDX-License-Identifier: Apache-2.0 ------------------------------------------------------------------------------- -- This file contains the unit tests for the set_tenant stored procedure. -- The unit...
true
b3c8a8a8817dabf87dc7d82802c19926edcda13f
SQL
bryanrafsanzani/Laravel-BasicAPI
/kolega.sql
UTF-8
1,304
2.890625
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 01 Agu 2019 pada 05.19 -- Versi server: 10.1.26-MariaDB -- Versi PHP: 7.2.15 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHAR...
true
2a260a3b60855f11a4693bb5ca3faaf834c5d01f
SQL
Communote/communote-server
/communote/persistence/src/main/resources/com/communote/server/liquibase/update/v2.2/KENMEI-4931_Thema einsehbar_obwohl_keine_Berechtigung_MySQL.sql
UTF-8
3,749
3.21875
3
[ "Apache-2.0" ]
permissive
-- Alte Daten loeschen DELETE FROM core_role2blog_granting_group; DELETE FROM core_role2blog WHERE granted_by_group = true; -- Daten in core_role2blog einfuegen INSERT INTO core_role2blog (blog_id, user_id, numeric_role, external_system_id, granted_by_group) SELECT DISTINCT core_blog_member.blog_...
true
35c334ea1a7b8924a5274330cf1f25e5447e4791
SQL
nguio/SIINCO_web
/FormasOracleForms/Repautw95/SQL/PLSINVNTCAD_CONUBICA.sql
UTF-8
1,327
3.234375
3
[]
no_license
SET TERMOUT ON set underline = col men heading '|||Generando Listado de SKUs sin Ventas en la cadena(&&1..csv)|Espere por favor|' format a100 select '....................................' men from dual / SET TERMOUT OFF SET SPACE 0 SET LINESIZE 300 SET PAGESIZE 3000 SET ECHO OFF SET FEEDBACK OFF SET VERIFY OFF SET UN...
true
bf19ed592a4ba86e94d94658f3619f0f596a3cc8
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day13/select2105.sql
UTF-8
269
3
3
[]
no_license
SELECT sen.name FROM SENSOR sen, SENSOR_TYPE st, COVERAGE_INFRASTRUCTURE ci WHERE sen.SENSOR_TYPE_ID=st.id AND st.name='Thermometer' AND sen.id=ci.SENSOR_ID AND ci.INFRASTRUCTURE_ID=ANY(array['2065','2076','3224','6036','6072','6213','3234','3214','4064','2100_2'])
true
eb574b5e6fc8aabe1627a1ca22206c731c9cd13c
SQL
a10h-bot/Spring-Boot-JPA-MySQL-CRUD-APP
/target/classes/database/book.sql
UTF-8
813
3.40625
3
[]
no_license
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; CREATE TABLE IF NOT EXISTS `book` ( `id` int(11) NOT NULL AUTO_INCREMENT, `author` varchar(255) DEFAULT NULL, `category` varchar(255) DEFAULT NULL, `name` varchar(255) DEFAULT NULL, `pages` int(11) DEFAULT NULL, `price` int(11) DEFAULT NULL,...
true
20d9033c9e25b4cb5ffbd604a0acaeef885fcf28
SQL
dblancoformacion/jairo_zapateria
/src/jairo_zapateria_sql.sql
ISO-8859-1
10,869
3.734375
4
[]
no_license
/* creacion de la base de datos */ DROP DATABASE IF EXISTS jairo_zapato; CREATE DATABASE jairo_zapato; USE jairo_zapato; CREATE TABLE articulos ( id_articulo int AUTO_INCREMENT, modelo varchar (255) NOT NULL, mat_interior varchar (255) NOT NULL, mat_exterior varchar (255) NOT NULL, precio float NOT NULL, t...
true
8263bccde79c40735017434cf9c2c59436bf2fcc
SQL
sheharyarikram/software-developer-coding-challenge
/src/main/resources/schema-h2.sql
UTF-8
641
3.3125
3
[]
no_license
CREATE TABLE users ( --id INTEGER AUTO_INCREMENT PRIMARY KEY, id INTEGER PRIMARY KEY, name VARCHAR(255) NOT NULL, licence_number VARCHAR(255) NOT NULL ); CREATE TABLE car ( id INTEGER PRIMARY KEY, model VARCHAR(255) NOT NULL, year INTEGER NOT NULL, plate_number VARCHAR(255)...
true
4107442a2674528b90a023abd92c6953c411b24a
SQL
IITDBGroup/maybms
/postgresql-8.3.3/src/test/regress/sql/maybms_combination.sql
UTF-8
2,021
3.671875
4
[ "PostgreSQL" ]
permissive
--test of combination of maybms constructs create table r(a int, b int); insert into r values(1,2), (1,3), (2,4); create table s as repair key a in r; select * from s; --output an error message for aconf without parameters select aconf() from s; --output an error message for esum and ecount without parameters selec...
true
51fb681e9a96f59b79e5d0a1cd56f5ad896d21fd
SQL
xuji1122/jdbc-partition
/test_cases_basic/schema/mysql/order/t_order_sku.ddl.sql
UTF-8
486
3.484375
3
[]
no_license
#订单商品表 DROP TABLE if EXISTS t_order_sku; CREATE TABLE t_order_sku ( id BIGINT PRIMARY KEY, order_id BIGINT NOT NULL, sku_stock_id BIGINT NOT NULL, buy_num INT NOT NULL DEFAULT 0, buy_price DECIMAL(17, 2) NOT NULL DEFAULT 0, create_dttm DATETIME NOT NULL DEFA...
true
4dbe2f8c12408332b314bc603d025868d41be185
SQL
aravindwithu/data-queries
/mySQL_queries/query18.sql
UTF-8
476
3.890625
4
[]
no_license
(SELECT st.sid, st.firstname, sum(cc.credits) as total_credit FROM students st JOIN enrollments en ON st.sid = en.sid JOIN classes cl ON cl.classid = en.classid JOIN courses cr ON cl.dept_code = cr.dept_code and cl.course# = cr.course# JOIN course_credit cc ON cr.course# = cc.course# WHERE en....
true
03eb16bf59d7d7e6ad79bc619c277359ffa2c4b5
SQL
ariel-alvear/modelamiento-bases-de-datos-postgresql
/caso_2.sql
UTF-8
2,739
3.6875
4
[]
no_license
CREATE DATABASE califications; CREATE TABLE class_groups_table( id SERIAL, class_name VARCHAR(30), PRIMARY KEY (id) ); CREATE TABLE teacher_departaments_table( id SERIAL, departament_name VARCHAR(40), PRIMARY KEY (id) ); CREATE TABLE teachers_table( id SERIAL, teacher_name VARCHAR(40)...
true
94ec975643859b0b6000899576dc7880984de9d1
SQL
dbacorp/aspen
/Scripts/BI_MDM/MDTR_MNSL/TB_DM_MOL.sql
UTF-8
265
2.515625
3
[]
no_license
DROP TABLE BI_MDM.TB_DM_MOL; CREATE TABLE BI_MDM.TB_DM_MOL ( SK_MOL VARCHAR2(10) PRIMARY KEY, DS_MOL VARCHAR2(250), DT_ULT_ATZ timestamp ); SELECT * FROM BI_MDM.TB_DM_MOL ORDER BY 1 ASC INSERT INTO BI_MDM.TB_DM_MOL VALUES ('0000000000','N/A',SYSDATE) COMMIT
true
61eacee60ebdcd6a215c4d9ee0b54688bbd927fb
SQL
freyxian/ecweb
/project/CigouAPI/zhuozhi-int/sql/zhuozhi-interface.sql
UTF-8
1,278
2.9375
3
[]
no_license
-- send order info to zhuozhi select * from wh_order_header -- update wh_order_header set orderDate='2016-4-11 12:34:00' -- update wh_order_header set customerId='suntech ???', warehouseId='CA-TO-6324', electriccode='suntech ??????' -- update wh_order_header set packingMaterial='barrel' -- update wh_order_header...
true
fed4cb5210e2d351f9155a3a8e3bd44d0190025b
SQL
fivetran-chloe/dbt_pardot_source
/models/stg_pardot__visitor.sql
UTF-8
854
3.265625
3
[]
no_license
with base as ( select * from {{ ref('stg_pardot__visitor_tmp') }} ), fields as ( select {{ fivetran_utils.fill_staging_columns( source_columns=adapter.get_columns_in_relation(ref('stg_pardot__visitor_tmp')), staging_columns=get_visitor_columns() ...
true
02864ed00c57ed70096a42a38c412203679cd389
SQL
panhachea/Time_list_staff
/Time_list/scedual.sql
UTF-8
6,361
3.09375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.6.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Aug 31, 2017 at 02:28 AM -- Server version: 5.7.14 -- PHP Version: 5.6.25 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */...
true
adef0cde3b4f7bd010ca93b1b0fb3e15acb963f3
SQL
MurrayCode/Cross-site-Scripting-against-PHP-Applications
/XSSApplication/App/phpapps/brim/plugins/bookmarks/sql/create.mysql.brim_bookmarks.sql
UTF-8
611
2.578125
3
[]
no_license
CREATE TABLE brim_bookmarks ( item_id int(11) NOT NULL auto_increment, owner varchar(70) NOT NULL default '', parent_id int(11) NOT NULL default '0', is_parent tinyint(1) default NULL, name text default NULL, description text, visibility varchar(10) default NULL, category varchar(50) default NULL, is_...
true
d6b353396ec385d7d054be30d328fe8c1faf39e3
SQL
msmet/EAA-SQL-Reports
/Academics/List of Enrollments for Credit Recovery.sql
UTF-8
1,991
3.84375
4
[]
no_license
SELECT s.dcid , sch.name , s.id , s.student_number , s.lastfirst , s.grade_level , sectA.termid , terA.abbreviation , cA.course_name , sectA.course_number||'.'||sectA.section_number , sectA.expression , cA.credittype , tA.lastfirst , LISTAGG(sectB.termid,', <br />') WITHIN GROUP (ORDER BY sg.dcid) , LIST...
true
a5b0dc0209b1027568185addc2090870c0d8d79b
SQL
FranzAndreas/Oracle_scripte
/Tanel/px.sql
UTF-8
554
3.3125
3
[]
no_license
COL px_qcsid HEAD QC_SID FOR A13 SELECT pxs.qcsid||','||pxs.qcserial# px_qcsid , ses.username , ses.sql_id , pxs.degree , pxs.req_degree , count(*) slaves FROM gv$px_session pxs , gv$session ses , gv$px_process p WHERE ses.sid = pxs.sid AND ses.serial# = pxs.serial# AND p.sid = p...
true
c101eb0fc30ddf809a13550ae69fe21927b736f4
SQL
sivaprasadraju/Todolist-Spring
/out/production/resources/db/migration/V1_1__create_todo.sql
UTF-8
335
3.109375
3
[]
no_license
create table todo( id int, done int, title VARCHAR(20) not null, priority VARCHAR(6) not null, PRIMARY KEY (id) ); insert into todo values (1, 0, 'Meeting', 'HIGH'), (2, 0, 'Meeting', 'MEDIUM'), (3, 0, 'Meeting', 'HIGH'), (4, 0, 'Meeting', 'LOW'), (5, 0, 'Meeting', 'HIGH'); sele...
true
674cb66ead15ec33c0bf012b374cd4322517bf38
SQL
podoynitsyn-va/GEEKBRAINS-Learning
/3.Learning_Databases_MySQL/course_project/course_project.sql
UTF-8
5,790
4
4
[]
no_license
DROP DATABASE IF EXISTS reservation; CREATE DATABASE IF NOT EXISTS reservation DEFAULT CHARSET utf8; USE reservation; -- -- Table structure for table users -- DROP TABLE IF EXISTS users; CREATE TABLE users ( idusers SERIAL PRIMARY KEY, login varchar(255) NOT NULL, pass varchar(255) NOT NULL, UNIQUE KEY logi...
true
5cfb7ee4ba6631cabc3058763ded910765d86ea8
SQL
chuttin/TW-front-end-homework
/spring/3/demo_web_JDBC/src/init.sql
UTF-8
236
2.609375
3
[]
no_license
CREATE TABLE `student` ( `id` int NOT NULL AUTO_INCREMENT, `name` varchar(15) DEFAULT NULL, `gender` int DEFAULT NULL, `classNumber` int DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8;
true
a31c3993e6ea18cc268d91adcf19f232c331f7cb
SQL
gprakarsh/Mistreee-official
/db/info/getPendingReq.sql
UTF-8
122
2.8125
3
[]
no_license
select name,number,address,item from timeslots t join users u on t.user_id = u.id where user_id = $1 and mech_id is null;
true