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
c99b4216603c6e93f28fba6a2d76b8aff9171739
SQL
Bernardita1980/curso68RoR
/SQL/Ejemplos.sql
UTF-8
339
3.25
3
[]
no_license
select * from faves; -- El * sirve para especificar todas las columnas select user_id, tweet_id from faves; -- La , es para separar select user_id, tweet_id from faves where user_id=1;-- seleccionar por valor del registro select * from faves where user_id=1 and tweet_id>=10;-- muestra todas las columnas con usuario1 y...
true
49ee5be97c12baf23a30aaae402e3ebbbc677a38
SQL
bikle/rluck
/svm4hp60min/svm2/cad_build_scorem.sql
UTF-8
450
2.734375
3
[]
no_license
-- -- cad_build_scorem.sql -- -- Builds a sql script to run a bunch of sql-scoring scripts. SELECT '@cad_score1day.sql ',ydate FROM cad_ms14 WHERE 'cad'||ydate NOT IN (SELECT prdate FROM fxscores) AND ydate > (SELECT MIN(ydate)+35 FROM cad_ms14) ORDER BY ydate / SELECT '@cad_score1day_gattn.sql ',ydate FROM cad_ms14...
true
cb766ce2b9d3a82daf206e94f50750fd0b5ad0ea
SQL
DarknessRdg/sistemas_escolar_em_bd
/usuarios e grupos/grupos.sql
UTF-8
991
2.671875
3
[]
no_license
create group diretor; create group professor; create group aluno; grant usage on schema public to group aluno; grant usage on schema public to group professor; -- diretor grant all on schema public to group diretor; grant all on aluno, aluno_turma, turma, professor, escola, disciplina,...
true
973c520aab7344f0ca448ac193c0ceb4b6f8e815
SQL
aminchev/IT-Tallents
/Java advance(collection&threads) and DB/3.SQL queries/Zaqvki 1/Dlujnost v koi otdel e.sql
UTF-8
156
3.4375
3
[]
no_license
select j.job_title, d.department_name from hr.jobs j join hr.employees e on(j.job_id = e.job_id) join hr.departments d on(e.department_id = d.department_id)
true
c27cc82afea39be0a908c092923ee415d5bdb2b1
SQL
radtek/abs3
/sql/mmfo/bars/Procedure/p_interest_cck2.sql
WINDOWS-1251
12,391
3.234375
3
[]
no_license
PROMPT ===================================================================================== PROMPT *** Run *** ========== Scripts /Sql/BARS/Procedure/P_INTEREST_CCK2.sql =========*** R PROMPT ===================================================================================== PROMPT *** Create procedure P_INTE...
true
99f8b50e5a3c1ae14fc3439141cb8612f517d7f1
SQL
Kush-Trivedi/MySQL-ALL-Aspects
/MySQL-All-Aspects.sql
UTF-8
14,136
4.1875
4
[]
no_license
-- First List the Databases show Databases; --------------------------------------------------------------------------------------------------------------- -- General command for creating a database: --------------------------------------------------------------------------------------------------------------- CREA...
true
c2da9330fff6f042a870fdfb51796a936ee04ce1
SQL
HaythServ/HaythServ
/script/base/auth/server/db/mysql_triggers.sql
UTF-8
138
2.671875
3
[]
no_license
CREATE TRIGGER `delete_domain_trigger` AFTER DELETE ON `domains` FOR EACH ROW BEGIN DELETE FROM users WHERE domain_id = OLD.id; END ~
true
ac53644f3a14ce1824e81f6f34887e14336d5308
SQL
SilviyaVasileva/SQL-HACKBG2020
/movies.sql
UTF-8
1,100
3.65625
4
[]
no_license
--1 SELECT address FROM STUDIO WHERE name="MGM"; --2 SELECT birthdate FROM MOVIESTAR WHERE name = "Kim Basinger"; --3 SELECT name FROM MOVIEEXEC where networth > 10000000; --4 SELECT name FROM MOVIESTAR WHERE gender = "M" or address = "Prefect Rd."; --5 INSERT into MOVIESTAR (name, address, gender, birthdate) VALUE...
true
1a1f09aff6a9c8c4f97cd06871d28815f090565c
SQL
austinfromboston/stasi
/spec/fixtures/preamp_test.sql
UTF-8
15,696
3
3
[]
no_license
-- MySQL dump 10.10 -- -- Host: localhost Database: preamp -- ------------------------------------------------------ -- Server version 5.0.27-standard-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION...
true
6bbe4a96720eae87e34670c8f808d4d609a8fbe7
SQL
satheeshkris/SQLScripts
/Important-Queries/Performance Troubleshooting/PT - Index Fragmentation.sql
UTF-8
773
4.34375
4
[]
no_license
--Query to check index fragmentation history ;WITH T_TableCounts AS ( select t.name TableName, i.rows Records from sysobjects t, sysindexes i where t.xtype = 'U' and i.id = t.id and i.indid in (0,1) ) ,T_Indexes AS ( SELECT OBJECT_NAME(ind.OBJECT_ID) AS TableName, ind.name AS IndexName, indexstats.index_type_desc...
true
32634b1a2b81f7dec2795f3dcbd594fc665d4417
SQL
kongyew/gpdb
/src/test/tinc/tincrepo/mpp/gpdb/tests/storage/filerep_end_to_end/sync2/sql/sync2_alter_tbl_add_column.sql
UTF-8
6,035
3.140625
3
[ "Apache-2.0", "LicenseRef-scancode-generic-cla", "PostgreSQL", "LicenseRef-scancode-other-copyleft", "metamail", "BSD-3-Clause", "LicenseRef-scancode-openssl", "LicenseRef-scancode-other-permissive", "ISC", "Python-2.0", "bzip2-1.0.6", "LicenseRef-scancode-ssleay-windows", "LicenseRef-scanco...
permissive
-- start_ignore SET gp_create_table_random_default_distribution=off; -- end_ignore -- -- HEAP TEST -- CREATE TABLE sync2_add_column_heap (col1 char DEFAULT 'z' ,col2 numeric DEFAULT 100 ,col3 boolean DEFAULT false, col4 character varying(512)[] DEFAULT '{one,two,three,four,five}', col5 timestamp with time zone DEFA...
true
d0f8d36625aa2aea08b57571530f50fd375e2d16
SQL
WladimirStoll/instandhaltung
/sicherungen/Produktion/Dump_20110812_1721/lager_halle.sql
UTF-8
2,774
3.09375
3
[]
no_license
CREATE DATABASE IF NOT EXISTS `lager` /*!40100 DEFAULT CHARACTER SET utf8 */; USE `lager`; -- MySQL dump 10.13 Distrib 5.5.9, for Win32 (x86) -- -- Host: localhost Database: lager -- ------------------------------------------------------ -- Server version 5.5.15 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CH...
true
5c86b4308954eb5c6fe21730178bb74090d08142
SQL
dataiti96/Rocket
/SQL/Testing_System_Assignment_2.sql
UTF-8
2,504
4.5
4
[]
no_license
-- Q1 SELECT * FROM department; -- Q2 SELECT DepartmentID FROM department WHERE DepartmentName = 'Sale'; -- Q3 SELECT * FROM `account` WHERE length(FullName) = (SELECT max(length(FullName)) FROM `account`); -- Q4 SELECT GroupName FROM `group` WHERE CreateDate < 2019-12-20; -- Q5 SELECT QuestionID FROM answer GROUP ...
true
09257e8f98dd53e986cb8f5e8a935c9156719934
SQL
benzebou/pfa-group2015
/Outil+Doc/BD/covoiturage.sql
UTF-8
4,905
3.1875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.2.11 -- http://www.phpmyadmin.net -- -- Client : 127.0.0.1 -- Généré le : Mer 11 Mars 2015 à 00:05 -- Version du serveur : 5.6.21 -- Version de PHP : 5.6.3 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_...
true
9d00b4932d851fc47269ef2b1b6a4b20d9f4de02
SQL
klk083/hapi
/src/Hapi/test-data.sql
UTF-8
3,532
2.875
3
[]
no_license
# noinspection SqlNoDataSourceInspectionForFile INSERT INTO role VALUES(DEFAULT, 'CEO'); INSERT INTO role VALUES(DEFAULT, 'Secretary'); INSERT INTO role VALUES(DEFAULT, 'Cook'); INSERT INTO role VALUES(DEFAULT, 'Driver'); INSERT INTO role VALUES(DEFAULT, 'Sales Representative'); INSERT INTO role VALUES(DEFAULT, 'Nutrit...
true
65081b94f070eaaa81584f69a73d00cd5dc0e7d2
SQL
HERCsMusicSystems/prolog
/code/prolog/main_course.prc
UTF-8
663
2.515625
3
[]
no_license
import studio program main_course [ light_meal main_course horse_duvre meat fish desert radishes pate beef pork sole tuna fruit icecream ] [[light_meal *energy *horse_duvre *main_course *desert] [horse_duvre *horse_duvre *hd_energy] [main_course *main_course *mc_energy] [desert *desert *des_ener...
true
c4e4b81fd1c6714b95fc3da67f18b235c5b9176d
SQL
JcGaara/SGA-PLSQL-OPE
/SGA-OPERACION/Procedures/P_VALORIZACION_AUTO_MO.sql
WINDOWS-1250
3,591
3.171875
3
[]
no_license
CREATE OR REPLACE PROCEDURE OPERACION.P_VALORIZACION_AUTO_MO is /* EMELENDEZ: 22/05/2008 Valorizacin automtica: Cuando el usuario pasa a estado Liquidado = 3 Se valorizan las actividades y materiales de la sot y pasa a estado Valorizado = 5 -- Solo para masivos solot.tipsrv in (58,59) 05/08/2008 Se quita por re...
true
8182c0c5bc26ef961711969f0a55927bc3260202
SQL
booit/php-examples
/tutorials/rest-api/infra/db/initdb.d/01-create-table.sql
UTF-8
335
2.890625
3
[]
no_license
CREATE TABLE `items` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(256) NOT NULL, `description` text NOT NULL, `price` int(255) NOT NULL, `category_id` int(11) NOT NULL, `created` datetime NOT NULL, `modified` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (id) ) ENGINE=MyISAM DEFAUL...
true
a299fa1fd7d398802379290bd70d200915d3f71d
SQL
phamdund97/quan-li-diem-sinh-vien
/hto.sql
UTF-8
6,122
3.265625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Jun 16, 2019 at 10:15 AM -- Server version: 10.1.38-MariaDB -- PHP Version: 7.2.16 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
8e40ab7f6c5fe999bea87972df0a46278dbc1ef6
SQL
Akram-abdl/b2_ProjetInfra
/scripts/templates/sql/common.sql
UTF-8
12,567
2.8125
3
[ "CC0-1.0" ]
permissive
/* Navicat Premium Data Transfer Source Server : Nuriki_test_server Source Server Type : MySQL Source Server Version : 80021 Source Host : localhost:3306 Source Schema : common Target Server Type : MySQL Target Server Version : 80021 File Encoding : 65001 ...
true
b89ce6650caef9cc7895dbbdad37405643fdbbbc
SQL
radtek/abs3
/sql/mmfo/bars/Data/tts/et_dma.sql
WINDOWS-1251
14,459
2.53125
3
[]
no_license
set lines 1000 set trimspool on set serveroutput on size 1000000 prompt / !DJ prompt : !DJ . declare cnt_ number; begin -------------------------------- -- -- -------------------------------- begin insert into tts(tt, name, dk, nlsm, kv, nlsk, kvk, nlss, nlsa, nlsb, mfob, flc, fli, ...
true
627042913d58591a793a95152e1b5d95f85620fa
SQL
maulananursan/tugas_weekend_ramen
/tugas_weekend_ramen.sql
UTF-8
597
3.453125
3
[]
no_license
CREATE DATABASE tugas_weekend USE tugas_weekend CREATE TABLE ramen ( review INT(4) PRIMARY KEY, brand VARCHAR(100), variety VARCHAR(100), style VARCHAR(50), country VARCHAR(100), stars DECIMAL(3,2), top_ten VARCHAR(10) ); LOAD DATA INFILE 'D:/Diklat_BKPSDM/Materi_Database/tugas_weekend/ramen-ratings.csv'...
true
cb15ba96ccd656861b50f26df453f8a4c167cacb
SQL
bikerstevewebdev/BLIFE
/db/add_client_message.sql
UTF-8
233
2.625
3
[]
no_license
INSERT INTO messages (client_id, coach_id, date_sent, content, sender, ROOM_NAME, sender_id) VALUES ($1, $2, $3, $4, $5, $6, $7); SELECT m.*, u.profile_pic FROM messages m JOIN users u ON u.username = m.sender WHERE m.client_id = $1;
true
e04ebb167f8054b473e6abda99188fa685b2ebcf
SQL
BeaRRRRR/MyNotebook
/Database Script/createAndFill.sql
UTF-8
3,038
2.9375
3
[ "MIT" ]
permissive
DROP DATABASE IF EXISTS test; CREATE DATABASE test; USE test; DROP TABLE IF EXISTS note; CREATE TABLE note( id INT NOT NULL AUTO_INCREMENT, message VARCHAR(255) NOT NULL, note_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, is_done BOOLEAN NOT NULL DEFAULT false, PRIMARY KEY(id) ); INSERT INTO Note(mess...
true
0120c9685ada4b500b4f25abf88459884f767f37
SQL
Samiys/Dynamic-Web-Project-PHP
/dynamic.sql
UTF-8
2,721
3.3125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: May 05, 2021 at 08:16 PM -- Server version: 10.4.13-MariaDB -- PHP Version: 7.4.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIEN...
true
a0d9196f7761d1a96774db8b9c56253645366c18
SQL
bill-zhuang/goutte_crawler
/data/aigou.sql
UTF-8
1,766
2.921875
3
[ "Apache-2.0" ]
permissive
/* Navicat MySQL Data Transfer Source Server : localhost Source Server Version : 50522 Source Host : localhost:3306 Source Database : crawl Target Server Type : MYSQL Target Server Version : 50522 File Encoding : 65001 Date: 2014-12-22 18:19:56 */ SET FOREIGN_KEY_CHECKS=0; -- ---...
true
cf1da380396f2b56a3a7a9e66b610de454ece61c
SQL
gloaec/oracle-ecommerce
/servers/ecommerce.secure/sql/migrate.sql
UTF-8
11,930
3.296875
3
[]
no_license
-- ------------------------------- -- TABLES -- ------------------------------- DROP TABLE IF EXISTS products; DROP TABLE IF EXISTS taxons; DROP TABLE IF EXISTS users; DROP TABLE IF EXISTS orders; DROP TABLE IF EXISTS variants; DROP TABLE IF EXISTS payments; DROP TABLE IF EXISTS payments_methods; DROP TABLE IF EXISTS...
true
2dd5198a8a17d8a0224dd402bfb01432702d69cc
SQL
DoubleWebb/report_money_receive
/database/workio_receive.sql
UTF-8
16,136
3
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 19, 2020 at 01:06 PM -- Server version: 10.4.14-MariaDB -- PHP Version: 7.4.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
11184a1ef0c4ee31204b74ccbded5770fc0e33cb
SQL
andrearaq/practica-ajax-datatables
/base_datos/crear_vista_doctores.sql
UTF-8
862
3.734375
4
[]
no_license
/*orden para crear la vista de doctores*/ create view vdoctores as select a.id_doctor, a.nombre, a.numcolegiado, group_concat(b.nombre) as clinica from doctores as a, clinicas as b, clinica_doctor as c where a.id_doctor = c.id_doctor and b.id_clinica = c.id_clinica group by a.nombre order by a.nombre; create view `vd...
true
db4864cec96f952d87f65a453d66cbbd555eb511
SQL
commi235/apex-plugin-clockpicker
/source/render_item.sql
UTF-8
6,948
2.859375
3
[ "MIT" ]
permissive
/*------------------------------------- * ClockPicker Functions * Version: 1.7.0 (22.12.2016) * Author: Daniel Hochleitner * * Changes: * 22.11.2017 Moritz Klein: Change to new interface and enable for interactive Grid *------------------------------------- */ PROCEDURE render_clockpicker(p_item in ...
true
399fcd937607e898409f2089f7b3c3de48a25fb0
SQL
bellmit/dbSmellsData
/data/open-source/extracted_sql/SpontaneousCMS_spontaneous.sql
UTF-8
5,175
3.171875
3
[ "MIT" ]
permissive
SELECT * FROM content WHERE ((type_sid IN ('MockContent2', 'MockContent3')) AND (content.source_id = 8)) SELECT * FROM content WHERE ((type_sid IN ('MockContent2', 'MockContent3')) AND (content.parent_id = 7)) SELECT * FROM __r00023_content WHERE ((hidden IS FALSE) AND (type_sid IN ('MockContent2', 'MockContent3')) AND...
true
a7bbdacab6f2421ac387711b11bdc5242af2aed7
SQL
ak47wyh/online-gateway
/online-gateway-webapp/src/main/resources/sql/T_EB_FrontEnd.sql
UTF-8
410
2.84375
3
[]
no_license
--drop table T_EB_FrontEnd; CREATE TABLE T_EB_FrontEnd( ID int primary key, NAME NVARCHAR2(30) not null,--前置机配置名称 BANK_NAME VARCHAR2(10) not null,--银行简码 STATUS VARCHAR2(10) default 'enable',--状态:是否启用 CREATE_TIME TIMESTAMP(6) not null, UPDATE_TIME TIMESTAMP(6) ); CREATE SEQUENCE FRONTEND_ID_SEQ INCREMENT BY 1 ST...
true
23cb6142a8a3df808725d9b15f2f5b091cb62b16
SQL
LaurenTowey/INSE-Group-B
/SmartSplit database.sql
UTF-8
1,904
3.671875
4
[]
no_license
Create database SmartSplit; use SmartSplit; CREATE TABLE Account( account_ID INT PRIMARY KEY NOT NULL AUTO_INCREMENT, account_Name VARCHAR(45) NOT NULL, account_Password VARCHAR(45) NOT NULL, account_Email VARCHAR(45) NOT NULL ); CREATE TABLE Friend( friend_ID INT PRIMARY KEY NOT NULL AUTO_...
true
64c6c680e983de9fe53da7c8cca0d3de9c44261e
SQL
Bricegnanago/zoomStudent
/agite/marquer.sql
UTF-8
1,955
3.453125
3
[]
no_license
-- -------------------------------------------------------- -- Hôte : localhost -- Version du serveur: 5.7.24 - MySQL Community Server (GPL) -- SE du serveur: Win32 -- HeidiSQL Version: 9.5.0.5337 -- -------------------------------------------------------- /*...
true
c6ede8cfcfcb6b8ce4e2a060fa31f60785e39239
SQL
zhang367007/pgcodekeeper
/apgdiff.tests/src/main/resources/cz/startnet/utils/pgdiff/selected_only_diff.sql
UTF-8
402
2.578125
3
[ "Apache-2.0" ]
permissive
SET search_path = pg_catalog; -- HIDDEN: Object public.v2 of type VIEW (action DROP) -- HIDDEN: Object public.v1 of type VIEW (action DROP) ALTER TABLE public.tbl ALTER COLUMN name TYPE integer USING name::integer; /* TYPE change - table: public.tbl original: text new: integer */ -- HIDDEN: Object public.v1 of typ...
true
9cfb57f968e41b0bf28132dc67e979657ad860a5
SQL
xaviercomi/mysql-estructura
/pizzeria.sql
UTF-8
7,852
3.703125
4
[]
no_license
-- Dades per crear la base de dades DROP DATABASE IF EXISTS pizzeria; CREATE DATABASE pizzeria CHARACTER SET utf8mb4 ; USE pizzeria; CREATE TABLE PROVINCIA ( provincia_id SMALLINT PRIMARY KEY AUTO_INCREMENT, provincia_nom VARCHAR(30) ); CREATE TABLE LOCALITAT ( localitat_id SMALLINT PRIMARY KEY AUTO_INCREMENT, lo...
true
c47db2ac361c8f85d2f190909f0adc22ea7ab618
SQL
jampaniuday/DBA-Scripts
/Memory_usage_by_each_session.sql
UTF-8
2,415
4.03125
4
[]
no_license
##Script to find out how much memory each session is using COLUMN sid FORMAT 999 HEADING 'SID' COLUMN oracle_username FORMAT a12 HEADING 'Oracle User' JUSTIFY right COLUMN os_username FORMAT a9 HEADING 'O/S User' JUSTIFY right COLUMN ...
true
607ca172664906562300b73be69fd41be2f9d124
SQL
smeagolthellama/super-duper-couscous
/konquest.sql
UTF-8
6,177
3.546875
4
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.6.6deb5 -- https://www.phpmyadmin.net/ -- -- Host: localhost:3306 -- Generation Time: Oct 24, 2018 at 12:39 PM -- Server version: 10.1.35-MariaDB-1 -- PHP Version: 7.2.9-1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CH...
true
b43655efb759a342147252b62da3dc65603ae13f
SQL
AnahiMir20/Proyectos
/Back/mvc/db/presupuestos_actualizado.sql
UTF-8
2,174
3.671875
4
[]
no_license
CREATE DATABASE presupuestos USE presupuestos CREATE TABLE users ( id_user int NOT NULL IDENTITY(1,1), [user] CHAR(30) NOT NULL, [name] CHAR(30) NOT NULL, last_name CHAR(30) NOT NULL, email CHAR(35) NOT NULL, [password] CHAR(100) NOT NULL, tel int NOT NULL, PRIMARY KEY (email) ) SELECT * FROM users ...
true
0acfc0b23d08442eb801c54669592770449f3355
SQL
dneves02/cs313-php
/db/db_inserts.sql
UTF-8
2,257
3
3
[]
no_license
$ heroku addons:create heroku-postgresql:hobby-dev $ heroku config -s DATABASE_URL= 'postgres://uaxuoahacaehsj:0fe3a8009bb1895ec30c9f73b234a9d6de1e361c9f477bd591fcfe699b078e58@ec2 -54-158-222-248.compute-1.amazonaws.com:5432/d8srftkdeo3t65' # First Create the database CREATE DATABASE timecard; # Connect to the datab...
true
772dc29899a4e4f2d9324808a528211de3654d50
SQL
helgagu/reviewSearchHelper
/mySQLFiles/createReviewSearchHelperSchema.sql
UTF-8
9,258
3.640625
4
[]
no_license
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0; SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0; SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES'; DROP SCHEMA IF EXISTS `reviewSearchResults` ; CREATE SCHEMA IF NOT EXISTS `reviewSearchResults` DEFAULT CHARACTER SE...
true
e997f2c8635f58ee5e563913519da76af9340a6b
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day18/select0407.sql
UTF-8
178
2.625
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-17T04:07:00Z' AND timestamp<'2017-11-18T04:07:00Z' AND temperature>=39 AND temperature<=54
true
828ded19576cd6f389fa58760a07f9b896e5d99b
SQL
gears-project/gearsx
/migrations/2019-12-27-091508_create_projects/up.sql
UTF-8
348
3.171875
3
[]
no_license
CREATE TABLE projects ( id UUID PRIMARY KEY NOT NULL, name TEXT NOT NULL, description TEXT NOT NULL, model_id UUID, created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(), updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW() ); CREATE TRIGGER set_projects_timestamp BEFORE UPDATE ON projects FOR EACH ROW EXECUTE PROCED...
true
c0d578ff05d9f78fab4a8e684612db3e784cfecc
SQL
gregus92/tp_quizz_java
/src/java/sql/quiz.sql
UTF-8
2,563
3.234375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.1.14 -- http://www.phpmyadmin.net -- -- Client : 127.0.0.1 -- Généré le : Lun 18 Mai 2015 à 14:22 -- Version du serveur : 5.6.17 -- Version de PHP : 5.5.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_...
true
a60394e65f9e31b5c4dac6b23643cfaa61f4fde6
SQL
mustafasacli/UsefulDatabaseScripts
/MySql/GetPrimaryKeys.sql
UTF-8
1,765
4.25
4
[]
no_license
-- https://stackoverflow.com/questions/2341278/how-to-get-primary-key-of-table/2341388 show columns from tablename where `Key` = "PRI"; -- https://stackoverflow.com/questions/2341278/how-to-get-primary-key-of-table/2341388 SHOW KEYS FROM table WHERE Key_name = 'PRIMARY' -- ** If you have spatial tables in your data...
true
7297cf70696cf048d6bcd716911d13dec5b75aca
SQL
TimurM/aa_academy
/week3/w3d2/import_db.sql
UTF-8
1,951
4.03125
4
[]
no_license
CREATE TABLE users ( id INTEGER PRIMARY KEY, fname VARCHAR(255) NOT NULL, lname VARCHAR(255) NOT NULL ); CREATE TABLE questions ( id INTEGER PRIMARY KEY, title TEXT NOT NULL, body TEXT NOT NULL, user_id INTEGER NOT NULL, FOREIGN KEY (user_id) REFERENCES users(id) ); CREATE TABLE question_followers ( ...
true
866a4b386922e356a78081e742d157b2d3f81f2f
SQL
albertomattos/SQL_gerais
/DBA/Tablespace.sql
UTF-8
3,780
3.625
4
[]
no_license
--% utilizado por cada filename SELECT file_name, tablespace_name, round((bytes/maxbytes)*100,0) perc_usado FROM DBA_DATA_FILES WHERE TABLESPACE_NAME in ('SYSTEM', 'WPDDADOS', 'WPDINDICES', 'TSD_MEGA', 'TSI_MEGA','VETORH_INDEX','VETORH_DATA') order by 2,3 SELECT file_name, tablespace_name, round((bytes/maxbytes)*100,0...
true
7db68079ab5e1352e9d5281643dc18998c293f18
SQL
mettlesolutions/coverage_determinations
/src/data/NCD/Cat1/SerologicTestingForAcquiredImmunodeficiencySyndrome(AIDS)/SerologicTestingForAcquiredImmunodeficiencySyndrome(AIDS).cql
UTF-8
2,752
3.34375
3
[ "Apache-2.0" ]
permissive
library SerologicTestingForAcquiredImmunodeficiencySyndrome using FHIR include FHIRHelpers version '1.8' called FHIRHelpers //include otherLibrary version 'x.x' called otherLibrary //codesystem codeSystemName : 'OID' version 'x.x' //valueset valuesetName : 'OID' version 'x.x' codesystems{codeSystem1 , codeSystem2, e...
true
42c4fa7a8e752e798327245af33eac56170c54a6
SQL
bigWebApps/Fleet
/DB/Scripts/dbo.sp_SelectComponentTypeList.PRC
UTF-8
722
3.71875
4
[]
no_license
SET QUOTED_IDENTIFIER ON GO SET ANSI_NULLS ON GO if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[sp_SelectComponentTypeList]') and OBJECTPROPERTY(id, N'IsProcedure') = 1) drop procedure [dbo].[sp_SelectComponentTypeList] GO CREATE PROCEDURE sp_SelectComponentTypeList ( @EquipId int ) AS ...
true
ae8534852f9ed2f82b07157aa7f72a62d4369408
SQL
HenriqueHaggstrom/BD
/motos.sql
UTF-8
1,539
3.5625
4
[]
no_license
# BD create table proprietario ( id int(5) auto_increment, nome varchar(30), nascimento date, cpf decimal(11,1) not null, estado varchar(2) not null default 'RS', cidade varchar(30), PRIMARY KEY (id), CONSTRAINT `fk_motos_proprietario` FOREIGN KEY ( `id` ) REFERENCES `motos` ( `id` ) )ENGINE = innodb; create database ...
true
747a5ecfdba1c5334691ab593a5fe372fd965bc3
SQL
veyisTurgut/cmpe321-p1-sqlQueries
/q6.sql
UTF-8
1,286
4.59375
5
[]
no_license
SELECT T.short_name, T.full_name, T.team_wc_count, SUM(D1.total_podiums + D2.total_podiums) /* return short names, full names, world championship counts, and team total podiums*/ FROM Teams T INNER JOIN Drivers D1 ON T.driver_one = D1.driver_id INNER JOIN Drivers D2 ON T.driver_...
true
512cb48701bc50e70abba9543b471bb5b760f3f6
SQL
whitemind/CursoPHP
/bd/tbusuarios.sql
UTF-8
466
2.9375
3
[]
no_license
use dbPHP7; CREATE TABLE tb_usuarios ( idusuario INT NOT NULL AUTO_INCREMENT PRIMARY KEY, deslogin NVARCHAR(64) NOT NULL, dessenha NVARCHAR(255) NOT NULL, dtcadastro TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP() ); INSERT INTO tb_usuarios(deslogin,dessenha) VALUES('Bruno','12345') update tb_usuarios se...
true
d79b86d2cbc00c94920f8b32290499a3a6d11336
SQL
Elisa003/Quizz
/db/structure.sql
UTF-8
1,840
3.984375
4
[]
no_license
--Supprime les tables suivantes si elles existent déja DROP TABLE if exists THEME; DROP TABLE if exists QUESTION; DROP TABLE if exists UTILISATEUR; DROP TABLE if exists DIFFICULTE; DROP TABLE if exists GAGNE; --Crée la table THEME CREATE TABLE THEME( id_theme INTEGER NOT NULL PRIMARY KEY auto_increment, libelle VARC...
true
0f0c8d5d7e666be1f283c09259f1713b3765f8ff
SQL
FredGOVIGNON/FORMATION_WCS
/WILD VILLAGE projet 3/wildvillage03-05-2016.sql
UTF-8
5,738
2.8125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.6.0 -- http://www.phpmyadmin.net -- -- Client : localhost -- Généré le : Mar 03 Mai 2016 à 17:27 -- Version du serveur : 5.7.12-0ubuntu1 -- Version de PHP : 7.0.6-1+donate.sury.org~xenial+1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHA...
true
5a59d78df2750a2fd05b66294254d54670a12ff9
SQL
fede2s/My-Course-s-Notes
/MySql/PA.sql
UTF-8
1,781
3.78125
4
[]
no_license
/* Profesores - Alumnos en mysql*/ /* Uso de llaves */ /* Para usar este script puedo usar el siguiente comando SOURCE C:\Users\FdS2\Desktop\PA.sql * Este script fue hecho para probar lo visto en el curso de bases de datos acerca de llaves primarias y llaves foraneas * El nombre es corto par...
true
37e3e32eae3953ab059a8bba7d660134a73a6d19
SQL
kamleshksingh/Kettle
/MKDM/sql/dns_crt_cdw_dncdne_indx.sql
UTF-8
1,114
2.765625
3
[]
no_license
------------------------------------------------------------------------------- -- Program : dns_crt_cdw_dncdne_indx.sql -- Original Author : kwillet -- -- Description : Create index on dns_cdw_dnc_dne_temp (acct_id, acct_seq_no) -- -- -- Revision History: Please do not stray from the example prov...
true
d082c18e71c9bc1dfbcf514b3296c87126c18633
SQL
carlollol/Homework-Bamazon
/Bamazon_2017-04-27.sql
UTF-8
2,006
3.109375
3
[]
no_license
# ************************************************************ # Sequel Pro SQL dump # Version 4541 # # http://www.sequelpro.com/ # https://github.com/sequelpro/sequelpro # # Host: 127.0.0.1 (MySQL 5.7.17) # Database: Bamazon # Generation Time: 2017-04-27 17:51:51 +0000 # ***********************************************...
true
60931ac6582d98ceda96b38dc7753c886476a8f8
SQL
vlbash/diklz
/src/App.Data/Migrations/SQL/v1.32.sql
UTF-8
1,691
3.03125
3
[]
no_license
 DO $$ BEGIN IF NOT EXISTS(SELECT 1 FROM "__EFMigrationsHistory" WHERE "MigrationId" = '20190926074304_v1.32') THEN CREATE TABLE pharmacy_item_pharmacies ( id uuid NOT NULL, record_state integer NOT NULL, caption character varying(128) NULL, modified_by uuid NOT NULL, mo...
true
f2dd33e438999eb24834c5d6f522790606b1b795
SQL
Camillelib/0323_2020DATAPAR
/Labs/module_1/MySQL_extra/bank_data/solutions_lab2.sql
UTF-8
4,055
4.84375
5
[]
no_license
#1. From the client table, of all districts with a district_id lower than 10, #how many clients are from each district_id? #Show the results sorted by district_id in ascending order. select district_id, count(distinct client_id) from client where district_id<10 group by district_id; #2. From the card table, how many...
true
ba776805ca0d2c1cec9997abc02120db33bbf8d2
SQL
Rkaufman0427/IT2351
/Assignment1D.sql
UTF-8
177
2.546875
3
[]
no_license
-- Created a query to show all the invoices for vendor_id 123 from the ap database. -- Created by Jeyanthi on 09/02, Fall 2021. SELECT * FROM ap.invoices WHERE vendor_id = 123;
true
4b4a4d3f0640e915f3a6794c7dccaf844759361e
SQL
topcoder-platform/tcs-cronos
/client_project_management_services/tags/version-1.0.0.1/test_files/schema.sql
UTF-8
5,365
3.0625
3
[]
no_license
CREATE TABLE informix.id_sequences ( name VARCHAR(255) NOT NULL, next_block_start INT8 NOT NULL, block_size INTEGER NOT NULL, exhausted INTEGER DEFAULT 0 NOT NULL, PRIMARY KEY(name) ); CREATE TABLE company ( id serial NOT NULL, name VARCHAR(64), passcode VARCHAR(64), c...
true
ce0292ed361ac99692499c27913cba58052401e9
SQL
Mariacagi/curso_data_science
/Taller_SQL/Curso UDemy/SQLQuery2.sql
ISO-8859-10
1,211
3.1875
3
[]
no_license
CREATE TABLE Clase( ClaseID INT PRIMARY KEY IDENTITY (1,1), FechaApertura Date, HoraClase VARCHAR(10), MaestroNombre VARCHAR (100), Precio Money, AlumnoNombre VARCHAR(100) ) INSERT INTO Clase (Nombre, FechaApertura, HoraClase, MaestroNombre, Precio, AlumnoNombre) VALUES ('Espaol', '18-03-2020', '2000', 'Estefani...
true
01ea8f5e53a925f1026655fe791f5e619a9aee88
SQL
google-code/acq-control
/AcqControl/AcqControl.Core/src/main/resources/plsql/INDX.sql
UTF-8
1,450
3.359375
3
[]
no_license
REM------------------------------------------- REM IE_VERSION : NAT03.000001 REM------------------------------------------- REM REM Script de creation de lindex I_MFRARRHIST_1 REM Auteur : A.FEZAI REM Date : 26/06/2009 REM Objet : Projet STD / HL65658 REM Evolution : DED57_091_STD482_ANNULATION_ARRETE_GES...
true
afc699c4acd4e0dee1565dae82df70fc9d605b91
SQL
Yacarreon93/TAASA-ERP
/htdocs/install/mysql/tables/llx_product.sql
UTF-8
4,628
3.015625
3
[]
no_license
-- ============================================================================ -- Copyright (C) 2002-2006 Rodolphe Quiedeville <rodolphe@quiedeville.org> -- Copyright (C) 2008-2010 Laurent Destailleur <eldy@users.sourceforge.net> -- Copyright (C) 2005-2010 Regis Houssin <regis.houssin@capnetworks.com> -- Copyr...
true
cdb641ad1515b9bafb0fae2bfbb6cf19a18a3252
SQL
JamKong/job
/db/init.sql
UTF-8
859
2.890625
3
[]
no_license
create table quartz_job ( id VARCHAR(64) NOT NULL COMMENT 'id', name varchar(100) NOT NULL COMMENT '任务名称', trigger_name varchar(100) NOT NULL COMMENT '触发器名称', group_name varchar(100) NULL COMMENT '分组名称', cron_exp varchar(20) NOT NULL COMMENT 'cron表达式', bean_name varchar(100) NOT NULL COMMENT '任务执行时调用的类名,完全限...
true
ad16b11240c9c18089ceda56280fa5fb86805812
SQL
ScottzMC/blog
/blog_db(2).sql
UTF-8
7,377
3.078125
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Aug 20, 2020 at 12:31 AM -- Server version: 10.1.38-MariaDB -- PHP Version: 7.3.3 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
4151249ec5a8545ddd0c397ad8051a72713b50df
SQL
Audrey0412/Lab
/database.sql
UTF-8
4,484
3.53125
4
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.4.10 -- http://www.phpmyadmin.net -- -- Client : localhost:8889 -- Généré le : Mer 11 Octobre 2017 à 14:37 -- Version du serveur : 5.5.42 -- Version de PHP : 7.0.0 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Base de données : `library` -- -- ------...
true
aa14b5caf876da85a6f6bf4c8a8bedfaf3f13bac
SQL
mmulenga/Computer-Science
/CMPT 355/Assignments/Assignment 4/test_operations.sql
UTF-8
1,479
3.234375
3
[]
no_license
/* Matthew Mulenga */ /* mam558 */ /* 11144528 */ SELECT set_config('session.trigs_enabled', 'Y', FALSE); -- Create a new employee, this should create an insert audit action in employee_audits INSERT INTO employees(employee_number, title, first_name, middle_name, last_name, gender, ssn, birth_date, marital_status_id,...
true
eed66e3192580b56f31a1ae48b767b8b30f0e5f5
SQL
volodymyrhusak/Users
/sqlProc.sql
UTF-8
4,448
4.53125
5
[]
no_license
DELIMITER $$ USE Users$$ drop procedure if exists add_user$$ CREATE PROCEDURE add_user( IN userName VARCHAR(30), IN userEmail VARCHAR(30), IN userPhone VARCHAR(30), IN userMobilePhone VARCHAR(30), IN userStatus INT(1) ) BEGIN INSERT INTO Users.Users (Users.userName, Users.userEmail, Users.u...
true
8be5690781018a93a285745bf03ac3398d4ce997
SQL
grupo43/CouchInn
/couchinn.sql
UTF-8
6,098
3.6875
4
[]
no_license
-- Adminer 4.2.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 DATABASE IF EXISTS `couchinn`; CREATE DATABASE `couchinn` /*!40100 DEFAULT CHARACTER SET utf8 COLLATE utf8_bin */; USE `couchinn`; DROP TABLE IF EXISTS `accepted_reservation`...
true
b92606946e90328bd966e4f37f635a35e25a14e6
SQL
bryant1410/GourdScan
/pscan.sql
UTF-8
3,393
3.078125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 3.4.9 -- http://www.phpmyadmin.net -- -- 主机: localhost -- 生成日期: 2015 年 11 月 16 日 02:57 -- 服务器版本: 5.5.20 -- PHP 版本: 5.3.9 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_...
true
5e37c924523fcd553173d45ccb45f0a101dfe629
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day21/select1143.sql
UTF-8
191
2.78125
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerObservation WHERE timestamp>'2017-11-20T11:43:00Z' AND timestamp<'2017-11-21T11:43:00Z' AND SENSOR_ID='5ebf8782_caac_4acc_b0a8_be93a9b09745'
true
f100ea4bf360e5270f9c75b01264068a19f97a68
SQL
reeli/data-structures-practice
/js/q4.sql
UTF-8
251
3.546875
4
[]
no_license
WITH t (STUDENT_ID, SUM_OF_MARKS) AS (SELECT DISTINCT STUDENT_ID, SUM(MARKS) FROM marks GROUP BY STUDENT_ID) SELECT * FROM t where SUM_OF_MARKS > 500 ORDER BY STUDENT_ID DESC
true
7bdf51669c90e52238c9774ab9b000bee43759d2
SQL
softwareteknologi/masterbackend
/infogunu_db.sql
UTF-8
6,997
3.078125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jan 21, 2018 at 07:27 AM -- Server version: 10.1.29-MariaDB -- PHP Version: 7.1.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
33a118d66a2ff2bf767fd965637dc6330eef18ec
SQL
601729260/Navicat
/MySQL/servers/ 报表库/mamahao_report/根据佣金比例修复数据.sql
UTF-8
7,643
3.765625
4
[]
no_license
#-----------------根据佣金比例修复 select max(direct_bonus) ,item_num_id from t_star_shop_goods_bonus_log where item_num_id in ( select distinct order_no, item_num_id,update_time from mamahao_warehouse.t_star_member_sales_detail a where update_time>'2019-10-11 03:00:00' and channel_type in (0) and order_time<'2019-10-11 00:00...
true
2dc036df21659544af62f0a3195640f0e08a4e04
SQL
pranjalijadhav13/book-recommendation-site
/bookdetails.sql
UTF-8
1,413
2.953125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 14, 2018 at 08:26 PM -- Server version: 10.1.32-MariaDB -- PHP Version: 5.6.36 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; ...
true
e38a3907f6c6e94c39a249bb2f89edd29fa771a4
SQL
daussho/aks
/natc.sql
UTF-8
5,649
3.046875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Apr 17, 2017 at 07:05 PM -- Server version: 10.1.16-MariaDB -- PHP Version: 7.0.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLI...
true
7291feddcf84012e53f5cea7ac6c8a898f582295
SQL
magdalena70/MSSQL-DB-Basics
/SQL-Language-Basics/Homework_03-DB-Basics-MSSQL-Basic-CRUD-Exercises/Problem_12-FindAllEmployeesWithSalaryMoreThan50000.sql
UTF-8
108
2.6875
3
[]
no_license
SELECT [FirstName], [LastName], [Salary] FROM [Employees] WHERE [Salary] > 50000.00 ORDER BY [Salary] DESC
true
591635d87951775cc7538459425e3b20d23dfb90
SQL
Ares7/2013-JUL-Module-7
/Task 05/Anzhela_Papova_labwork05/dw/tables/t_geo_objects/t_geo_objects.sql
UTF-8
1,515
3.984375
4
[]
no_license
--alter table dw.t_geo_objects -- drop constraint FK_T_GEO_TYPES2T_GEO_OBJECTS; -- --alter table dw.t_geo_systems -- drop constraint FK_T_GEO_OBJECTS2T_GEO_SYSTEMS; -- --drop index dw.ui_geo_objects_codes; -- --drop table dw.t_geo_objects cascade constraints; --=====================================================...
true
d15e4ee2397553582fd57f0da864a3a3be101996
SQL
leeneko/SQL
/1. 재고금액.sql
UTF-8
868
3.4375
3
[]
no_license
ALTER PROCEDURE STD_ICM_M_110 ( ) LANGUAGE SQLSCRIPT SQL SECURITY INVOKER AS BEGIN SELECT C."ItmsGrpNam", SUM( CASE WHEN A."DocDate" < CURRENT_DATE THEN (A."InQty" * A."Price") - (A."OutQty" * A."Price") END ) AS "전일(금액)", SUM( CASE WHEN A."DocDate" <= CURRENT_DATE THEN (A."InQty" * ...
true
7c04f203768af3e0003d6817e977cd121cae15b6
SQL
poikoak/2
/1/first.sql
UTF-8
455
3.25
3
[]
no_license
--CREATE DATABASE library /*USE library*/ CREATE TABLE authors(id INT IDENTITY PRIMARY KEY, firstname VARCHAR(20), lastname VARCHAR(20), age INT) drop table authors SELECT * FROM authors insert into authors(firstname, lastname, age) values ('Alex', 'Pushkin', 321) delete from a...
true
f3d4b7eb4f1f9cd557f677b13bde27b8205df844
SQL
brightniyonzima/eid
/docs/custom_sql/db.eid.revamp.2.sql
UTF-8
26,487
3.5625
4
[ "Apache-2.0" ]
permissive
/* Appendix: Mother PMTCT ARV Antenatal Table */ DROP TABLE IF EXISTS eid_appendix_pmtctarvsmothersantenatal; CREATE TABLE eid_appendix_pmtctarvsmothersantenatal ( id mediumint unsigned NOT NULL AUTO_INCREMENT, appendix varchar(200) NOT NULL, position mediumint unsigned NOT NULL, created datetime NOT NULL, /* A...
true
30190c6cbf5c5850222d0cfd61653163d565e55a
SQL
dandraden/Database-Scripts
/Oracle/others/user_script/prc_critica_contrato.sql
ISO-8859-1
17,899
3.078125
3
[]
no_license
/* Formatted on 2004/12/08 13:58 (Formatter Plus v4.5.2) */ CREATE OR REPLACE PROCEDURE ifrbde.prc_critica_contrato ( v_num_seq_contrato IN NUMBER ) IS -- -- objetivo: executar criticas sobre os dados do contrato para que possa -- se enviado para o smartstream -- -- Historico de modificaes -- Pes...
true
8fe6e5d96e4097b25b1b181282ec8577336bd493
SQL
ClickHouse/ClickHouse
/tests/queries/0_stateless/00230_array_functions_has_count_equal_index_of_non_const_second_arg.sql
UTF-8
2,127
2.890625
3
[ "BSL-1.0", "Apache-2.0" ]
permissive
select has([0 as x], x); select has([0 as x], materialize(x)); select has(materialize([0 as x]), x); select has(materialize([0 as x]), materialize(x)); select has([toString(0) as x], x); select has([toString(0) as x], materialize(x)); select has(materialize([toString(0) as x]), x); select has(materialize([toString(0) ...
true
4c66207b1331b85df7ccd3b67df2ee4db5cf8e9a
SQL
ruitaomu/BI-Visualization
/db.create/project_tester.sql
UTF-8
457
2.859375
3
[]
no_license
DROP TABLE IF EXISTS project_tester; CREATE TABLE project_tester ( id int unsigned not null auto_increment, project_id int unsigned not null default 0, tester_id int unsigned not null default 0, wistia_video_hashed_id varchar(32) not null default '', index_file varchar(64) not null default '', tags_file var...
true
09b4a40779e9646865c5fd7afa13909a39e56ad9
SQL
snavarrete1/HW-sql3
/HWday3.sql
UTF-8
1,667
4.40625
4
[]
no_license
--1.List all customers who live in Texas SELECT first_name, last_name, district FROM address JOIN customer ON address.address_id = customer.address_id WHERE district = 'Texas'; --2.Get all payments above 6.99 with the Customer's Full Name SELECT first_name, last_name, amount FROM customer JOIN payment ON customer.cu...
true
930b0f2b58b316cb7bcded3d797bccbc877bba49
SQL
hpardess/OpenMRS-NRH
/SQL Data Sets/Encounter/Discharge Encounter.sql
UTF-8
3,234
3.90625
4
[]
no_license
SELECT patient_identifier.identifier, DATE(person.date_created) AS register_date, CONCAT(family_name, ' ', given_name) AS fullname, birthdate, TIMESTAMPDIFF(YEAR, birthdate, CURDATE()) AS age, gender, (SELECT person_attribute.value FROM person_attribute WHERE person_attribute_type_id=11 AND person_attribut...
true
1285752dc1b2a8c6edfb77eea47a9c29d17c2442
SQL
aliashkov/JD2018-08-21
/src/by/it/nesterovich/jd03_01/init_db_online_reserved_tickets.sql
UTF-8
8,093
3.3125
3
[]
no_license
-- MySQL Workbench Forward Engineering SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0; SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0; SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES'; -- ----------------------------------------------------- -- Schema nesterovi...
true
3bcc711fbe6ef037a54c6a586598a9f3c36a36db
SQL
chedly-abdennadher/premier-projet-
/src/parts/procedure verif identite.sql
UTF-8
216
2.734375
3
[]
no_license
CREATE OR REPLACE PROCEDURE VERIF_IDENTITE (id_carte in int(11)) is x int(11) begin select count(*) into x from identite where identite.id_carte=id_carte; if (x==0) return true; else return false; end if; end;
true
2bd09fba4af4f5b71cef0c0750261ecb888880a9
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/low/day15/select1451.sql
UTF-8
264
2.828125
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='WiFiAP' AND sen.id=ci.SENSOR_ID AND ci.INFRASTRUCTURE_ID=ANY(array['5062','3074','2064','2100_6','3204','5064','4214','4089','6211','4068'])
true
e490a754239580500a01cee1ec83b3c7416919e9
SQL
source-farm/MasteryWithSQL
/05_Data_types/04.Date_time.sql
UTF-8
4,982
4.09375
4
[]
no_license
-- Для работы с датами и временем есть несколько типов данных: -- date - только дата -- time - только время -- timestamp - дата + время -- timestamptz - дата + время + часовой пояс -- interval - разница между временами --------------------------------------------------------------------------------...
true
37619de28f3b02b0aba3df3af99e6950cb84b70f
SQL
syrus-ru/amficom
/AMFICOM/v2/database/schema/measurement/object/evaluation.sql
UTF-8
1,057
3.40625
3
[]
no_license
CREATE TABLE Evaluation ( id NUMBER(20, 0), created DATE NOT NULL, modified DATE NOT NULL, creator_id NUMBER(20, 0) NOT NULL, modifier_id NUMBER(20, 0) NOT NULL, -- type_id NUMBER(20, 0) NOT NULL, monitored_element_id NUMBER(20, 0) NOT NULL, -- threshold_set_id NUMBER(20, 0) NOT NULL, etalon_id NUMBER(20, 0) N...
true
95585ec9ce7fed84e4ec0c6a2d16a79d4e8ec3f0
SQL
quyetaloha/spring-boot-api-student-score
/sql.sql
UTF-8
5,212
2.96875
3
[]
no_license
CREATE DATABASE IF NOT EXISTS `student` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci */; USE `student`; -- MySQL dump 10.13 Distrib 8.0.14, for Win64 (x86_64) -- -- Host: 127.0.0.1 Database: student -- ------------------------------------------------------ -- Server version 8.0.12 /*!40101 SE...
true
7316a3a3b7f7714bdf19ef6ae4dcf19d877f66bf
SQL
cckmit/leleooche
/src/main/java/com/leletc/product/sql/ProductsDao_getListByUserId.sql
UTF-8
248
2.921875
3
[]
no_license
SELECT * FROM auto_base_products p WHERE p.sys_org_code = ( SELECT d.org_code from t_s_depart d WHERE d.id = ( SELECT bu.departid from t_s_base_user bu WHERE bu.id = :userId ) ) AND p.id = :parentProductId AND p.product_status = :productStatus
true
5af20fb102db2bab6557657dbe859b41cedc191f
SQL
phpalchemy/sandbox
/schema/database/Sandbox.sql
UTF-8
4,403
3.625
4
[]
no_license
# This is a fix for InnoDB in MySQL >= 4.1.x # It "suspends judgement" for fkey relationships until are tables are set. SET FOREIGN_KEY_CHECKS = 0; -- --------------------------------------------------------------------- -- book -- --------------------------------------------------------------------- DROP TABLE IF E...
true
95627f93d08a4465199c078ab0ed02a619bbf8a7
SQL
bluesky777/Olimpiadas-acade-micas
/OlimpiadasDB/Algunas consultas/Examenes.sql
UTF-8
803
3.6875
4
[]
no_license
select ExaId, u.UsuCodigo, UsuNombre, CatNombreCorto, ExaCantPreg, Det.CantContestadas, Det.CantCorrec from tbEventos ev, tbCategorias c, tbInscripciones i, tbExamenes ex, tbEntidades en, tbUsuarios u, (select count(D.DetPregunta) as CantContestadas, count(D.DetContestada) as CantCorrec from tbDetalleExamen ...
true
1d0807b24008b0fefc39d8b966de3beabd428843
SQL
hrl159159/Spring-Vue-garbageclassfy
/garbageclassfication.sql
UTF-8
261,495
3.328125
3
[]
no_license
/* Navicat Premium Data Transfer Source Server : root Source Server Type : MySQL Source Server Version : 80017 Source Host : localhost:3306 Source Schema : garbageclassfication Target Server Type : MySQL Target Server Version : 80017 File Encoding : 65001 Date: 25/03...
true
187de49e809fbcfcc1ea1fd8828b7c68e46c2eda
SQL
bjchangxiao/gitnotes
/READXML.sql
UTF-8
2,285
3.34375
3
[]
no_license
create or replace procedure test_clob(v_itemid number) as l_clob CLOB; l_parser DBMS_XMLPARSER.parser; l_doc DBMS_XMLDOM.domdocument; l_nl DBMS_XMLDOM.domnodelist; l_n DBMS_XMLDOM.domnode; l_exists number(9):=0; TYPE tab_type IS TABLE OF bps%ROWTYPE; t_t...
true
92b3f2387f2ba6bfec24e229782d08ed2038980d
SQL
mauricionietom/FPD_APP4
/ScriptPostgre.sql
UTF-8
959
3.265625
3
[]
no_license
create table Usuario( idUser serial, email VARCHAR(30), pswd VARCHAR(20), nombre VARCHAR(30), apellido VARCHAR(30), colegio VARCHAR(30), PRIMARY key (idUser) ) create Table Experiencia( idExp serial, nombreExp VARCHAR(30), curso INTEGER, asignatura VARCHAR(30), tema VARCHAR(30), descripcion VARCHA...
true
e7af5818a4bc35d17bbb9412fa6fba89a4c358d2
SQL
ShahakBH/jazzino-master
/bi/bi-dbdw/src/main/resources/deltas/102.sql
UTF-8
7,218
3.40625
3
[]
no_license
INSERT IGNORE INTO rpt_report_status (report_action, action_ts, val, val_desc) values( 'promotionTransactionsExtractLastRun', '2012-2-27 01:00:00', null, '')# DROP PROCEDURE IF EXISTS rptExtractPromotionSummary# create procedure rptExtractPromotionSummary() begin start transaction; /* Transactions up to 21 da...
true