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
32d340c93f6cc44f7b593cb3f4c9e42fd9d8e95a
SQL
matomario8/Bulletin
/create.mysql
UTF-8
980
3.578125
4
[]
no_license
DROP TABLE IF EXISTS SendTos, Messages, Users; CREATE TABLE Users ( u_userid INTEGER UNSIGNED AUTO_INCREMENT, u_username VARCHAR(60), u_passhash CHAR(40), u_newpass CHAR(40), u_email VARCHAR(255), u_created TIMESTAMP DEFAULT CURRENT_TIMESTAMP, u_lastlogin TIMESTAMP NULL, u_validate CHAR(20), u_salt CHAR(20), u_newsalt...
true
d50933828bb3d8df7412c876de8d4e356bb29d18
SQL
Danderssen/DBISEx2
/sql zeug.sql
UTF-8
2,713
3.921875
4
[]
no_license
DROP TABLE APARTMENT; DROP TABLE CONTRACT; DROP TABLE ESTATE; DROP TABLE ESTATE_AGENT; DROP TABLE HOUSE; DROP TABLE PERSON; DROP TABLE PURCHASE_CONTRACT; DROP TABLE RENTS; DROP TABLE SELLS; DROP TABLE TENANCY_CONTRACT; CREATE TABLE Estate_Agent ( Name VARCHAR(50), Address VARCHAR(70), Login VARCHAR(20) UNIQ...
true
1ab154787d17e76bba1867821ba7e81b3a374bc3
SQL
vsuzarte/ekoob
/projetoPI/ekoob/src/main/java/com/aztec/koob/resources/maindb.sql
UTF-8
4,698
3.1875
3
[ "MIT" ]
permissive
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ /** * Author: guilherme.rpinto * Created: 03/10/2017 */ CREATE TABLE Produto( idProduto INTEGER PRIMARY KEY GENERATED...
true
d2b78f331b924193fb34230d25958def513fb489
SQL
DpadamsX/DpadamsX
/types_plus/loaner_v1/loaner_v1_combined.sql
UTF-8
4,158
3.4375
3
[]
no_license
-- Create a view onto loaner formatted as loaner_v1. -- If loaner changes, you can update the view to handle the modification smoothly. -- Note: This view is automatically a custom type, with an array type to match. See types_plus.insert_loaner_v1. DROP VIEW IF EXISTS types_plus.loaner_v1 CASCADE;-- Careful! CREATE OR...
true
b5aaaf449e2adb527c8142920738413b0ce91d7b
SQL
ayeti82/university-management
/DBHW2_Desmukhya_Ayetijhya/Create_Tables.sql
UTF-8
6,363
3.703125
4
[]
no_license
--use UniversityDatabase; CREATE TABLE University( [UniversityID] [varchar](10) NOT NULL, [UniversityName] [varchar](50) NOT NULL, CONSTRAINT PK_University PRIMARY KEY (UniversityID) ); CREATE TABLE Departments( [DepartmentID] [varchar](10) NOT NULL, [DepartmentName] [varchar](50) NOT NULL, [Univer...
true
60eb74aed3f099ba53b13a1029a63a16cf1a5945
SQL
coschain/contentos-go
/app/plugins/dbtables/trxinfo.sql
UTF-8
500
3.328125
3
[ "MIT" ]
permissive
create table trxinfo ( id bigint AUTO_INCREMENT PRIMARY KEY, trx_id varchar(64) not null, block_height int unsigned not null, block_time int unsigned not null, invoice json null, operations json null, block_id varchar(64) not null, creator varchar(64) not null, INDEX trxinfo_block_height_index (block_height...
true
5d533b4848b844019ed5a3a2d7f96745c658a4be
SQL
yknx4/Information-Retrieval-Engine--Indexer-
/SQL/information_retrievv1.sql
UTF-8
2,725
3.390625
3
[]
no_license
-- -------------------------------------------------------- -- Host: localhost -- Versión del servidor: 5.6.23-log - MySQL Community Server (GPL) -- SO del servidor: Win64 -- HeidiSQL Versión: 9.1.0.4867 -- --------------------------------------------------------...
true
7c66cee85b6ccc72b0432d75b3934dcd5c23c712
SQL
cnWumingrui/recruit
/parttime/src/main/resources/recruit.sql
UTF-8
6,252
3.15625
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : mysql Source Server Type : MySQL Source Server Version : 50558 Source Host : localhost:3306 Source Schema : parttime_job Target Server Type : MySQL Target Server Version : 50558 File Encoding : 65001 Date: 1...
true
d899406cf3303d0501ccb4e8a672f0602f1bd7c5
SQL
LFirmiano/kgstore
/scripts/create_pedidoitem.sql
UTF-8
640
3.140625
3
[]
no_license
CREATE TABLE pedido_item ( id_pedido_item INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY, tamanho VARCHAR(200) NOT NULL, quantidade INT(10) NOT NULL, valor DECIMAL(6,2) NOT NULL, cliente VARCHAR(200) NOT NULL, pagamento VARCHAR(200) NOT NULL, hora_compra DATETIME ) ALTER TABLE pedido_item ADD ...
true
1075b2b28a6251ece6cd3c0604347367fdc9f28b
SQL
ezinkow/Ask-This-Dad
/schema.sql
UTF-8
578
2.84375
3
[]
no_license
DROP DATABASE IF EXISTS askthisdad; CREATE DATABASE askthisdad; USE askthisdad; CREATE TABLE questions ( id INTEGER NOT NULL AUTO_INCREMENT, name VARCHAR(50) NOT NULL, category VARCHAR(100) NOT NULL, question TEXT NOT NULL, ); CREATE TABLE testimonials ( id INTEGER NOT NULL AUTO_INCREMENT, na...
true
fb4e14c2181910c5c01e4b9fcbb9ac2cc5e2c340
SQL
matpato/SIMELA
/web/ALSrm-sqlserver/ALSRM.Infrastructure/Data/SQLServer_Scripts/InsertData.sql
ISO-8859-1
4,260
3.3125
3
[ "MIT" ]
permissive
Use ALSRM; INSERT INTO Users(username,userpassword,securityQuestion,securityAnswer,descriminator) values('Xavier Pedro Linares','92f5675e579a6689b601a9223a458325','Best childhood friends name?', '0c50e40970f0b6ca97f8b3546cbf090f','patient') INSERT INTO Patient( id, patientid, mac_bitalino) VALUES (SCOPE_ID...
true
2455d73dbd1581b111eb411436f7f9b0530085d3
SQL
ThanhChanh-1420/website-tracuudongvat
/public/uploads_animal/B1805845.sql
UTF-8
4,485
3.671875
4
[ "MIT" ]
permissive
-- 1 VI DU CREATE OR REPLACE TRIGGER CHECK_SAL_COMM_EMP AFTER INSERT OR UPDATE ON SCOTT_EMP FOR EACH ROW BEGIN IF (:NEW.SAL <= :NEW.COMM) THEN RAISE_APPLICATION_ERROR ( num => -20225, msg => 'LUONG PHAI NHIEU HON THUONG'); ELSIF (:NEW.SAL <= :OLD.SAL) THEN RA...
true
2836a0a53720317915b4d04659ec75489ab66119
SQL
knguyen99/CS-143
/Project 3/q4.sql
UTF-8
127
2.65625
3
[]
no_license
SELECT COUNT(city) FROM ( SELECT * FROM affiliations WHERE name="University of California" GROUP BY city ) as T;
true
e96f45ce67598e1c45b0e8527612a03827b515da
SQL
apache/spark
/sql/core/src/test/resources/sql-tests/inputs/operators.sql
UTF-8
2,704
3.65625
4
[ "BSD-3-Clause", "CC0-1.0", "CDDL-1.1", "Apache-2.0", "LicenseRef-scancode-public-domain", "BSD-2-Clause", "LicenseRef-scancode-unknown-license-reference", "EPL-2.0", "CDDL-1.0", "MIT", "LGPL-2.0-or-later", "Python-2.0", "LicenseRef-scancode-generic-cla", "LicenseRef-scancode-free-unknown",...
permissive
-- unary minus and plus select -100; select +230; select -5.2; select +6.8e0; select -key, +key from testdata where key = 2; select -(key + 1), - key + 1, +(key + 5) from testdata where key = 1; select -max(key), +max(key) from testdata; select - (-10); select + (-key) from testdata where key = 32; select - (+max(key)...
true
f5382bb7114b3e75cce99e4a02be89a70ce77878
SQL
felpsbs/Clubinho-Nerd
/NerdClub/ReservMe/DB/ModelagemFisica.sql
UTF-8
3,598
3.640625
4
[]
no_license
CREATE DATABASE AGENDAMENTO; USE AGENDAMENTO; CREATE TABLE CLIENTE( IDCLIENTE INT PRIMARY KEY AUTO_INCREMENT, NOME VARCHAR(30) NOT NULL, SEXO ENUM(M, F) NOT NULL, EMAIL VARCHAR(50) UNIQUE, CPF VARCHAR(15) UNIQUE, CELULAR SENHA VARCHAR(8) ); INSERT INTO CLIENTE VALUES ('Ana Batista', 'F', 'ana....
true
f6e1cbf40d15acdf9b50df22aac92eef080d4464
SQL
awasekhirni/dbscripts
/mysqldb/createcourierdb.sql
UTF-8
18,364
3.078125
3
[]
no_license
# ---------------------------------------------------------------------- # # Script generated with: DeZign for Databases V8.1.2 # # Target DBMS: MySQL 5 # # Project file: courierdb.dez # # Project name: ...
true
6a94615dfead8faaeba6441f73d4c70cc58ced11
SQL
avamsykiran/PLSQL_23Apr2021_28Apr2021_14001600
/script17.sql
UTF-8
683
3.328125
3
[]
no_license
declare cursor sal_cursor is select e.department_id, employee_id, last_name, salary from employees e inner join departments d on e.department_id=d.department_id and d.department_id = 60 for update of salary nowait; begin for emp_record in sal_cursor ...
true
20c4ffe8ba30d77fdf1e0f8d2bc6cf4ad93ac2ee
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day18/select2136.sql
UTF-8
178
2.703125
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-17T21:36:00Z' AND timestamp<'2017-11-18T21:36:00Z' AND temperature>=30 AND temperature<=75
true
df344602c740f2cf37cd7377ecc75df0032c2bf2
SQL
liangzhifa/big-file-upload
/src/main/resources/sql/file_tb.sql
UTF-8
1,134
3.09375
3
[]
no_license
/* Navicat Premium Data Transfer Source Server : 阿里 Source Server Type : MySQL Source Server Version : 50728 Source Host : 47.100.45.101:3306 Source Schema : file_db Target Server Type : MySQL Target Server Version : 50728 File Encoding : 65001 Date: 22/07/2020 14:35...
true
732a3379919b034b6385f0bb1b367d8aa1a03343
SQL
HugoL18/Base-de-Datos-Gpo-010
/Funciones y procedimiento.sql
UTF-8
831
3.34375
3
[]
no_license
--Hugo Lopez Lugo #1748951 Funciones y Procedimientos --Funciones Create function MaestrosyMaterias (@materia varchar(50)) returns @maestros table (Idmaestro varchar(50), Nombre varchar(50),ApellidoPaterno varchar (50), ApellidoMaterno varchar(50) ,materia varchar(50)) as begin insert @maestros select Idmaestro, Nom...
true
5d8882163ee74ca593bd951102a9f8f6ff4b3ede
SQL
kitapkurduhatice/SQL
/HR.sql
UTF-8
2,600
4.15625
4
[]
no_license
/* 1) Select d.department_name,j.job_title job_name,h.start_date,h.end_date From DEPARTMENTS d,JOBS j,JOB_HISTORY h,EMPLOYEES e where e.job_id=j.JOB_ID and j.JOB_ID=h.JOB_ID and e.department_id=d.DEPARTMENT_ID and e.first_name='Steven' order by start_date,end_date;*/ /* 2) Select c.country_name,d.departm...
true
8b109e5f380aadb262ffc159ec54d8dae6ddd93b
SQL
launchbadge/sqlx
/tests/sqlite/migrations/1_user.sql
UTF-8
152
2.6875
3
[ "MIT", "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
create table user ( -- integer primary keys are the most efficient in SQLite user_id integer primary key, username text unique not null );
true
34385831bc9bf7604d21471f6d3bf6cd6ba436a8
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day20/select1959.sql
UTF-8
191
2.78125
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerObservation WHERE timestamp>'2017-11-19T19:59:00Z' AND timestamp<'2017-11-20T19:59:00Z' AND SENSOR_ID='b4abe576_cab4_4cc5_a620_94f9c3de779c'
true
d336b9288bf4550d524a2d54553d718f8c6eb8fa
SQL
lebozan/KTS-NWT-2020
/Cultural-content-app/src/main/resources/data.sql
UTF-8
3,521
2.609375
3
[]
no_license
--password: admin INSERT INTO registered_user (type, id, email, first_name, last_name, password, active) VALUES ('Admin',100,'admin@mail.com','Bojan', 'Cakic','$2y$12$YEZzLa8qmv69iere8iQzkO7AkJtcigLOrFI7jUSNRgYvTd2IZJZXq', true); --password: sifra1 INSERT into registered_user (type, id, email, first_name, last_name...
true
2b46651dab37653c54447ce8d13bb44386491e2f
SQL
susmitasomanchi/pharmacy
/evolutions/MedNetwork-1.3/20140922_add_blood_bank_entites.sql
UTF-8
3,155
3.671875
4
[]
no_license
--- Author: Lakshmi --- Script to create BloodBankUser,BloodBank,BloodDonation entities --- entities is added to models.bloodBank package. ---BloodBank create table blood_bank ( id bigint not null, name varchar(255), contact_person_name varchar(255), contact_no v...
true
3ee044c308f7b57ff9300a5bba0c0846f4f8fed6
SQL
mlanotte1998/DatabaseDesignA2
/Assignment-2/update.sql
UTF-8
1,058
3.765625
4
[]
no_license
-- Update developer - Update Charlie's primary phone number to 333-444-5555 UPDATE phones SET phone = '333-444-5555' WHERE phones.fk_person_id = 34 AND phones.primary = 1; -- Update widget - Update the relative order of widget head345 on the page so that it's new order is 3. Note that the other widget's order needs ...
true
a1f1ed292cdf7f31745eff20a40811e5bed0105a
SQL
shawnabroyles/meganjordan
/uploads/revisr-backups/revisr_wp_wc_admin_note_actions.sql
UTF-8
2,805
3.078125
3
[]
no_license
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SE...
true
75662ea46c9b5f34413dddc3dd64796c90360a00
SQL
SnowFox108/Nexus
/Controls/News/Doc/News.sql
UTF-8
2,020
3.5625
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'; CREATE SCHEMA IF NOT EXISTS `e2CMS` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci ; USE `e2CMS`; -- ------------------------------...
true
0d3bc4a16878b4c55f1c3a2783bc9ab673350fff
SQL
mqg007/CFCFrame
/db/mysql/frameuser_ssy_logcontrol.sql
UTF-8
3,068
2.984375
3
[ "MIT" ]
permissive
-- MySQL dump 10.13 Distrib 5.7.12, for Win64 (x86_64) -- -- Host: 127.0.0.1 Database: frameuser -- ------------------------------------------------------ -- Server version 5.7.17-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS *...
true
69eab006aeca7a710c0f05e1919c1a25a289feef
SQL
t2m-git/LeetCode
/SQL/1633.sql
UTF-8
220
3.25
3
[]
no_license
# Write your MySQL query statement below SELECT contest_id, ROUND((COUNT(user_id) / (SELECT COUNT(*) FROM Users))*100, 2) AS percentage FROM Register GROUP BY contest_id ORDER BY percentage DESC, contest_id;
true
6a0c25d1d82a49281bff2932010f80769b26dbdc
SQL
aakaashsrt200/skill-matrix
/Database/CreateStoreProc/sp_add_language.sql
UTF-8
438
3.4375
3
[]
no_license
USE skill_matrix; DELIMITER ;; CREATE DEFINER=`root`@`localhost` PROCEDURE `sp_add_language`(IN in_language_name varchar(50)) BEGIN DECLARE count INT DEFAULT 1; select count(*) INTO count from skill_matrix.`languages` a where a.language_name= in_language_name; IF(count = 0) THEN INSERT INTO SKILL_MATRIX.languag...
true
df1d3cc7daf3915023b3f0f1fffbc73262d3c8cd
SQL
neilkelly02/contact-tracing
/calculate_age.sql
UTF-8
192
2.765625
3
[]
no_license
-- Question 1 ALTER TABLE zvoid.census ADD age bigint; UPDATE zvoid.census SET age = id_Number; UPDATE census SET census.age = 2020-substring(id_Number, 6, 4); SELECT * FROM zvoid.census;
true
460a476495acf4bbb078e43dc75c10450be88a97
SQL
AjitKumar5/A
/ObjectHelper/SQL/UserDefinedDataTypes_9.sql
UTF-8
1,428
3.84375
4
[]
no_license
SELECT st.name AS [Name], sst.name AS [Schema], st.user_type_id AS [ID], CAST(CASE WHEN baset.name IN (N'nchar', N'nvarchar') AND st.max_length <> -1 THEN st.max_length/2 ELSE st.max_length END AS int) AS [Length], CAST(st.precision AS int) AS [NumericPrecision], CAST(st.scale AS int) AS [NumericScale], st.max_length ...
true
9a27e34548e51c15af8eef4787b2dc61e021a18f
SQL
hashiCode/challenge-backend
/task2/query.sql
UTF-8
288
3.6875
4
[]
no_license
select e.event_type, (select p.value from events p where p.event_type = e.event_type order by time desc limit 1 offset 1) - (select p.value from events p where p.event_type = e.event_type order by time asc limit 1) as value from events e group by e.event_type having count(e.event_type)>1
true
116715a1ec64c55e1e6d75080cc4833d1cf5f6d3
SQL
iloveloveyou/shell_script
/2015年1-3月广东各地市彩信计费用户和新增用户明细.sql
UTF-8
4,668
3.15625
3
[]
no_license
select n.mobile_sn 新增号码, m.province 省份, m.city 所属地市, to_char(n.mobile_sub_time, 'yyyy-mm-dd hh24:mi:ss') 新增时间, to_char(n.mobile_modify_time, 'yyyy-mm-dd hh24:mi:ss') 退订时间 from new_wireless_subscription n, opt_code o, mobilenodist m where n.appcode = o.appcode and substr(n.mobile_sn, 1, ...
true
c5761defe39e89fcffe3818623022027a55bcc1b
SQL
Martin1987/myTestCode
/Pro_Oracle_SQL/chapter09_scripts/Listing_9_24.sql
UTF-8
777
2.890625
3
[]
no_license
PROMPT PROMPT Execution plan - ACYCLIC FAST PROMPT col product format A30 col country format A10 col region format A10 col year format 9999 col week format 99 col sale format 999999.99 col receipts format 999999.99 set lines 120 pages 100 select distinct product, country, year,week, sale_f...
true
938ca006fd5a1188ab9c8403e76a2169ebd35b89
SQL
ktroka17/ZIP
/Software Code/db/web18_spinari17.sql
UTF-8
16,467
2.828125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.4 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Jun 24, 2020 at 12:00 AM -- Server version: 5.5.62-0ubuntu0.14.04.1 -- PHP Version: 7.2.15-1+ubuntu14.04.1+deb.sury.org+1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET t...
true
add1e6771a18747dfa54c8834f9b545bd7d089ca
SQL
HuzarO/C4-Datapack
/sql/merchant_lease.sql
UTF-8
279
2.578125
3
[]
no_license
CREATE TABLE IF NOT EXISTS `merchant_lease` ( `merchant_id` INT(11) NOT NULL DEFAULT 0, `player_id` INT(11) NOT NULL DEFAULT 0, `bid` INT(11), `type` INT(11) NOT NULL DEFAULT 0, `player_name` VARCHAR(35), PRIMARY KEY (`merchant_id`, `player_id`, `type`) );
true
6eff8ea69596b5ca115367f68a23136ac68f5036
SQL
dogcalas/cursoframework
/saue/lib/ZendExt/WF/WFExecute/lib/workflow/WorkflowDatabaseTiein/design/schema_mysql.sql
UTF-8
2,572
3.6875
4
[]
no_license
DROP TABLE IF EXISTS workflow; CREATE TABLE workflow ( workflow_id INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, workflow_name VARCHAR(32) NOT NULL, workflow_version INTEGER UNSIGNED NOT NULL DEFAULT 1, workflow_created INTEGER N...
true
1757b3824db3a7e2197dd285339135fb2c067bfe
SQL
mahesh3141/ForientSystemServer
/dbs/2018-03-01/db.sql
UTF-8
5,963
3.234375
3
[]
no_license
/* SQLyog Community v12.4.3 (64 bit) MySQL - 5.7.21-0ubuntu0.16.04.1 : Database - corephpadmin ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET ...
true
5bec31f307a49935f1a48291c8ed91ff8b328a3d
SQL
jkstill/index-compare
/ct-idx-count.sql
UTF-8
141
2.9375
3
[]
no_license
select count(*) from dba_indexes where owner in ( select username from dba_users where default_tablespace not in ('SYSTEM','SYSAUX') ) /
true
a655839f7df0a07ac2b7a358a5d2b18cea6d0177
SQL
sunsu18/testSvnSync
/SOA/trunk/SQL_SCRIPTS/Tables/ENGAGE_SOA_CARDGROUP_ERRORLOG.sql
UTF-8
1,579
3
3
[]
no_license
CREATE TABLE "SOACUSTOM"."ENGAGE_SOA_CARDGROUP_ERRORLOG" ( "DELTA_TS" TIMESTAMP (6) NOT NULL ENABLE, "PARTNER_ID" VARCHAR2(20 BYTE), "F_FORHOLD_HTP" VARCHAR2(20 BYTE), "F_FORHOLD_UTP" VARCHAR2(20 BYTE), "F_FORHOLD_LNR" VARCHAR2(20 BYTE), "KONTO_ID" VARCHAR2(20 BYTE), "F_FORHOLD_TX" VARCHAR2(50 BYTE),...
true
5cf8b8492e5bc14335c84015e5e87b5a0f0bf0d1
SQL
targerr/distributed-lock
/distribute-demo/doc/distribute.sql
UTF-8
3,754
3.421875
3
[]
no_license
/* Navicat Premium Data Transfer Source Server : localhost Source Server Type : MySQL Source Server Version : 50731 Source Host : localhost:3306 Source Schema : distribute Target Server Type : MySQL Target Server Version : 50731 File Encoding : 65001 Date: 06/03/2021...
true
c7acb5aeed2d540f46341c07c9130bd1a69a2860
SQL
RaviHindocha/tpc-di_benchmark
/dags/queries/incremental/resync_dim_account_with_new_customer_sk.sql
UTF-8
2,642
3.625
4
[]
no_license
MERGE INTO master.dim_account old USING ( WITH data AS (SELECT n.SK_CustomerID as new_sk, n.Status AS CustomerStatus, a.SK_AccountID, a.AccountID, ...
true
92852ecf3c626171fd99bf44678d757bc49ea266
SQL
tugloo1/database-learning
/course3/week3/lab1.sql
UTF-8
912
4.21875
4
[]
no_license
-- Write a script that creates a stored procedure named test. -- This stored procedure should declare a variable and set it to the count of all products in the Products table. -- The procedure should return a 1 row, 1 column result set with a column named result. -- If the count is greater than or equal to 7, the st...
true
5a3da1c04717010c3089bb727a6c461c36ae145c
SQL
thanq/Thanq-s-Note
/DATABASE/sybase/some.sql
UTF-8
254
3.078125
3
[]
no_license
select top 5 * from ... getdate() /* 当前时间戳*/ isnull(xxx, 'null ! ') RANK() OVER(PARTITION BY b.PCODE ORDER BY b.CODESEQ) as SORT power(10.0000,4-8) datediff(day, (substring('20110930',1,4)+'0101'),'20110930')+1 aa , trim(' xxx ')
true
5c8af48590efcdc82aa07ee12bc85a33c61c8d5d
SQL
ptrumpy/Sample-SQL-Code
/Size_Order from Flex.sql
UTF-8
641
3.4375
3
[]
no_license
SELECT [PackNumber] ,B.ColorwayName ,[SizeDesc] ,[PLN] ,[PLNLongDesc] ,[SC] ,[SCDesc] --,A.[ID] ,C.SortOrder FROM PPMRK_Flex.dbo.tbl_product Prod inner Join (PPMRK_Flex.dbo.[tbl_PLNSCMap] A ...
true
1fbc6e33c891ace0ffa429e951626317e4a1224f
SQL
aditya10n/fe_test
/db/nibble_front_end_test.sql
UTF-8
2,571
3.203125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 09, 2020 at 06:48 AM -- 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
e1cd0aefb6d846a9f1491c09a222e194ee91aac5
SQL
GaryStanton/BugLogHQ
/install/migration/1_6_to_1_7/pg.sql
UTF-8
332
2.796875
3
[ "Apache-2.0" ]
permissive
-- -- Table structure for table `bl_ExtensionLog` -- DROP TABLE IF EXISTS bl_extensionlog; CREATE TABLE bl_extensionlog ( extensionLogID SERIAL, extensionID INTEGER NOT NULL, createdOn TIMESTAMP NOT NULL DEFAULT now(), entryID INTEGER NOT NULL, CONSTRAINT bl_ExtensionLog_pkey PRIMARY KEY (extensionLo...
true
3e2170afabeef5dd225e111c8fda7370ba72d1d6
SQL
tomekzaw/agh_sem5_bd
/lab1_oracle/9_rezerwacje_before_update.sql
UTF-8
663
2.9375
3
[]
no_license
CREATE OR REPLACE TRIGGER rezerwacje_before_update BEFORE UPDATE ON rezerwacje FOR EACH ROW BEGIN IF :OLD.status != :NEW.status THEN IF :OLD.status = 'A' AND :NEW.status != 'A' THEN sprawdz_czy_jest_wolne_miejsce_2(:NEW.id_wycieczki); UPDATE wycieczki SET liczba_woln...
true
415762548d031ef6c4defeef1bd71df87c749a13
SQL
jasonlearn/SQL
/Project/Part D/SQLQuery8.sql
UTF-8
169
2.921875
3
[]
no_license
-- Term Project PartD.D8 CREATE PROCEDURE sp_del_inactive_cust AS DELETE c FROM Customers c LEFT JOIN Orders o ON c.CustomerID = o.CustomerID WHERE o.CustomerID IS NULL
true
39a398eb512863fe33c6ff7fc059f2cbe0d2f37d
SQL
uverus2/Quotes-API-Slim3
/quotes.sql
UTF-8
2,119
3.21875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.7 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 01, 2019 at 06:12 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
d40a0ed6e6917f30f65b91edd3d4566af22e95f1
SQL
pgmasters/expresspg
/sample/script/sample_table.sql
UTF-8
1,319
3.53125
4
[ "MIT" ]
permissive
-- Create a sample schema create schema sample; -- reset role; -- Create a sample table create table sample.master ( id bigint, name text not null, description text, constraint mst_pk primary key (id) ); do $$ begin perform _build.object_name_exception('sample', 'mst_pk'); perform _build.his...
true
842c35dd51b6d97eed94510f8b56695806dbd7b1
SQL
devcavalcante/my-way
/bootcamp-igti-de/modulo_1/dump/dump/livraria_area_conhecimento.sql
UTF-8
2,506
2.953125
3
[]
no_license
CREATE DATABASE IF NOT EXISTS `livraria` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci */ /*!80016 DEFAULT ENCRYPTION='N' */; USE `livraria`; -- MySQL dump 10.13 Distrib 8.0.25, for Win64 (x86_64) -- -- Host: localhost Database: livraria -- ------------------------------------------------------...
true
4dcc37f0069fb1aa514718d25e9fbfa6a6af139e
SQL
simpson12013/mySQL-Database-Manipulations
/sakila.sql
UTF-8
9,465
4.40625
4
[]
no_license
-- ## Homework Assignment -- * 1a. Display the first and last names of all actors from the table `actor`. SELECT first_name, last_name FROM actor; -- * 1b. Display the first and last name of each actor in a single column in upper case letters. Name the column `Actor Name`. SELECT CONCAT(first_name, ' ', last_name)...
true
78cc13ab52c796322454c6797754ec53ffb9cc82
SQL
kvnneff/nestbox
/src/server/db/queries/setup.sql
UTF-8
4,470
3.234375
3
[]
no_license
-- -- PostgreSQL database dump -- -- Dumped from database version 9.5.0 -- Dumped by pg_dump version 9.5.0 SET statement_timeout = 0; SET lock_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; SET check_function_bodies = false; SET client_min_messages = warning; SET row_security = off; ...
true
8a7a5bfb93007444cb5c618a5c3f6a87942d6d2c
SQL
Nachev/Telerik
/Databases/Homeworks/AdvancedSQL/11.FindManagersWith5Employees.sql
UTF-8
290
4.125
4
[]
no_license
-- Write a SQL query to find all managers that have exactly -- 5 employees. Display their first name and last name. SELECT * FROM TelerikAcademy.dbo.Employees m WHERE ( SELECT COUNT(*) FROM TelerikAcademy.dbo.Employees e WHERE e.ManagerID = m.EmployeeID GROUP BY e.ManagerID ) = 5
true
f25dd5f36cc5452f3f5fbe5dce24ad01cc4cd814
SQL
suhojang/RESTfulAPIforBank
/src/main/resources/db/table_script.sql
UTF-8
48,893
3.34375
3
[]
no_license
CREATE DATABASE IF NOT EXISTS relaydb; USE relaydb; CREATE USER IF NOT EXISTS 'kwic'@'%' IDENTIFIED BY 'kwicDB5539!'; GRANT ALL PRIVILEGES ON relaydb.* TO 'kwic'@'%'; FLUSH PRIVILEGES; /* DROP TABLE relaydb.TBRL_CDCLS; DROP TABLE relaydb.TBRL_CDDTL; DROP TABLE relaydb.TBRL_GRPINF; DROP TABLE relaydb.TBRL_MBRINF; DROP...
true
81f6626f42cdf9ce2828156ec5939588fe50ad2c
SQL
nephewtom/tekams
/sql/conns-with-repeated-url.sql
UTF-8
91
2.53125
3
[]
no_license
select * from conns where url in (select url from conns group by url having count(*) > 1);
true
616a4877920a8bbaf76c8a41c445b5995401f1b5
SQL
liyibo1110/smart-elephant
/database.infos.sql
UTF-8
612
2.71875
3
[]
no_license
CREATE TABLE "public"."database_infos" ( "id" int4 NOT NULL DEFAULT nextval('"public".database_infos_id_seq'::regclass), "name" varchar COLLATE "pg_catalog"."default" NOT NULL, "host" varchar COLLATE "pg_catalog"."default" NOT NULL, "port" varchar COLLATE "pg_catalog"."default" NOT NULL, "username" varchar CO...
true
ae9afb66d133ba47a4f5bfeec98a889cf09743f8
SQL
Light07/Mobile_FrameWork
/EvcMobile/axis20/testhelpers/etown/teacher/teacher_info.sql
UTF-8
183
3
3
[]
no_license
SELECT UserName ,Password ,CenterCode FROM ET_Main..Members INNER JOIN Teachers..Teacher ON Members.MemberId = Teacher.Member_id WHERE MemberId = {member_id}
true
b16c4c55fb3350fb1d5d1214afd6417ff994d9a0
SQL
IDEXX-DataPoint/BatchClient
/DataPointBatchClient/Scripts/MergePrescription.sql
UTF-8
2,594
3.203125
3
[]
no_license
MERGE dbo.Prescription AS target USING (SELECT @Code ,@Description ,@ProviderId ,@ProviderName ,@AdministeredDate ,@Quantity ,@Amount ,@Instructions ,@ClientPimsId ,@PatientPimsId ,@LocationId ,@DpUid ,@PimsId ,@SiteId ,@AgentVersion ,@Action ,@DpCreatedDate ,@DpModifiedD...
true
6511d52087f5ad5f852e07bb9c82426bead92571
SQL
Hvardd/Wayfare
/src/sql/Wayfare.sql
UTF-8
4,951
3.0625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.2 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: 26. Apr, 2019 12:05 PM -- Tjener-versjon: 10.1.34-MariaDB -- PHP Version: 7.2.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_C...
true
20de99975179c292859c0f3801f3feaed43fa91b
SQL
LuizCBX/Projeto_Desktop
/src/bancoDeDados.sql
UTF-8
1,983
3.578125
4
[]
no_license
create database db_clinica; use db_clinica; create table tb_usuario( id int auto_increment primary key, usuario varchar (50) not null, foneUsuario varchar (20), login varchar(20) not null unique, senha varchar(200) not null ); insert into tb_usuario (id, usuario, foneUsuario, login, senha) values (1, 'Administrador...
true
b56c29b8daa99a6606edc4a6a2551b48f7fe78e0
SQL
ninodafonte/czstr.link
/prisma/migrations/20210709153322_add_user_table/migration.sql
UTF-8
611
3.765625
4
[ "MIT" ]
permissive
/* Warnings: - Added the required column `userId` to the `Link` table without a default value. This is not possible if the table is not empty. */ -- AlterTable ALTER TABLE "Link" ADD COLUMN "userId" INTEGER NOT NULL; -- CreateTable CREATE TABLE "User" ( "id" SERIAL NOT NULL, "email" TEXT NOT NULL, ...
true
ae21e518c7606759f4551fa5df930fa85b1b07f5
SQL
Pushpendra9350/Device-Inventory-management-system-PHP
/dims_db.sql
UTF-8
4,105
3.328125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3307 -- Generation Time: Aug 22, 2020 at 07:06 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_...
true
a5cf4ea1e161edde992b5c3e6261a94639756429
SQL
vkozjak/arewefastyet
/sql/vitess-benchmark.sql
UTF-8
6,988
3.125
3
[ "Apache-2.0" ]
permissive
/* * * Copyright 2021 The Vitess Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or...
true
216c15d170d1d6a4cc69ce66b2acc9c34898a8f3
SQL
collaborist/CS50-Web-Programming
/Database/flights.sql
UTF-8
1,088
3.546875
4
[]
no_license
/* Команда в psql для смены кодировки: psql \! chcp 1251 Просмотр всех сущностей в таблице psql \d set DATABASE_URL = URI of my db set FLASK_DEBUG = 1 // run debug mode set FLASK_APP=application.py */ CREATE TABLE flights ( id SERIAL PRIMARY KEY, origin VARCHAR NOT NULL, destination VARCHAR NO...
true
4db2bfc24c89b87dc26a65c0452eb81eed028446
SQL
Rodriguit/dpa_equipo2
/Scripts/sql/FeatureEngineering/Paso31_etiqueta.sql
UTF-8
584
2.78125
3
[]
no_license
/*Paso 31: Generacion de etiquetas y Limpieza*/ DROP TABLE IF EXISTS TRANSFORM.NWFINAL; CREATE TABLE TRANSFORM.NWFINAL AS SELECT FECHA, DAY_SEM, ID_OPERADOR, ID_AVION, NUM_VUELO, ORIGEN, DESTINO, HORASALIDAF, SALIDA_REALF, TIEMPO_TRANS_VUELO, DISTANCIA_MILLAS, HORA_LLEGADA_PROGF, DELAY2, BANDERA_DELAY, RANK_CONTADOR AS...
true
681bc14d46193a1486a125a01bd1506ab141a6b3
SQL
alexcr-telecom/sirena2
/alarm_journal.sql
UTF-8
1,553
2.71875
3
[]
no_license
-- MySQL dump 10.11 -- -- Host: localhost Database: asterisk -- ------------------------------------------------------ -- Server version 5.0.95 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION...
true
37277bbfa6f9d8e520bff95fa669c2feb97b5378
SQL
imnurdin173/Mabi-Inventory-App
/assets/database/inventory v0.3.sql
UTF-8
3,455
3.1875
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.4.14 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Jun 21, 2017 at 12:20 PM -- Server version: 5.6.26 -- PHP Version: 5.6.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;...
true
b1435ecb5db5bf9f666343518fe4ed1c9af8220a
SQL
carolfly86/altar
/sql/golden_record/polling_etl/polling_etl_ws2_gr.sql
UTF-8
1,839
3
3
[]
no_license
-- -- PostgreSQL database dump -- SET statement_timeout = 0; SET lock_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; SET check_function_bodies = false; SET client_min_messages = warning; SET search_path = public, pg_catalog; SET default_tablespace = ''; SET default_with_oids = fals...
true
bff0b2417457fa38685a3868523796102dfc3631
SQL
berenar/McFat
/BDII43212796/_arxius_pràctica/event.sql
UTF-8
453
3.34375
3
[ "Apache-2.0" ]
permissive
DELIMITER | CREATE EVENT COMANDA_A_HISTORIC ON SCHEDULE EVERY 60 SECOND DO BEGIN INSERT INTO HISTORIC (data,estat,targeta,id_comanda,id_restaurant,total,pagat) SELECT CURRENT_DATE(),estat,targeta,id_comanda,id_restaurant,total,pagat FROM COMANDA WHERE PAGAT='0'; DELETE QUANTITAT FROM QUANTITAT INNER JOIN COM...
true
666dbaf87ab4b6443d49091775b6d71862a6dd60
SQL
McxmCxmcX/MySQL
/sql/day1.sql
UTF-8
528
3.375
3
[]
no_license
SHOW DATABASES; -- 单行注释 --空格 一段注释 ctrl 斜杠 -- 多行注释 星号 斜杠 -- Ctrl + Enter = 运行 CREATE DATABASE db_1702; USE db_1702; DROP DATABASE db_1702; -- USE db_1702; SHOW TABLES; CREATE TABLE t_student ( sno VARCHAR(10), -- variable character 可变长字符类型 sname VARCHAR(10),-- 属性 列 字段 column/列 gender CHAR(1), age I...
true
b6e5452b42ed9f7fc08503f0d8689078bb0b4cab
SQL
vishalbelsare/mimir
/test/sanity/simple/TABLE06.SQL
UTF-8
78
3.03125
3
[ "Apache-2.0" ]
permissive
SELECT R.A, S.C FROM R, S WHERE (R.B = S.B) AND ((R.A > S.C) or (R.A < S.C));
true
908718041c44dce7c5e16bb902ee4d623cc3b1fb
SQL
StefanosPoulidis/Software-Engineering
/src/src/main/sql/myDB.sql
UTF-8
3,887
3.5
4
[]
no_license
-- MySQL Script generated by MySQL Workbench -- Thu Jan 10 23:26:26 2019 -- 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
176589b3d1c9cc4226978cf2e22a3f8c03ed3c31
SQL
CRayFish07/EquipDistributionMS
/equipdistribution.sql
UTF-8
12,774
3.171875
3
[]
no_license
/* MySQL Data Transfer Source Host: localhost Source Database: equipdistribution Target Host: localhost Target Database: equipdistribution Date: 2017/5/3 23:04:47 */ SET FOREIGN_KEY_CHECKS=0; -- ---------------------------- -- Table structure for jfzs_board_card_manage -- ---------------------------- DROP...
true
0173b34f75785ebaa61e30164a2a4f0c584f39b9
SQL
wagnercorreiasenai/ativida5PosBigData
/carga_dados.sql
UTF-8
6,835
2.546875
3
[]
no_license
--Inserções na tabela usuário INSERT INTO usuario (username,nome,email,telefone) VALUES ('user1', 'Usuario1', 'usuario1@mail.com', '111-111'); INSERT INTO usuario (username,nome,email,telefone) VALUES ('user2', 'Usuario2', 'usuario2@mail.com', '222-111'); INSERT INTO usuario (username,nome,email,telefone) VALUES ('user...
true
6bd8058ad372dcc8036234f4246823cad9836804
SQL
mwiguna/Sistem-Manajemen-Proyek
/laravel_simapro.sql
UTF-8
27,298
2.765625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.0 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: May 10, 2018 at 02:42 PM -- Server version: 10.1.31-MariaDB -- PHP Version: 7.0.29 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
4dd9d119e09df4fde351d6232956b6e3a651705a
SQL
phively/ksm-models
/ar-prospecting-fy20/code/SQL data - initial interest groups.sql
UTF-8
14,626
2.859375
3
[]
no_license
With params As ( Select 2018 As prev_year , 2010 As committee_year , 2015 As giving_year From DUAL ) , profiles As ( Select id_number , Case When id_number In ('0000289909', '0000328657', '0000422285', '0000442251', '0000472484', '0000468514', '0000500947', '0000501039', '0000532191'...
true
e12456c980b978dfc91a16e3fd83807cfe8d2b4f
SQL
ikebi3/JV94
/sampledata/langtest3.sql
UTF-8
1,311
3.125
3
[]
no_license
DROP DATABASE IF EXISTS langtest; CREATE DATABASE langtest; use langtest; CREATE TABLE t( id int PRIMARY KEY AUTO_INCREMENT, lang VARCHAR(10) CHARACTER SET latin1, chara VARCHAR(10) CHARACTER SET utf16, utf8 VARCHAR(3) CHARACTER SET utf8, ucs2 VARCHAR(3) CHARACTER SET ucs2, sjis VARCHAR(3) CHARACTER SET sjis, c...
true
79e02941d81ba012faf622ea8536372345eceaa1
SQL
akbars95/souvenir_project
/src/main/resources/db/stored_procedure/checkCaptcha.sql
UTF-8
303
2.828125
3
[]
no_license
DROP PROCEDURE IF EXISTS souvenir.checkCaptcha; DELIMITER $$ CREATE DEFINER=`souvenir`@`localhost` PROCEDURE `checkCaptcha`(IN captcha_idIN INT(11), IN captcha_valueIN VARCHAR(10)) BEGIN SELECT * FROM CAPTCHA c WHERE c.captcha_id = captcha_idIN AND c.captcha_value = captcha_valueIN; END$$ DELIMITER ;
true
d9c12fa4db3a33fc09a361989e196e0a99c386ba
SQL
itlj/RentSystem
/RentSystem/bin/main/test-data.sql
UTF-8
1,280
2.53125
3
[]
no_license
insert into student (name,password,phoneNumber,address,brithday,sex) values ('张三', '8888', '13333333333', '华侨大学','1997-9-25','男'); insert into student (name,password,phoneNumber,address,brithday,sex) values ('李四', '8888', '14444444444', '华侨大学','1997-9-25','男'); insert into master (name,password,phoneNumber,address) va...
true
b09a1e44729915699f0611e656219cb1e0ccf2e2
SQL
HadziabdicMidhat/hadziabdic_sales1
/database/TRG_CUSTOMER.sql
UTF-8
502
3.15625
3
[]
no_license
create or replace trigger TRG_CUSTOMER BEFORE INSERT OR UPDATE ON CUSTOMER REFERENCING NEW as newROW OLD AS oldROW FOR EACH ROW DECLARE BEGIN IF (:newROW.CREDIT < :newROW.CREDIT) THEN raise_application_error (-20999, 'The balance ' || :newROW.CREDIT || ' is over the credit limit ' || :newROW.CREDIT); END IF; ...
true
e4c691328fb95caea50d0a52b07a1b1920059fcc
SQL
dehscardoso/SQL
/Scripts/05 Adicionando Chaves.sql
UTF-8
418
2.625
3
[]
no_license
-- Alterando a tabela já criada e adicionando chave primária ALTER TABLE [TABELA DE PRODUTOS] ALTER COLUMN [CODIGO DO PRODUTO] VARCHAR (20) NOT NULL ALTER TABLE [TABELA DE PRODUTOS] ADD CONSTRAINT PK TABELA DE PRODUTOS PRIMARY KEY CLUSTERED ([CODIGO DO PRODUTO]) -- ALTER TABLE [TABELA DE VENDEDORES] ADD CONSTRAINT...
true
6f6a95b3a7329e169cfe2c679880bac18aa9036e
SQL
lshappylife/snippet-manager
/snippets/join-table.sql
UTF-8
220
3
3
[ "MIT" ]
permissive
USE as_vehicle; SELECT DISTINCT xxx FROM table_xxx INNER JOIN table_yyy ON (table_xxx.id = table_yyy.prod_id) WHERE some_id = 'XY' AND table_xxx.opq LIKE '闽AW' AND table_yyy.uvw IS NOT NULL; LIMIT 1;
true
b39bd6f845b53743103e7269debb7af6ab7892d6
SQL
cesarchs/BD1_P1_2S21_201700634
/PROYECTO 1 BASES1/BD1 entregable P1/SCRIPS/[BD1]Reportería_201700634.sql
WINDOWS-1252
32,327
4.5625
5
[]
no_license
-- CONSULTAS /* CONSULTA#1 Mostrar la cantidad de copias que existen en el inventario para la pelcula Sugar Wonka. */ SELECT COUNT (*) AS COPIAS_PELICULA FROM TIENDA_PELICULA WHERE TIENDA_PELICULA.fk_id_pelicula IN ( SELECT pelicula.id_pelicula FROM PELICULA WHERE pelicula.nombre_pelicul...
true
3fb88568f85a4a89aa693040e358d8c94da5a0ab
SQL
psnd2018-team-n/lab_assistant
/lab_assistant_api/ddl/lab_assistant.ddl.sql
UTF-8
12,161
3.390625
3
[]
no_license
-- MySQL Script generated by MySQL Workbench -- Sun Mar 17 22:39:19 2019 -- 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
b519eed13026e5ab00f435e80e1e498ab37e92ea
SQL
sangmin9412/sql-study
/source/0608/2020-06-08.sql
UHC
15,195
3.984375
4
[]
no_license
INSERT INTO employees VALUES ((select max(employee_id)+1 from employees), 'Den', 'Raphealy', 'DRAPHEAL', '515.127.4561', TO_DATE('6 8, 2020', 'MON DD, YYYY'), 'AC_ACCOUNT', 11000, NULL, 100, 30); INSERT INTO employees VALUES ((select max(employee_id)+1 f...
true
55470d5b0d960e1d0ab45147b34d87d3d47f2a37
SQL
filip99m/aliexpress
/aliexpress.sql
UTF-8
4,383
2.734375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jul 02, 2021 at 06:00 PM -- Server version: 10.4.17-MariaDB -- PHP Version: 8.0.0 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIEN...
true
709fa4447fe085e1c9e56c9682a2b67ef3cc5e79
SQL
jroof88/GreenfieldRMS
/sql/init/tableCreation.sql
UTF-8
2,203
3.953125
4
[]
no_license
/* Table Creation */ DROP TABLE Lease_Agreement; DROP TABLE Renter; DROP TABLE Rental_Property; DROP TABLE Employee; DROP TABLE Branch; DROP TABLE Owner; CREATE TABLE Branch ( branchNo VARCHAR(5) PRIMARY KEY NOT NULL, phoneNo VARCHAR(10) NOT NULL, address_street VARCHAR(30) NOT NULL, address_city VARCHAR(30) NOT ...
true
82e07f6ecb4968f5d5f8bfc7ec9aa4345f440693
SQL
ternoffice/TERNDataDeliveryPortal
/tern-portal/sql/regions/index_scheduler.sql
UTF-8
3,444
3.59375
4
[]
no_license
-- -- PostgreSQL database dump -- SET statement_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; SET check_function_bodies = false; SET client_min_messages = warning; SET search_path = public, pg_catalog; SET default_tablespace = ''; SET default_with_oids = false; ...
true
1a283b792597155911a70f1834c6e2ed5e88eb8d
SQL
ninh-tomosia/luli-shop
/doan.sql
UTF-8
24,983
3.1875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Máy chủ: 127.0.0.1 -- Thời gian đã tạo: Th7 12, 2020 lúc 12:54 PM -- Phiên bản máy phục vụ: 10.4.11-MariaDB -- Phiên bản PHP: 7.4.6 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARA...
true
e22968ac656176b6bfcb5bc768eb3d341cd0e364
SQL
smokeyfeet/smokeyfeet-registration
/reports_sql/2017/sf_registered_full.sql
UTF-8
660
3.375
3
[ "MIT" ]
permissive
copy ( select r.first_name, r.last_name, r.email, r.residing_country, r.dance_role, pt.type as pass_type, pt.name as pass_name, r.workshop_partner_name, r.workshop_partner_email, lt.name as lunch_type, crew_remarks from registration_registration r left join registration_p...
true
af41ee46378c980bcb8646dae733694b077bff73
SQL
gallu/CareerCollege
/htdocs/bak_2020/PHP_beginner_course/db_2/data.sql
UTF-8
1,094
3.46875
3
[]
no_license
-- 「テーブルがもし存在していたらテーブルを破棄する」というSQLです。なくてもよいのですが、個人的には書いておくことが多いです DROP TABLE IF EXISTS test_form; -- 実際のテーブルを作成します CREATE TABLE test_form ( `test_form_id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT '識別するためのID', -- `name` varchar(128) NOT NULL COMMENT '入力値:名前', `post` varchar(8) NOT NULL COMMENT '入力値:郵便番号(...
true
fda4e31d6e8adaf7cf82f55bdbd855dad014ffc6
SQL
xmidt-org/codex-deploy
/deploy/docker-compose/docFiles/create_db.cql
UTF-8
1,022
3.578125
4
[ "Apache-2.0" ]
permissive
CREATE KEYSPACE IF NOT EXISTS devices; CREATE TABLE devices.events (device_id varchar, record_type INT, birthdate BIGINT, deathdate BIGINT, data BLOB, nonce BLOB, alg VARCHAR, kid VARCHAR, row_id TIMEUUID, PRIMARY KEY (device_id, birthdate, record_type)) WITH CLUSTERING ORDER BY...
true
37a0ae28c844684abb42fee783a475fe6939751e
SQL
Xinxin0407/GoDrive
/dbsetup/tbl_userfile.sql
UTF-8
872
3.578125
4
[]
no_license
CREATE TABLE `tbl_userfile` ( `id` int(11) NOT NULL PRIMARY KEY AUTO_INCREMENT, `username` varchar(64) NOT NULL, `hash` varchar(64) NOT NULL DEFAULT '' COMMENT 'hash', `size` bigint(20) DEFAULT '0' COMMENT 'file size', `filename` varchar(256) NOT NULL DEFAULT '' COMMENT 'filename', `upload_at` datetime DEFA...
true
3af90997d74ffd01c31e406014bab120bad75b35
SQL
joshuadanielp/09_SQL_HW
/EmployeeSQL/EmployeeSQL.sql
UTF-8
3,063
4.8125
5
[]
no_license
-- Create a Departments table CREATE TABLE departments ( dept_no VARCHAR(30) NOT NULL, dept_name VARCHAR(30) NOT NULL ); SELECT * FROM departments -- Create a Dept_Emp table CREATE TABLE dept_emp ( emp_no INT NOT NULL, dept_no VARCHAR(30) NOT NULL ); -- Create a Dept_Manager table CREATE TABLE dept_manager (...
true
fa5f380874ce2ba19c07cff8a74909f4a845543a
SQL
ytatus94/Leetcode
/SQL/0610_Triangle_Judgement.sql
UTF-8
187
3.1875
3
[]
no_license
-- 三角形的兩邊之和要大於第三邊 SELECT x, y, z, CASE WHEN x+y > z AND y+z > x AND x+z > y THEN 'Yes' ELSE 'No' END AS 'triangle' FROM triangle;
true
7f90c5976dc2f9f96172569cf74c92c46f2903be
SQL
lorand024/Lorand-Kovacs-FSWD30-CodeReview11
/cr11_lorand_kovacs_php_car_rental.sql
UTF-8
2,037
3.15625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Feb 17, 2018 at 04:27 PM -- Server version: 10.1.30-MariaDB -- PHP Version: 7.2.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true