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
575c6e63e6ae28b10c6b724b3e6f28cdaf251a88
SQL
disvenk/kaa
/kaa_sql/mysql/2-procFuncView/trigger.sql
UTF-8
10,216
3.078125
3
[]
no_license
/******************************************************************************************** * 项目名称: 触发器 * 创建日期: 2014-10-23 09:42:00 * 创建人员: wang.h * 文件说明:本文件用于创建系统所需的触发器。 * 所有触发器都以 t 开头,后跟类型。 ********************************************************************************************* * 系统—ts ***********...
true
ede7f0ca6cb2b6f68eb8ecc6f7ba0b91ee50c8bc
SQL
dongzhiyong-coder/auth
/mcharge.sql
UTF-8
4,661
3.234375
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : local Source Server Version : 50726 Source Host : localhost:3306 Source Database : mcharge Target Server Type : MYSQL Target Server Version : 50726 File Encoding : 65001 Date: 2020-06-10 17:34:37 */ SET FOREIGN_KEY_CHECKS=0; -- -----...
true
c9c9ce0e38774d7de943a1045b8768cc5d322023
SQL
chrischrisjackson/StateStreetTransformations3
/ddl/Snowpipe/pipe/PORTFOLIONODE_PIPE.sql
UTF-8
1,113
2.578125
3
[]
no_license
USE ROLE SS_DBA; CREATE OR REPLACE PIPE SS_DEV.RAW.PORTFOLIONODE_PIPE AUTO_INGEST = TRUE INTEGRATION = 'STATESTREET_INTEGRATION' AS COPY INTO PORTFOLIONODE ( SPONSOR_ID, ENTITY_CODE, ENTITY_SHORT_NAME, EFFECTIVE_DATE, CLSSFN_HIER_SCHM_ID, CLSSFN_HIER_SCHM_NM, CLSSFN_HIER_LVL2_NM, ...
true
13aa9573f144ead8c56c3d5de908334074acd137
SQL
49038554/Buddy
/Server/DataLayer/sql/Auth.sql
UTF-8
1,029
3.21875
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : localhost_3306 Source Server Version : 50150 Source Host : localhost:3306 Source Database : auth Target Server Type : MYSQL Target Server Version : 50150 File Encoding : 65001 Date: 2016-05-04 22:35:58 */ SET FOREIGN_KEY_CHECKS=0; --...
true
4bff87dc06c72da352690ed39f8c3d34d34f6e5b
SQL
amj133/bird-tracker
/birdy/schema.sql
UTF-8
556
3.046875
3
[]
no_license
DROP TABLE IF EXISTS birdy_user; DROP TABLE IF EXISTS bird; DROP TABLE IF EXISTS user_birds; CREATE TABLE birdy_user ( id SERIAL PRIMARY KEY, latitude TEXT NOT NULL, longitude TEXT NOT NULL, notify TEXT NOT NULL, username TEXT UNIQUE NOT NULL, email TEXT UNIQUE NOT NULL, password TEXT NOT NULL ); CREATE...
true
abce9cd414ac75fc663e47fcf22015f4d0d36f6d
SQL
azrihafiz-aziz/ci_fone
/db_pengguna.sql
UTF-8
2,101
3.015625
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 5.0.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jul 13, 2021 at 03:02 AM -- Server version: 10.4.14-MariaDB -- PHP Version: 7.2.34 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
true
12e58ea628487551da2a0bcf72f0f7599d453a81
SQL
ulivegenov/MS-SQL-Server
/06.Subqueries-and-JOINs/Exercise/Joins-Subqueries-CTE-and-Indices-solves.sql
UTF-8
7,803
4.65625
5
[]
no_license
/* 01.Employee Address */ SELECT TOP(5) e.EmployeeID, e.JobTitle, e.AddressID, a.AddressText FROM Employees AS e JOIN Addresses AS a ON e.AddressID = a.AddressID ORDER BY a.AddressID /* 02.Addresses with Towns */ SELECT TOP(50) e.FirstName, e.LastName, t.[Name] AS Town, a.AddressText ...
true
0f8f4c0c62eba7e6c6b40a3e67be74e4618eed05
SQL
Christophenkoa/Compte_Presence_Etudiant
/Create BD.sql
UTF-8
1,222
3.59375
4
[]
no_license
CREATE DATABASE controle-horaire; CREATE TABLE Etudiant ( idEtudiant SMALLINT NOT NULL AUTO_INCREMENT PRIMARY KEY, nom VARCHAR(255) NOT NULL, prenom VARCHAR(255) NOT NULL, sexe CHAR(1) NOT NULL CHECK (sexe IN('M', 'F')), telephone BIGINT UNIQUE NOT NULL )ENGINE=INNODB; CREATE TABLE Semestre ( ...
true
ab63162c8ee503a1bf55e328f6b38d6659c8ff9a
SQL
lorvei/Aj-nlatk-r-s
/kmajanlatkeres(1).sql
UTF-8
3,093
3.25
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.2.6deb1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: May 12, 2015 at 12:07 PM -- Server version: 5.5.43-0ubuntu0.14.10.1 -- PHP Version: 5.5.12-2ubuntu4.4 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CL...
true
29cc1603f04d708ad0062505b0d78eb984369e30
SQL
captain0317/jikexueyuan
/node百度V2/nodebaidu/public/baidunews.sql
UTF-8
2,044
3.171875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: 2017-12-16 12:02:36 -- 服务器版本: 10.1.19-MariaDB -- PHP Version: 5.6.28 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40...
true
ad9ac672c81c33bdddbf4f25eea25b36d2a4638c
SQL
ioanavitomireanu09/Jury-Duty
/Database/db/jury_contest.sql
UTF-8
2,517
3.03125
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.16, for Win64 (x86_64) -- -- Host: localhost Database: jury -- ------------------------------------------------------ -- Server version 8.0.16 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;...
true
6b5a2f75a81360f5d28df8fa086846ddad6ceee8
SQL
manelfg24/RekindleBackend
/src/test/resources/database-init/creation.sql
UTF-8
3,861
3.640625
4
[]
no_license
/* * Resources local: spring.datasource.url=jdbc:mysql://localhost:3306/local_rekindle spring.datasource.username=alumne spring.datasource.password=rekindle * Resources server: spring.datasource.url=jdbc:mysql://10.4.41.149:3306/PES spring.datasource.username=aplicacion spring.datasource.password=rekindle */...
true
3822eb9a498425b7cdb884f2658630379ab5efb7
SQL
lucaburatti7/A00-Training-plan
/讲义_旧版/ZLJPj/DEV_FOLDER/SERVER/SQL文/D691SFM_TBL.Sql
SHIFT_JIS
2,370
3.296875
3
[]
no_license
prompt PL/SQL Developer import file prompt Created on 2004N827 by ren_dali set feedback off set define off prompt Dropping D691SFM_TBL... drop table D691SFM_TBL cascade constraints; prompt Creating D691SFM_TBL... create table D691SFM_TBL ( ansk_ԍ CHAR(10) not null, anskԍ NUMBER(4) not null, ă[X NU...
true
848d62734991a1e90b466f126d41326a66d97b0d
SQL
1920-3ahitm-itp/02-project-repositories-tournamentmanagement
/sql/create-tables.sql
UTF-8
934
3.4375
3
[]
no_license
create table "Tournament" ( id INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY (START WITH 1, INCREMENT BY 1), name varchar(50), date varchar(30), pointsWin int, pointsDraw int, CONSTRAINT pk_TournamentId PRIMARY KEY (id) ); create table "Phase" ( id INTEGER NOT NULL GENERATED AL...
true
1497a4cafbc7eecec3e6c8ff95902ad1bb9475db
SQL
HenriqueRoncon/LojadeJogos
/dbLojaJogos.sql
UTF-8
1,369
3.09375
3
[]
no_license
CREATE DATABASE bdLojaJogos; USE bdLojaJogos; CREATE TABLE tbFuncionario( FuncionarioID SMALLINT primary key, Nome VARCHAR(150) NOT NULL, CPF VARCHAR(14) NOT NULL, RG VARCHAR(12) NOT NULL, DataNasc DATE NOT NULL, Endereco VARCHAR(150) NOT NULL, Celular VARCHAR(15) NOT NULL, Email VARCHAR(50) NOT NULL, Cargo VARCHAR(5...
true
c2549566f378dd019f615c896c6d832c098125c8
SQL
Thijs1990/htdocs
/backup/test_11-12-2018.sql
UTF-8
1,679
2.953125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Dec 11, 2018 at 05:37 PM -- Server version: 10.1.36-MariaDB -- PHP Version: 7.2.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
e195041dccf53de92ecc4162b826e4dcb798dca7
SQL
kimkyungyeon/LibraryManagement
/Scripts/1.ddl.sql
UTF-8
4,359
3.921875
4
[]
no_license
-- 도서관리 DROP SCHEMA IF EXISTS LibraryManagement; -- 도서관리 CREATE SCHEMA LibraryManagement; -- 대출정보 CREATE TABLE LibraryManagement.rentinfo ( rentno INT(5) NOT NULL COMMENT '대여번호', -- 대여번호 membno INT(5) NOT NULL COMMENT '회원번호', -- 회원번호 bookno INT(5) NOT NULL COMMENT '도서번호', -- 도서번호 rentdate ...
true
d2a09b8cfdddb6ce8496f9e837148f5d756fdd04
SQL
DruxaVoron/EasaprSqlQuerys
/sql/Выгрузка актов ПКО для ручейка.sql
UTF-8
1,029
4.375
4
[]
no_license
--SELECT uhv.AktOfNum, uhv.AktNum, uhv.AktDate, uhv.Station, car.CarriageNum, sends.SendNum SELECT car.CarriageNum, sends.SendNum ,aoc.Cargo ,uhv.StationFrom ,uhv.StationTo ,COUNT( DISTINCT uhv.Station) c_st FROM uhv.dbo.AktOf AS uhv WITH(NOLOCK) INNER JOIN uhv.dbo.AktOfCarriage AS car WITH(NOLOCK) ...
true
641a4cfb00296abc814584074c3f493ea97f1828
SQL
haraphat01/sql
/join.sql
UTF-8
1,071
4.1875
4
[]
no_license
SELECT matchid, player FROM goal WHERE teamid LIKE '%GER' SELECT id,stadium,team1,team2 FROM game WHERE id = 1012 SELECT player, teamid, stadium, mdate FROM game JOIN goal ON (id=matchid) WHERE teamid = 'GER' SELECT team1, team2, player FROM game JOIN goal ON game.id = goal.matchid WHERE goal.p...
true
9a5b6cb235fe43b3b90deb94162490fff13bf4d4
SQL
allwaysoft/DIVERSOS_PROJETOS
/Oracle/09_PRC_GERA_NF.sql
UTF-8
9,647
3.578125
4
[]
no_license
-- ------------------------------------------------------------------------------- -- PRC_GERA_NF -- TABELAS ORIGEM: PED_VENDAS, PED_VENDAS_ITENS, PED_COMPRAS, PED_COMPRAS_ITENS -- TABELAS DESTINO: NOTA_FISCAL, NOTA_FISCAL_ITENS -- PARAMETROS: TIP_NF, DOCTO, CFOP, DATA_EMIS, DATA_ENTREGA -- EXEC PRC_GERA_NF 'S',4,'5.10...
true
d0b509d4d230d9604a91754c9ed616289b2e6584
SQL
NicGagnon/apollo-space-mission
/apollo_space_mission/sql_queries/4.sql
UTF-8
6,706
3.9375
4
[]
no_license
/* Q: By using the GoogleAnalyticsSample data and BackendDataSample tables, analyse how often users tend to change their location in the beginning of their journey (screens like home and listing) versus in checkout and on order placement and demonstrate the the deviation between earlier and later inputs (i...
true
d7d4f3f012cdd2e8830f650ef667f502ed759486
SQL
tpokora/emmy
/emmy-persistance/src/main/database/data.sql
UTF-8
566
3.25
3
[]
no_license
INSERT INTO role(role_id, name) VALUES (1, 'ADMIN'); INSERT INTO role(role_id, name) VALUES (2, 'USER'); ALTER TABLE storm RENAME x TO LONGITUDE; ALTER TABLE storm RENAME y TO LATITUDE; -- Forecast implementation UPDATE forecast SET rain1h = 0.0, rain3h = 0.0 WHERE rain1h IS NULL; -- Add DM coordinates to storm enti...
true
193d4a6c40491b2f67693a39c3d294d96a18088b
SQL
zacharymiller2/databaseManagement
/lab3.sql
UTF-8
628
3.171875
3
[]
no_license
--question 1 select ordno, dollars from orders; --question 2 select name, city from agents where name = 'Smith'; --question 3 select pid, name, priceUSD from products where quantity > 208000; --question 4 select name, city from customers where city = 'Dallas'; --question 5 select name from agents where city not in ('N...
true
4915fcf803975edd49cce8add04e95a85ef216b5
SQL
kachoungho/ProjectBackUp
/WebContent/sql/subjectDB.sql
UHC
12,902
3.890625
4
[]
no_license
--⼭ ڵ ( sub_code .) --EX) COM101 ( ) | --KYO201 ( ) -- com == а ̸ | --KYO == ̶ -- 1 == 1г | --2 == 3 ִ. װͿ ε "1, 2, 3" -- 01 == Index | --01 == Index. --ð ڵ?? ̷ ؼϼ. --EX) MON123 -- 123 ؼ. --ȭ 345ø TUE345 ǥ ϰڽϴ礷? -- 3̱⶧. -- 2̹Ƿ TUE012 -- ...
true
9439de59417fd325461f8d98a514557a89b77301
SQL
kl45699654/Spring-
/src/main/mysql/Script.sql
UTF-8
5,110
3.171875
3
[]
no_license
--<ScriptOptions statementTerminator=";"/> CREATE TABLE account ( id INT NOT NULL AUTO_INCREMENT, name VARCHAR(45), money DECIMAL(10 , 0), PRIMARY KEY (id) ) ENGINE=InnoDB; CREATE TABLE `goods_tbl`( `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT 'ID', `goods_name` VARCHAR(100) NOT NULL COMMENT '商品名称', ...
true
fe3fe4334ba3a116829e2d8e6bf40dc5653088be
SQL
jcmccowan/gitrepo
/growler/db/create_all.sql
UTF-8
6,163
4.5
4
[]
no_license
/* Authors: * created by: * Justin Bauguess on 01/29/13 * * edited by: * Brandon Foster from 02/05/13 * * Purpose: * This script will drop and create every table designed. * * */ /* * Creates the table for storing theme information */ --dropping tables before we create them DROP TABLE theme; ...
true
531b957fbf282177401ff8ad89bcd4821ce17ec2
SQL
abhi10010/Hackerrank-Solutions
/SQL/Aggregation/WeatherObservationStation20.sql
UTF-8
374
3.625
4
[]
no_license
SELECT ROUND(S.LAT_N, 4) FROM station S WHERE (SELECT COUNT(Lat_N) FROM station WHERE Lat_N < S.LAT_N ) = (SELECT COUNT(Lat_N) FROM station WH...
true
aa45abe5899303a3913e946d788a47e40e6b06e0
SQL
tomcruzana/spring-references
/spring-data/7a_hibernate-relationships-onetoone/src/main/resources/db.sql
UTF-8
510
3.703125
4
[]
no_license
create database driver_license_db; use driver_license_db; create table person ( id int primary key auto_increment, fname varchar(30), lname varchar(30), age int ); create table license ( license_number int primary key, person_id int, foreign key (person_id) references person(id) ); insert into pe...
true
7c17cf1e7a9234cb076c75efa6f818a7b8b6bc29
SQL
akrai37/mysql_for_DA_and_BI
/21WHERE_HAVING.sql
UTF-8
255
3.28125
3
[]
no_license
SELECT emp_no, COUNT(emp_no) AS total_contracts FROM dept_emp WHERE from_date > '2000-01-01' GROUP BY emp_no HAVING total_contracts > 1 ORDER BY emp_no; # 'having' cannot have both aggregate and non aggregate functions at once. it is a rule.
true
821e52218aa00c5809f0fee84eac1ed841a10f5c
SQL
girishkg95/DotNetTraining_23456789_GirishKG
/SQL Server/SQLQuery3.sql
UTF-8
240
2.859375
3
[]
no_license
Use Pubs; Select * from Titles; Select * from Publishers; Select * from Titles t INNER JOIN Publishers p ON t.pub_id = p.pub_id; Use Northwind; Select * from Customers c INNER JOIN Orders o ON o.CustomerID = c.CustomerID;
true
04af40a9a181bd7eec97945d55e2936a6ceb8e6a
SQL
moutainhigh/p2p
/sz-yld/front/数据库/数据库结构(零注释)脚本/S63.sql
UTF-8
25,391
3
3
[]
no_license
/* Source Server : 标准库-DEVELOPMENT Source Server Version : 50621 Source Host : Source Database : S63 Target Server Type : MYSQL Target Server Version : 50621 File Encoding : UTF-8 Copyright (c) dimeng.net 2014 Date : 2014-10-11 15:02:37 */ SET FOREIGN_KEY_CHECKS=0; ...
true
a962f742d55f0f35a40a0bd65d81a4bbfc35c56e
SQL
vsaraminev/Databases-Basics-MS-SQL-Server-09.2017
/08.FunctionsAndProcedure/10. People with Balance Higher Than.sql
UTF-8
253
3.375
3
[]
no_license
CREATE PROCEDURE usp_GetHoldersWithBalanceHigherThan(@money MONEY) AS BEGIN SELECT ah.FirstName, ah.LastName FROM AccountHolders AS ah JOIN Accounts AS a ON a.AccountHolderId = ah.Id GROUP BY ah.FirstName, ah.LastName HAVING SUM(a.Balance) > @money END
true
60b849c1d44c9600ed28fa43f26637aa2d6af4a3
SQL
sengeiou/robot-rebate
/jeecg-boot/db/增量SQL/2.2.0升级到2.2.1mysql.sql
UTF-8
5,444
2.609375
3
[ "MIT", "Apache-2.0" ]
permissive
-- ----author:scott--------date:20200602-------for: 字典表字段禁止为空------ ALTER TABLE `sys_dict_item` MODIFY COLUMN `item_text` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '字典项文本' AFTER `dict_id`, MODIFY COLUMN `item_value` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT...
true
15d117e27e86fba9bce8a764d40e5fce90dfccb9
SQL
september98/yxt
/database/wechat/red_packet.sql
UTF-8
976
3.078125
3
[]
no_license
-- -------------------------------------------------------- -- -- 表的结构 `yxt_red_packet` -- 红包活动信息 -- CREATE TABLE IF NOT EXISTS `yxt_red_packet` ( `packet_id` int(11) NOT NULL AUTO_INCREMENT, `packet_type` varchar(25) NOT NULL, `key_word` varchar(25) DEFAULT NULL, `nick_name` char(32) NOT NULL, `send_name` ...
true
5676dae6f78ba56b9cbbf5750256c8e0043b6d90
SQL
UAMS-DBMI/PosdaTools
/posda/posdatools/queries/sql/GetDicomFileForDefacingFromNiftiSlice.sql
UTF-8
369
2.921875
3
[ "Apache-2.0" ]
permissive
-- Name: GetDicomFileForDefacingFromNiftiSlice -- Schema: posda_files -- Columns: ['dicom_file_id'] -- Args: ['nifti_file_id', 'nifti_slice_number'] -- Tags: ['nifti'] -- Description: Get row in file_nifti table from file_id -- select dicom_file_id, nifti_file_id, nifti_slice_number from dicom_slice_nifti_slice w...
true
57cc889c7c90fc1d37d74facc2695428c7581fff
SQL
bryan7zhang/T-SQL_Fundamentals
/BookStore/PART-II/SQLQuery2.sql
UTF-8
340
3.515625
4
[]
no_license
/* Create a new table called 'business_books' containing the title ID, title, price, publisher ID, and publish date columns, as well as the data, from the TITLES table for those rows which are of type 'business'. */ SELECT t.title_id , t.title , t.price , t.pub_id , t.pubdate INTO business_books FROM titles t WHER...
true
d99df947dfdb2d35f04a343f925639da2b837031
SQL
aoi-mitori/2021WEB-final
/dataTable/my_dice.sql
UTF-8
2,862
2.96875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.5 -- https://www.phpmyadmin.net/ -- -- 主機: localhost:3306 -- 產生時間: 2021 年 06 月 15 日 14:50 -- 伺服器版本: 10.3.16-MariaDB -- PHP 版本: 7.3.23 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@...
true
a853759e8d235e1934eb149f8ac5645f16079320
SQL
izoya/sleepme_database
/procedures.sql
UTF-8
3,168
4.125
4
[]
no_license
-- Вставка комментария drop procedure if exists sp_insert_comment; delimiter // CREATE procedure sp_insert_comment ( out `result` VARCHAR(255), in media INT, in parent INT, in author INT, in content TEXT ) begin declare error BIT default 0; declare lvl tinyint unsigned default 0; declare code, e...
true
e4a4a2ad58d9b3a18490923862a910cc48e0a4f5
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/low/day11/select1913.sql
UTF-8
191
2.71875
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerObservation WHERE timestamp>'2017-11-10T19:13:00Z' AND timestamp<'2017-11-11T19:13:00Z' AND SENSOR_ID='a81ff93b_f354_4bf9_a9c5_660b7df289f2'
true
8dec2493d507df267d098bdf89180674fb3d0470
SQL
rvbugs0/loyalty
/ignore this- sql /vendor_outlet/remove_vendor_outlet.sql
UTF-8
213
2.546875
3
[]
no_license
DELIMITER $$ DROP PROCEDURE IF EXISTS `loyalty`.`remove_vendor_outlet`$$ CREATE PROCEDURE `loyalty`.`remove_vendor_outlet` (in v_code int) BEGIN delete from vendor_outlet where code = v_code ; END$$ DELIMITER ;
true
b09487b54cb8a9c848fdf19567f54cd718d3aa9e
SQL
KhandelwalVishal/sample-application
/sample/src/main/resources/data.sql
UTF-8
566
2.78125
3
[]
no_license
DROP TABLE IF EXISTS datasets; CREATE TABLE datasets( id INT AUTO_INCREMENT PRIMARY KEY, quarter INT, stock VARCHAR(25),date VARCHAR(25),open DECIMAL(20,10),high DECIMAL(20,10),low DECIMAL(20,10),close DECIMAL(20,10),volume DECIMAL(20,10) ,percent_change_price DECIMAL(20,10),percent_change_volume_over_last_wk ...
true
4f1586473d2013bce407d8e3b606f8927f9e0b14
SQL
davidbjohnston1/sql-challenge
/EmployeeSQL/queries.sql
UTF-8
2,594
4.5
4
[]
no_license
-- List the following details of each employee: employee number, last name, first name, gender, and salary. SELECT employees.emp_no, employees.last_name, employees.first_name, employees.gender, salaries.salary FROM employees INNER JOIN salaries on employees.emp_no=salaries.emp_no; -- List employees who were hired in...
true
b797271efbb86cef761ddcc2e35e0d6b4da066d2
SQL
ridwanzal/ristek-kalkulator-valuasi-teknologi
/db_step/sikav_database_2020_11_01_alter.sql
UTF-8
18,540
3.140625
3
[ "MIT" ]
permissive
/* MySQL Data Transfer Source Host: localhost Source Database: sikav_database Target Host: localhost Target Database: sikav_database Date: 01/11/2020 21.25.38 */ SET FOREIGN_KEY_CHECKS=0; -- ---------------------------- -- Table structure for sikav_cost -- ---------------------------- DROP TABLE IF EXISTS `sikav_cost`...
true
9e17cfc3028619b6f3095dbbb3009f03a83e2f00
SQL
peach0819/peach
/有用的/需求记录/0、2021年需求/5、订单归属/数仓新的stg层/订单实时归属中间表/dw_trd_order_d修改/dw_trd_order_d参考.sql
UTF-8
15,060
2.875
3
[]
no_license
insert overwrite table ytdw.dw_trd_order_d partition(dayid='$v_date') select order_shop.order_id ,order_shop.order_no ,order_shop.order_status ,coalesce(enum2.enum_value,'未知') as order_status_name ,order_shop.biz_id ,order_shop.biz_type ,coalesce(enum1.enum_value,'未知') as biz_type_name ,order_shop.sale_dc_id ,if(order_...
true
4a9dc067c69c1dd71068ab721b21a1c4528b3f8f
SQL
youngsinatra189/DatabaseAppDev
/a.sql
UTF-8
1,784
3.4375
3
[]
no_license
/* File: a.sql Author: Roshan Sahu Oracle Username: s6_sahuro Description: Enters a new customer */ SET SERVEROUTPUT ON; -- Prompting the customer for the required information ACCEPT p_custname PROMPT 'Enter the customers name: ' ACCEPT p_custstreet PROMPT 'Enter the customer street...
true
f1fabfb18795088e50c5230cd7a9da5430998895
SQL
diegoribas/deserieenserie
/conf/evolutions/default/1.sql
UTF-8
2,596
3.296875
3
[]
no_license
# --- Created by Ebean DDL # To stop Ebean DDL generation, remove this comment and start using Evolutions # --- !Ups create table serie ( id bigint not null, nombre varchar(255), descripcion varchar(255), valoracion double, genero ...
true
901daab6ff1b6edb7093e2f6fca2e3d819e1ac19
SQL
Ospanova/Data_Science
/Courses/Udacity/Bertelsmann Data Science Challenge Scholarship 2018/Tasks/SQL/Basic/Quiz IN/in2.sql
UTF-8
239
3.125
3
[]
no_license
### IN /* Questions using IN operator */ # Use the web_events table to find all information regarding individuals who were contacted via the channel of organic or adwords. SELECT * FROM web_events WHERE channel IN ('organic', 'adwords')
true
9f49f385e468c4bfee2b8fa4a6457ac1f63100c3
SQL
juanig92/mu_online_lgnd
/Database/log.sql
UTF-8
20,215
2.703125
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.21, for Win64 (x86_64) -- -- Host: localhost Database: mu_online_log -- ------------------------------------------------------ -- Server version 5.7.29-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESUL...
true
d5620cef664ddce8a1823a8a84962720588d4c4b
SQL
slabounty/learn_sql_the_hard_way
/ex19.sql
UTF-8
689
3.9375
4
[]
no_license
/* Calclulate average age of a pet */ select sum(age) / count(*) as average from pet; /* Average age of pet */ select avg(age) from pet; /* Average pet name length */ select avg(length(name)) from pet; /# Rounded average age of a pet */ select round(avg(age)) from pet; /* Get a random number */ select random(); /...
true
41973f8fb8680d516ba1d4266ac0e5062229aecb
SQL
LunguAlexandruMihai/timed-quiz
/Docs/tests.sql
UTF-8
2,873
3.3125
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.0.4.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Oct 26, 2013 at 10:02 PM -- Server version: 5.6.11 -- PHP Version: 5.5.3 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;...
true
fa462120e65dd2f6e83d48518c14dcb15806ca71
SQL
vhalbert/modeshape
/connectors/modeshape-connector-jdbc-metadata/src/test/resources/postgresql9/create.ddl
UTF-8
1,504
3.359375
3
[ "Apache-2.0" ]
permissive
-- ModeShape (http://www.modeshape.org) -- -- 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 a...
true
c9df90f8cac5bb9217b5ea1e9aefedb55e407542
SQL
bani48/akademik_syifa
/resource/lampiran_seminar_hasil.sql
UTF-8
2,480
2.65625
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : LOCAL Source Server Version : 50626 Source Host : 127.0.0.1:3306 Source Database : akademik_syifa Target Server Type : MYSQL Target Server Version : 50626 File Encoding : 65001 Date: 2019-02-07 22:15:22 */ SET FOREIGN_KEY_CHECKS=0; -...
true
4a9ceacac806b1e5566ddbe77ccf519111354e15
SQL
zbcha/Database-Structure
/SQL/a4.sql
UTF-8
855
3.171875
3
[]
no_license
CREATE TABLE `Check_List` ( `idCheck_List` int(11) NOT NULL, `S_ID` int(11) NOT NULL, `S_NAME` varchar(255) NOT NULL, `DATE` date NOT NULL, `E_NAME` varchar(255) NOT NULL, `E_ID` int(11) NOT NULL, `GYM_ID` int(11) NOT NULL ); ALTER TABLE `Check_List` ADD PRIMARY KEY (`idCheck_List`); CREATE...
true
c7ce059a1caa172d2c8f43cb24b4fb51284c5e7c
SQL
Duddha/SQL
/[ОЭ] Получившие 1000грн по 87му виду из числа женившихся в определенном году.sql
WINDOWS-1251
712
3.109375
3
[]
no_license
select gmr, tab, rbf.fam_u || ' ' || rbf.f_name_u || ' ' || rbf.s_name_u fio from qwerty.sp_zar_zar13, qwerty.sp_rb_fio rbf where tab in (select id_tab from (select rbf.id_tab, rbf.fam_u || ' ' || rbf.f_name_u || ' ' || rbf.s_name_u fio, ...
true
127e815a2a683eea760a97d3db6e383b13456cf3
SQL
whitewo/football-manager-php-
/db/football.sql
UTF-8
4,901
3.3125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.4.15.5 -- http://www.phpmyadmin.net -- -- Хост: 127.0.0.1:3306 -- Время создания: Авг 21 2016 г., 22:30 -- Версия сервера: 5.5.48 -- Версия PHP: 5.6.19 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT *...
true
fecb50c20be12a274f60cc0642d0d3aa8543795b
SQL
shawnHsx/spring-boot
/src/main/resources/sample.sql
UTF-8
604
3.25
3
[]
no_license
CREATE TABLE `t_user` ( `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键', `use_type` tinyint NOT NULL COMMENT '用户类型 1:个人,2:企业', `user_name` varchar(255) COLLATE utf8_bin NOT NULL COMMENT '姓名', `phone` varchar(255) COLLATE utf8_bin NOT NULL COMMENT '电话', `created_time` datetime NOT NULL DEFAULT CURRENT_TIMESTA...
true
4a57ef5983afd0a808ee0ee0e5147caf9ac1c775
SQL
rashedcs/LAB
/DBMS/Lab 4/insert table.sql
UTF-8
860
2.71875
3
[]
no_license
-- inserting person table with values insert into person values (1, 'Noor Uddin', 'Pabna'), (2, 'Rashed Hasan', 'Sirajganj'), (3, 'Nazmul Hossain', 'Rajshahi'); -- inserting car table with values insert into car values ('Pabna H-124536', 'MAZDA', 2012), ('Dhaka K-536985', 'BMW', 2011), ('Raj R-413...
true
a60d65f78710cb729b5d78412bea661eb5ef9eb5
SQL
erodriguez0/computer-repair-business-app
/esteban_computer_repair_db/crt_views.sql
UTF-8
4,525
4.0625
4
[]
no_license
CREATE OR REPLACE VIEW super_emp AS SELECT emp_id, username, password, super_id, jobtitle FROM employee; CREATE OR REPLACE VIEW empTickets AS SELECT t.ticket_id, t.total_cost, t.status, w.start_date, w.end_date, e.emp_id FROM ticket t, work_on w, employee e WHERE t.ticket_id = w.ticket_id and w.emp_id = e.emp_id;...
true
531099224ccc40172aca4064eeb7d1fe19f79c3f
SQL
shrestha23roshan/school-project
/database/school_project.sql
UTF-8
30,466
2.984375
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jul 03, 2019 at 06:11 PM -- Server version: 10.1.29-MariaDB -- PHP Version: 7.2.0 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
b5f49ed0fb757c1994d89d50ff735e942ffd32be
SQL
Razarion/razarion
/razarion-server/src/test/resources/sql/db/razarion/THREE_JS_MODEL_PACK.sql
UTF-8
5,172
3.25
3
[]
no_license
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET NAMES utf8 */; /*!50503 SET NAMES utf8mb4 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; CREATE TABLE IF NOT EXISTS `THREE_...
true
58113e67d68178e4b875947f1a66284edf6443fa
SQL
stefanos1316/Rosetta-Code-Research
/Scripts/Task/benfords-law/sql/benfords-law.sql
UTF-8
909
3.921875
4
[]
no_license
-- Create table create table benford (num integer); -- Seed table insert into benford (num) values (1); insert into benford (num) values (1); insert into benford (num) values (2); -- Populate table insert into benford (num) select ult + penult from (select max(num) as ult from benford), (select max(nu...
true
feb9a0aec1dcb96c5c377097cc5d9799a8be60c8
SQL
haneyx/Php.ApiPeliculas
/BD.sql
UTF-8
764
2.9375
3
[]
no_license
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; CREATE DATABASE peliculas; CREATE TABLE peliculas.pelicula ( id INT(8) AUTO_INCREMENT NOT NULL, nombre VARCHAR(70) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL , anio int(4) NOT NULL , PRIMARY KEY(id) ) ENGINE = INNODB CHARACTER SET utf8 COLLATE utf8_unicode_ci; /...
true
cb17f6de16586ce687edff749eed7fbdc31f72a4
SQL
luismangulov/ideas-en-accion
/sql/migrar_ganadores_votaciones_internas.sql
UTF-8
1,298
3.984375
4
[]
no_license
select * from ( select IF(@region = region_id, @ctr := @ctr + 1, @ctr := 1) as rn, @region := region_id, region_id, proyecto_id, votos, resumen,equipo_id,tipo,ruta,votomaximo from ( select votacion_interna.region_id, votacion_interna.proyecto_id, count(votacion_interna.id) / (select count(votacion_interna.id) as vot...
true
30a914d212c765e9a58fe609852a9d2cf4e33ad5
SQL
Nguyen-Dinh-Sang/SSGTraining_Oracle
/FourthWeek/Practice/Query12.sql
UTF-8
5,546
4.5
4
[]
no_license
SELECT PB AS "Phòng Ban", MNV AS "Mã Nhân Viên", HTNV AS "Họ Tên Nhân Viên", LUONG AS "Mức Lương", TLP AS "Tổng Lương Phòng", SNV AS "Số Nhân Viên Phòng", TBLP AS "Lương Trung Bình Phòng" FROM TABLE(NHAN_VIEN_LUONG_HON_TB); -- Tạo loại bản ghi CREATE OR REPLACE TYPE TABL...
true
cd4717090fa98b9d26ea5455839b9f607fcb773d
SQL
grayasm/git-main
/tutorial/postgresql_11.1_doc/08_data_types/08.2_geo_line.sql
UTF-8
1,876
3.90625
4
[]
no_license
/* Cap.8 Data Types 8.8. Geometry Types 8.8.2 Lines psql -d mytestdb -U pgmihai \i 08.2_geo_line.sql \? \qecho '\033[2J' */ /* Geometric Types Name Storage Size Description Representation ------+-----------+--------+-----------------+----------------------------- ...
true
f5fb5208ca88384ec37686852f83d36cdeb59f5e
SQL
adetiamarhadi/demo-jdbc-jpa
/src/main/resources/data.sql
UTF-8
1,841
3.265625
3
[]
no_license
--create table person ( --id integer not null, --name varchar(255) not null, --location varchar(255), --birth_date timestamp, --primary key(id) --); insert into person (id, name, location, birth_date) values (1001, 'Adet', 'Bekasi', sysdate()); insert into person (id, name, location, birth_date) values (1002, 'Avril',...
true
48025c71e96d81fd48f60f58100ce3c32abffef9
SQL
swapnilblues/-cs5200-fall2019-bhaumik1
/cs5200-fall2019-bhaumik/Assignment3/SQL_for_Stored_Procedure/create_for_stored_procedure.sql
UTF-8
1,349
3.46875
3
[]
no_license
create table module ( name varchar(20) not null default '', primary key (name) ); insert into module (name) values ('Project1'); insert into module (name) values ('Project2'); insert into module (name) values ('Assignment1'); insert into module (name) values ('Assignment2'); insert into module (name) values ('Qui...
true
d7487fef131dd4c79ed05ad96f87d552ab18c8ea
SQL
ECipolatti/Bases-de-Datos
/Practica Tuco/G7/E7.sql
UTF-8
360
2.9375
3
[]
no_license
/*CREATE TRIGGER tr_productos_iu ON productos FOR insert, update AS IF UPDATE (stock) begin if EXISTS ( SELECT stock FROM INSERTED WHERE stock<0 ) begin RAISERROR('Stock negativo',1,16,1) ROLLBACK TRANSACTION end end */ INSERT INTO productos (codProd,descr,precUnit...
true
71ca48b0ab5c1bbabd59af5649dde16055f0b93d
SQL
shixiuyin/rbac
/src/main/resources/rbac.sql
UTF-8
6,812
3.09375
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : bj1804 Source Server Version : 50717 Source Host : localhost:3306 Source Database : rbac Target Server Type : MYSQL Target Server Version : 50717 File Encoding : 65001 Date: 2018-09-28 16:28:59 */ SET FOREIGN_KEY_CHECKS=0; -- -------...
true
738ebcafec6863a801d9f1afd903937401428bc8
SQL
Sourabh-Kumar7/Hacker-Rank
/SQL/Basic Join/Ollivander's-Inventory.sql
UTF-8
409
3.765625
4
[]
no_license
-- Problem Statement : https://www.hackerrank.com/challenges/harry-potter-and-wands/problem SELECT ID,AGE,m.COINS_NEEDED,m.POWER FROM (SELECT CODE,POWER,MIN(COINS_NEEDED) AS COINS_NEEDED FROM WANDS GROUP BY CODE,POWER) AS m JOIN WANDS AS w ON m.CODE=w.CODE AND m.COINS_NEEDED=w.COINS_NEEDED AND m.POWER = w.POWER JOIN...
true
d6a03f2d3bb5416929cc28cbf2a28f8d0f37999f
SQL
GJordao12/ISEP-BDDAD
/PL6-Scripts/PL06-Scripts/PL06.S1-CREATE e ALTER TABLE.sql
ISO-8859-1
3,932
3.859375
4
[]
no_license
-- ** eliminar tabelas se existentes ** -- CASCADE CONSTRAINTS para eliminar as restries de integridade das chaves primrias e chaves nicas -- PURGE elimina a tabela da base de dados e da "reciclagem" DROP TABLE revisao CASCADE CONSTRAINTS PURGE; DROP TABLE automovelCliente CASCADE CONSTRAINTS PURGE; DROP TAB...
true
5a625e901728bb3988f1095e94efe81651f5d61c
SQL
sssvt-palynskyj/Projekt_New
/SongsAndVotesSol/DatabaseScript.sql
UTF-8
1,048
3.34375
3
[]
no_license
CREATE TABLE TB_Role ( CISLOROLE INT IDENTITY(1,1) NOT NULL, CONSTRAINT FK_CISLOROLE FOREIGN KEY (CISLOROLE) REFERENCES TB_UserData (ID), NAZEVROLE NVARCHAR(20) NOT NULL, ); CREATE TABLE TB_UserData ( ID INT IDENTITY(1,1) NOT NULL, CONSTRAINT PK_CISLOROLE PRIMARY KEY (ID), USERNAME NVARCHAR(64) NOT NULL, USERP...
true
1fec5350d1061a3c79d7848a8633d1a9a8f0fd78
SQL
hasnathm99/construction_management_system
/db/rent_status.sql
UTF-8
1,836
3.109375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Sep 13, 2018 at 12:04 PM -- Server version: 10.1.29-MariaDB -- PHP Version: 7.2.0 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
50fdac627327a4977f0f8b39db7075504fdc4bcb
SQL
vahmed/SQL
/addSynonyms.sql
UTF-8
843
3.421875
3
[]
no_license
DEFINE src_schema=&1 DEFINE dest_schema=&2 SET SERVEROUTPUT ON SET DEFINE ON DECLARE v_cursor SYS_REFCURSOR; v_c1 dba_objects%ROWTYPE; v_sql VARCHAR2 (2000); BEGIN OPEN v_cursor FOR SELECT * FROM dba_objects WHERE object_type = 'PACKAGE' AND owner = '&src_schema...
true
44d9ea8e47205f6c8d61e9a9cb6183294331d7ee
SQL
bradleyservice/helo
/db/get_all_posts.sql
UTF-8
191
3.53125
4
[]
no_license
SELECT p.*, u.username, u.profile_pic FROM users u JOIN posts p ON u.id = p.author_id WHERE CASE WHEN $1 = false then u.id != $2 ELSE true END AND LOWER(p.title) LIKE LOWER('%' || $3 || '%');
true
5ab64622c01bee71b183967e2782a97702475b80
SQL
SivanLiu/SpringBoot-Learning-exercises
/SpringDatabase/src/main/resources/sql/t_user.sql
UTF-8
311
2.96875
3
[]
no_license
create table t_user ( id int(12) not null auto_increment, user_name varchar(60) not null, sex int(3) not null default 1 check (sex in (1, 2)), note varchar(256) null, primary key (id) ); insert into t_user (id, user_name, sex, note) values(1,'gggg', 2, 'gggg')
true
e091a97e837d9e1ccf2ff8801aed857796669895
SQL
everthis/leetcode-js
/1077-project-employees-iii.sql
UTF-8
346
3.84375
4
[ "MIT" ]
permissive
# Write your MySQL query statement below SELECT P.project_id, E.employee_id FROM Project as P INNER JOIN Employee as E On E.employee_id = P.employee_id WHERE (P.project_id , E.experience_years) in ( SELECT P.project_id, MAX(E.experience_years) FROM Project as P INNER JOIN Employee as E On E.employee_id = P.employee_i...
true
8325a22c03d099268d66edd1dc2f3841f3885a3c
SQL
waterknows/cspp53001
/examples/HAFH insert.sql
UTF-8
2,382
2.734375
3
[]
no_license
INSERT INTO manager VALUES ('M12', 'Boris', 'Grant', '1980-06-20', 60000, null, null); INSERT INTO manager VALUES ('M23', 'Austin', 'Lee', '1975-10-30', 50000, 5000, null); INSERT INTO manager VALUES ('M34', 'George', 'Sherman', '1976-01-11', 52000, 2000, null); INSERT INTO managerphone VALUES ('M12', '555-222...
true
ebc6a9aa04d72df4e69e82da4b97616c58adbc6f
SQL
bellmit/origin
/family_order/sql/TF_F_USER_DISCNT/SEL_BY_USERID_SVC.sql
UTF-8
667
3.1875
3
[]
no_license
SELECT partition_id,to_char(user_id) user_id,to_char(user_id_a) user_id_a,a.discnt_code,spec_tag,relation_type_code,to_char(a.start_date,'yyyy-mm-dd hh24:mi:ss') start_date,to_char(a.end_date,'yyyy-mm-dd hh24:mi:ss') end_date FROM tf_f_user_discnt a WHERE a.user_id=:USER_ID AND a.partition_id=MOD(:USER_ID,10000) AN...
true
aa56e4175a51f72fa679ec8ecde954c8cf7427ac
SQL
kort/kort-core
/database/kort/kort_views.sql
UTF-8
10,879
3.828125
4
[ "MIT" ]
permissive
create or replace view kort.all_errors as select e.source, e.error_id, e.schema, e.error_type_id, e.osm_id, e.osm_type, e.description, CAST(e.latitude AS NUMERIC)/10000000 latitude, CAST(e.longitude AS NUMERIC)/10000000 longitude, e.geom, ...
true
3c7ebed414dfea45749ddc26121fec5448852afa
SQL
imkhalidhasan/Art-gallary
/art.sql
UTF-8
2,858
3.078125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Dec 26, 2018 at 06:03 AM -- Server version: 10.1.32-MariaDB -- PHP Version: 7.2.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @O...
true
e3d6aa7894271e774c2dc650592d41c6380e453d
SQL
seungbeomi/development
/java/spring/spring-batch/spring-batch-web/DATABASE/quartz/tables_mysql.sql
UTF-8
6,005
3.140625
3
[]
no_license
drop table qrtz_calendars; drop table qrtz_fired_triggers; drop table qrtz_trigger_listeners; drop table qrtz_blob_triggers; drop table qrtz_cron_triggers; drop table qrtz_simple_triggers; drop table qrtz_triggers; drop table qrtz_job_listeners; drop table qrtz_job_details; drop table qrtz_paused_trigger_grps; drop tab...
true
52c1c89d3e325859b424a2ceaf2681ca7dacee98
SQL
FelixPriori/BootcampX
/4_queries/6_cohort_with_longest_assistances.sql
UTF-8
725
3.875
4
[]
no_license
SELECT avg_table.name, avg_table.avg_cohorts_time FROM ( SELECT cohorts.name as name, avg(assistance_requests.completed_at - assistance_requests.started_at) as avg_cohorts_time FROM assistance_requests JOIN students ON student_id = students.id JOIN cohorts ON cohort_id = cohorts.id GROUP BY cohorts.name )...
true
630f640c5ab0f5e4d451f4abed9612d49e854fd5
SQL
kylie2250/01_sql-1
/day08.sql
UHC
6,036
4.03125
4
[]
no_license
--day 08: Լ --(3) Լ ---6)case ---job ޿ /* CLERK : 5% SALESMAN :4% MANAGER: 3.7% ANALYST :3% pRESIEDNT: 1.5% */ --1.Simple CASE --: DECODE , 񱳸 --ٸ : ȣ , ޸ WHEN,THEN,ELES SELECT e.sal , e.ename ,e.job ,CASE e.job WHEN 'CLERK' THEN e.sal * 0.05 ...
true
17e3e83f3ab7cf520c874e0ee8ec40d826eafead
SQL
mjturi/Soccer-Leagues-Site
/sql/soccer.sql
UTF-8
2,635
3.5
4
[]
no_license
CREATE TABLE `league` ( `League_id` int NOT NULL AUTO_INCREMENT, `League_Name` varchar(45) NOT NULL, `League_Country` varchar(45) NOT NULL, PRIMARY KEY (`League_id`) ) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; INSERT INTO `league` VALUES (5,'Bundesliga 1','Germany'),(...
true
9796bacb1b2f1487e16e0734af0ef3982b04243e
SQL
abhi3174/Databse
/assignement11sql.sql
UTF-8
472
3.46875
3
[]
no_license
use company; select * from orders; select * from customers; select * from salespeople; select sum(amt) from orders group by snum; select max(amt) from orders; #1 select onum,amt from orders where snum=(select snum from customers where cname="Cisneros"); #2 select Cname,Rating from customers where cnum in (select cnu...
true
bce5543049d8c5d3a0a9a59aab29b506220831ea
SQL
dsatiyeh04/CAHSI-Database
/SQL/Abstract.sql
UTF-8
788
2.9375
3
[]
no_license
CREATE TABLE Abstract ( ABKey INT(10) NOT NULL AUTO_INCREMENT, Atitle VARCHAR(30) NOT NULL, ABstatus CHAR(20) NOT NULL, ABPoster BLOB, Aadmin_ID INT(10) NOT NULL, Sstudent_ID INT(10) NOT NULL, ABKey_doc INT(10) NOT NULL, PRIMARY KEY (ABKey), FOREIGN KEY (Aadmin_ID) REFERENCES Admin (Aadmin_ID) ON UPDATE CASC...
true
9c2295e6c0bfd410bb183d61c23ac5059523bb62
SQL
yangricardo/INF1341-BD3-Trabalho1
/sql_scripts/functions/CALCULA_NOTA_GERAL.sql
UTF-8
317
2.59375
3
[]
no_license
create or replace FUNCTION CALCULA_NOTA_GERAL(CODMODALIDADE_ NUMBER, CODATLETA_ NUMBER) RETURN NUMBER AS V_RETORNO NUMBER; BEGIN SELECT SUM(AH.NOTA) INTO V_RETORNO FROM ATLETAHISTORICO AH WHERE AH.CODMODALIDADE = CODMODALIDADE_ AND AH.CODATLETA = CODATLETA_; RETURN V_RETORNO; END CALCULA_NOTA_GERAL;
true
528fb1d08db1ad5040d1180b5fc7fc9575bfe8cf
SQL
nktssk/DataBase
/universiade_village/V18__student_position_create.sql
UTF-8
207
3.125
3
[]
no_license
CREATE TABLE IF NOT EXISTS `student_position` ( `id` INT UNSIGNED UNIQUE NOT NULL AUTO_INCREMENT, `position` VARCHAR(100) NOT NULL, PRIMARY KEY (`id`), UNIQUE INDEX `id_UNIQUE` (`id` ASC) VISIBLE);
true
1292ee6e8841452112401623fef706f3808b6655
SQL
yoonjk/spring-batch
/scripts/emp.sql
UTF-8
741
3.28125
3
[ "Apache-2.0" ]
permissive
CREATE TABLE IF NOT EXISTS GRADE ( GRADE_CODE INTEGER NOT NULL, BONUS_MAGNIFICATION INTEGER, FIXED_BONUS INTEGER, PRIMARY KEY (GRADE_CODE) ); CREATE TABLE IF NOT EXISTS EMP ( EMP_ID INTEGER NOT NULL, EMP_NAME VARCHAR(50), BASIC_SALARY INTEGER, GRADE_CODE INTEGER NOT NULL, PRIMARY KEY (EMP_ID), FORE...
true
f17e5c65278216436d151e678498c7aebeaaa448
SQL
kheneahm-ares/DatabaseProject
/TriggersAndProcedures.sql
UTF-8
2,185
3.96875
4
[]
no_license
DROP PROCEDURE IF EXISTS proc_update_days_left; DELIMITER // CREATE PROCEDURE proc_update_days_left() BEGIN DECLARE cur_id INT; DECLARE cur_date DATE; DECLARE done INT DEFAULT 0; DECLARE cur CURSOR FOR SELECT id, dateDue FROM rentals WHERE isReturned = 0; DECLARE CONTINUE HANDLER FOR NOT FOUN...
true
725807874bdffd3134873f2cfb8414cb4adba13c
SQL
JoamirS/oracle-database
/Class_08.sql
UTF-8
348
2.734375
3
[]
no_license
INSERT INTO tb_produtos ( PRODUTO, NOME, EMBALAGEM, TAMANHO, SABOR, PRECO_LISTA ) VALUES ( '1040108', 'Premium - 450 ml', 'PET', '450 ml', 'Limão', 7.0 ) -- Selecionando os registros da tabela. SELECT * FROM tb_produtos; -- Alterando o registro da tabela UPDATE tb_produtos SET embalagem = 'Lata', preco_lista = 2.46...
true
7f6794c83ce35c0c67701297bd13c852dea757e6
SQL
novadwisaptanainseven/konfis-api
/pkfp-app.sql
UTF-8
14,855
2.8125
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 5.0.3 -- https://www.phpmyadmin.net/ -- -- Host: localhost:3306 -- Generation Time: Apr 13, 2021 at 10:15 AM -- Server version: 5.5.65-MariaDB -- PHP Version: 7.3.27 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_...
true
c0fcf48a58e30b263863096e839fef3200c2b25e
SQL
jonliu6/KnowledgeBase
/src/main/resources/dbscripts.sql
UTF-8
1,360
3.375
3
[]
no_license
--Create database and user. Refer to https://jldevtest.blogspot.com/2018/10/set-up-postgressql-database.html --log on PostgreSQL with user and database information -- psql -h localhost -p 5432 -U postgres -W -d db_knowledge_base -- data structure scripts (DDL) CREATE SEQUENCE public.article_id_seq START WITH 10000...
true
9c1c88bd885e9614e495539ec74ad42e27006270
SQL
jianbingfang/xhf
/src/main/resources/dbmigrate/h2/car/V0_0_1__car_info.sql
UTF-8
415
2.875
3
[ "Apache-2.0" ]
permissive
------------------------------------------------------------------------------- -- car info ------------------------------------------------------------------------------- CREATE TABLE CAR_INFO( ID BIGINT GENERATED BY DEFAULT AS IDENTITY(START WITH 1) NOT NULL, NAME VARCHAR(200), CODE VARCHAR(200), STATUS...
true
7d2e54e4bba1ab416f8bb7f6a82f40ef77a65a5e
SQL
univmajalengka/181410001
/SBDL/notaris.sql
UTF-8
10,359
3
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Apr 04, 2020 at 03:36 PM -- Server version: 10.4.8-MariaDB -- PHP Version: 7.3.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
true
10ec2590d2252c565879804dc73b858db5b5faaa
SQL
itsmixa/ora_perf_diag
/top_sharedpool_sqls.sql
UTF-8
399
2.75
3
[]
no_license
col "Stmt" for a100 wrap select * from (SELECT sql_text "Stmt", sql_id, count(*), sum(sharable_mem)/1024/1024 "Mem", sum(users_opening) "Open", sum(executions) "Exec" FROM v$sql GROUP BY sql_text, sql_id order by "Mem" desc) where rownum<20; --HAVING sum(sharable_mem) > (select current_size*0.01 fr...
true
12d76e2018a75a9c90720463ad37869cc7a95dc5
SQL
tejuh/MobileManufacturerAnalysis
/Mobile manufacturer data analysis.sql
UTF-8
5,259
4.5625
5
[]
no_license
--1)ALL STATES WHERE CUSTOMERS HAVE BOUGHT CELLPHONES FROM 2005 SELECT DISTINCT T1.STATE AS STATE1 FROM DIM_LOCATION AS T1 left JOIN FACT_TRANSACTIONS AS T2 ON T1.IDLocation = T2.IDLocation WHERE year(date) >= 2005 -- 2) WHICH STATE IN US IS BUYING MORE SAMSUNG PHONES SELECT top 1 state from FACT_TRANSACTIONS...
true
b6b9a82054a9986bed3e5da6b968409c058d3c9d
SQL
kranthi003/Lib_Pers
/transaction/common/Database/P2a/REVERSAL_REASON_TYPE.sql
UTF-8
1,787
3.375
3
[]
no_license
/*==============================================================*/ /* DBMS name: ORACLE Version 10g */ /* Created on: 8/3/2011 8:21:03 PM */ /*==============================================================*/ /*==========================================...
true
f7c0cc2aa7b1c3b4ebeea6b118e2356e8e536a5d
SQL
zhzahid1911509/CSE311_Section-1_Project_Group-2
/sql file/get_ambulance.sql
UTF-8
2,115
2.9375
3
[ "MIT" ]
permissive
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Sep 30, 2020 at 05:31 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