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
f77b64d21ec02f0306c1e462779cacdfe5275962
SQL
DanBasilaev/xsolla_backend
/catalog.sql
UTF-8
1,752
3.171875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.1.0 -- https://www.phpmyadmin.net/ -- -- Хост: 127.0.0.1:3306 -- Время создания: Июл 18 2021 г., 18:11 -- Версия сервера: 8.0.24 -- Версия PHP: 8.0.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARA...
true
0524c07ab0d475a1559cc41fa490e8b8553f0631
SQL
kayvank/kinesis-to-aurora
/scripts/sql/like_events.sql
UTF-8
292
2.984375
3
[]
no_license
-- -- create like-events table -- create table like_events ( id varchar(40) not null unique, user_id varchar(40) not null, entity_id varchar(140) not null, entity_type varchar(20) not null, ts timestamp , created_at timestamp default CURRENT_TIMESTAMP, CONSTRAINT pk_id PRIMARY KEY(id) );
true
ab9692aad499c43f7abfbc908dbc16d8beba5bf5
SQL
ravindrakumarkumawat/todo-postgresql
/init.sql
UTF-8
617
3.859375
4
[]
no_license
CREATE TABLE lists ( list_id SERIAL PRIMARY KEY NOT NULL, list_name VARCHAR(255) NOT NULL ) -- INSERT INTO lists (list_name) VALUES ('Shopping of book') CREATE TABLE tasks ( task_id SERIAL PRIMARY KEY NOT NULL, task_name VARCHAR(255) NOT NULL, task_scheduled DATE, completed boolean DEFAULT FAL...
true
400e4dc08517d3375b94a76dfe7bb44b654eca9e
SQL
Nell87/SQL-exercises
/02.Employee_management/02.questions_and_solutions.sql
UTF-8
3,694
4.90625
5
[]
no_license
# 1. Select the last name of all employees. SELECT LastName FROM employees; # 2. Select the last name of all employees, without duplicates. SELECT DISTINCT LastName FROM employees; # 3. Select all the data of employees whose last name is "Smith". SELECT * FROM employees WHERE LastName = "Smith"; # 4. Select all the ...
true
89253536c5b4880a6546e47191b7ba86c8ae9063
SQL
zhangtianle/AttendanceSys
/ass.sql
UTF-8
3,672
2.859375
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : local Source Server Version : 50710 Source Host : 127.0.0.1:3306 Source Database : ass Target Server Type : MYSQL Target Server Version : 50710 File Encoding : 65001 Date: 2017-10-25 11:55:59 */ SET FOREIGN_KEY_CHECKS=0...
true
c3651d994f3e315c9e4f880d71dfa9655d0ee9db
SQL
joegeneq/apc-softdev-it112-07
/database/yii2advanced.sql
UTF-8
7,727
3.03125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.0.9 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Apr 22, 2015 at 02:00 PM -- Server version: 5.6.14 -- PHP Version: 5.5.6 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /...
true
7e2cbdcae046fd59f2cb15663da3d89d6afe432a
SQL
semihstp/Patika_VitrA_VeriBilimi_Bootcamp
/Week 01 SQL Homeworks/sql_odev07.sql
UTF-8
733
4.125
4
[]
no_license
-- 1) -- film db'sindeki rating sütunu gruplandı. SELECT rating FROM film GROUP BY rating; -- 2) -- film db'sindeki replacement_cost sütununu gruplayıp sayısı 50'den az olan -- replacement_cost'lar harici hepsini al ve ORDER BY ile bana sırala dedik. SELECT replacement_cost, COUNT(*) FROM film GROUP BY replacement_co...
true
f7f63b087289fd7141cc08d9a03b81bd0e167003
SQL
CaroBima/g9-a3g9stock
/Documentación/BDD/Script DDL - BeerFriendsStockSystem.sql
UTF-8
8,710
3.359375
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='ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTI...
true
92ec155dfea118270a1cef4bca53bb38d085f4b1
SQL
GXT2821/Ordering-system
/ordersys.sql
UTF-8
14,400
2.84375
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : MySQL Source Server Version : 50508 Source Host : localhost:3306 Source Database : ordersys Target Server Type : MYSQL Target Server Version : 50508 File Encoding : 65001 Date: 2017-07-06 15:05:14 */ SET FOREIGN_KEY_CHE...
true
99c86c2b072c72e9a2977fadf07fa566c1584ec1
SQL
dyancl1024/CodeGenerator
/temp/tempfolder/RH/Training/Modify/CourseQuestionModify.sql
UTF-8
759
3
3
[]
no_license
/* RH_CourseQuestion - 修改信息脚本 */ DROP PROCEDURE IF EXISTS sp_SJ_RH_CourseQuestion_Modify; CREATE PROCEDURE sp_SJ_RH_CourseQuestion_Modify ( IN i_ID int, IN i_CourseID int, IN i_Question nvarchar(200), IN i_QType int, IN i_Sort int, IN i_Status int, IN i_CreateBy int, IN i_CreateTime datetime,...
true
78df5685a446fcb2c6c3896ec70cf6892a828aa4
SQL
DimaKriv/SpringOrderStorage
/src/main/resources/populate.sql
UTF-8
524
2.78125
3
[]
no_license
DELETE FROM order_task; DELETE FROM order_row; BEGIN TRANSACTION; INSERT INTO order_task(order_number) VALUES('Potate'); INSERT INTO order_row(order_id,item_name, quantity, price) VALUES (currval('seq1'), 'Brown', 50, 5); INSERT INTO order_row(order_id,item_name, quantity, price) VALUES (currval('seq1'), 'White', 2...
true
050ee1ea02d380b588e6f4a4d5d2d81a32bd5c45
SQL
onlinekof2001/OracleProcedure
/d_sqltxt.sql
UTF-8
715
2.5625
3
[]
no_license
rem ******************************************************************************** rem ******************************************************************************** rem who : pascal BEN rem rem FUNCTION rem display the query of an SQL_ID rem rem rem ***************************************************************...
true
9f378092528825c51d183743fb05627c635cbb58
SQL
ahmadtechcampus2/ahmad4
/برنامج الامين المحاسبي/Bin/System/Sys/prcPOSSD_RelatedSale_GetMaterialExtended.sql
UTF-8
797
3.515625
4
[]
no_license
################################################################################ CREATE PROCEDURE prcPOSSD_RelatedSale_GetMaterialExtended -- Param -------------------------------- @MaterialExtendedType INT ----------------------------------------- AS SET NOCOUNT ON ------------------------------------...
true
675e24c2cf8c66535d4a6c16cd6e97683a9e11ce
SQL
CarlitosDev/PersonalisationsUtils
/sql/collectStatsOnRawTables.sql
UTF-8
3,365
3.671875
4
[]
no_license
-- List of the campaigns and their presence create table adform.impressionsList AS ( SELECT campaign_id, count(*) AS numRecords, sum(case when publisher_domain = '' then 1 else 0 end) as unknownPubl, rank() over (order by numRecords desc) as rnk from adform.impressions group by 1 ) -- List of the campai...
true
357e5ad146caa23dd39378aecc22672e5a0863c4
SQL
RisingStar522/python-scraping
/dataproducts.sql
UTF-8
1,682
3.140625
3
[]
no_license
/* Navicat Premium Data Transfer Source Server : localhost_3306 Source Server Type : MySQL Source Server Version : 100416 Source Host : localhost:3306 Source Schema : priceanalyzer Target Server Type : MySQL Target Server Version : 100416 File Encoding : 65001 Date: ...
true
812014394a0814bebf77d53f9a35540eb37ddbe2
SQL
FirebirdSQL/x-cvs-vulcanj
/VulcanJ/ddl/nist/dml147.sql
UTF-8
941
3.375
3
[]
no_license
SET NAMES ASCII; CREATE DATABASE 'test.fdb' DEFAULT CHARACTER SET ISO8859_1; -- Notes: TEST:0840 Roll back schema manipulation ! CREATE TABLE USIG (C1 INT, C_1 INT); INSERT INTO USIG VALUES (0,2); INSERT INTO USIG VALUES (1,3); COMMIT; SET AUTODDL OFF; CREATE TABLE NOT_THERE (C1 CHAR (10)); -- PASS:0840 If tabl...
true
e787afa5876401a18112907cdf5bb00eac7f04a1
SQL
reversedArrow/cmput291
/ass2/a2-queries.sql
UTF-8
4,232
3.796875
4
[]
no_license
.print Question 1 -xianhang SELECT distinct sa.local_contact FROM service_agreements sa, account_managers am, accounts ac, personnel p WHERE sa.master_account = ac.account_no AND ac.account_mgr = p.pid AND sa.waste_type = "hazardous waste" AND p.name = "Dan Brown"; .print Question 2 -xianhang SELECT distin...
true
554884d4d26f62fea47a78d400ecf25140c369df
SQL
dtom90/FinDash
/db/sample_queries.sql
UTF-8
2,562
3.375
3
[ "Apache-2.0" ]
permissive
-- STOCK_TRADES -- SELECT DISTINCT SYMBOL from STOCK_TRADES; SELECT SYMBOL,TRADE_DATE,CLOSE_PRICE from STOCK_TRADES WHERE ("SYMBOL"='AMZN') ORDER BY TRADE_DATE; SELECT SYMBOL,TRADE_DATE,CLOSE_PRICE from STOCK_TRADES WHERE ("SYMBOL"='RACE') ORDER BY TRADE_DATE; SELECT DISTINCT SYMBOL,TRADE_DATE,CLOSE_PRICE from STOC...
true
623a40f31634aa84b038d9e3af3bb464ab1142e2
SQL
mlevitas94/codechallenge
/db/seed.sql
UTF-8
476
3.171875
3
[]
no_license
create table users ( id serial primary key, name varchar(50) not null, email varchar(50) not null, password text not null, admin boolean default false ); create table projects ( id serial primary key, user_id int references users(id) not null, name varchar(100) not null ); create table...
true
9eff0d0e92b3bdb04f6a2f6ca0afeaf9ae9aa026
SQL
AlexanderAtanasov/SoftUni_MySQL
/MySQL - 06 - Subqueries and JOINs/Exercise Tasks/GeographyDB - Tasks 12 - 17/Problem.17 - Highest Peak and Longest River by Country.sql
UTF-8
613
4.21875
4
[]
no_license
SELECT c.`country_name`, MAX(p.`elevation`) AS `highest_peak_elevation`, MAX(r.`length`) AS `longest_river_length` FROM `countries` AS c LEFT JOIN `mountains_countries` AS mc USING (`country_code`) LEFT JOIN `mountains` AS m ON mc.`mountain_id` = m.`id` LEFT JOIN `pe...
true
61b709921fd3af6f337f13625e8365c56cfd7329
SQL
james-gould/osm2mssql
/osm2mssql.Importer/SQL/CreateDatabase.sql
UTF-8
1,662
2.609375
3
[]
no_license
if exists(select * from sys.databases where name = '[OSM]') begin ALTER DATABASE [OSM] SET SINGLE_USER WITH ROLLBACK IMMEDIATE DROP DATABASE [OSM]; end CREATE DATABASE [OSM]; ALTER DATABASE [OSM] SET ANSI_NULL_DEFAULT OFF ; ALTER DATABASE [OSM] SET ANSI_NULLS OFF ; ALTER DATABASE [OSM] SET ANSI_PADDING OFF ; ALTER ...
true
3cbf22f64e53d0610884b72f217490ba124fccd4
SQL
suhail9722/HackerRank_SQL
/Basic Select/Weather Observation Station 7.sql
UTF-8
430
3.203125
3
[]
no_license
ERROR: type should be string, got "https://www.hackerrank.com/challenges/weather-observation-station-7/problem\n\nQuery the list of CITY names ending with vowels (a, e, i, o, u) from STATION. Your result cannot contain duplicates.\n\n\nSELECT DISTINCT CITY FROM STATION WHERE CITY REGEXP '[AEIOU]$'; ---> $ IS USED TO MATCH THE LAST WORD\n\nSELECT DISTINCT CITY FROM STATION WHERE CITY LIKE '%A' OR CITY LIKE '%E' OR CITY LIKE '%I' OR CITY LIKE '%O' OR CITY LIKE 'U';\n\n\n\n"
true
3505ac7a5c22e1b8cea4f5725ea8b66245d3ee50
SQL
thechicagoreporter/ilcampaigncash
/sql/views/Officers.sql
UTF-8
430
2.71875
3
[ "MIT" ]
permissive
CREATE TABLE public.officers AS SELECT id as id, lastname as last_name, firstname as first_name, address1 as address1, address2 as address2, city as city, state as state, zip as zip, title as title, phone as phone, redactionrequ...
true
4549667b803da2623c8d503bf13c4bd95a2d3d8a
SQL
Ankit0907/Dataphi-submission
/form_data.sql
UTF-8
2,668
2.90625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.0.1 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Apr 29, 2018 at 09:22 PM -- Server version: 5.7.21-0ubuntu0.17.10.1 -- PHP Version: 7.1.16-1+ubuntu17.10.1+deb.sury.org+1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET...
true
4a3a4c7ae2b1b754d14f0c20bf854642086c9516
SQL
smminhaz/SalesMonitoring-JavaSwing
/mall.sql
UTF-8
3,634
3
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 2.10.0.2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Jun 02, 2014 at 12:55 PM -- Server version: 5.0.37 -- PHP Version: 5.2.1 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; -- -- Database: `mall` -- -- -------------------------------------------------------- --...
true
58e8dc59ee5fa0c353c9d6bf0a84945cd4862a17
SQL
johanhanses/databas
/skolan/insert.sql
UTF-8
2,019
3.515625
4
[]
no_license
-- -- Insert values into tables in database skolan. -- By johv18 for course databas. -- 2019-02-12 -- -- -- inserts and updates into table larare -- -- Delete if not empty DELETE FROM larare; -- Add column to TABLE ALTER TABLE larare DROP COLUMN kompetens; ALTER TABLE larare ADD COLUMN kompetens INT DEFAULT 1 NOT NUL...
true
ccca2e385b1f4c8407fe87a475b8fb6c128895c6
SQL
huhaiqng/WeibbixJava
/data/weibbix.sql
UTF-8
20,181
3.078125
3
[]
no_license
-- MySQL dump 10.13 Distrib 8.0.12, for linux-glibc2.12 (x86_64) -- -- Host: localhost Database: testdb -- ------------------------------------------------------ -- Server version 8.0.12 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULT...
true
ed75c3303f6dbce801ef93e36ac32f5aeeabe3af
SQL
salvajih/LSC-Grants
/Easygrants_Web_LSC/Easygrants_Web_LSC/DBScripts/Build 8.x/Build 8.4/06_Create_vLSC_TIG_BUDGET_BY_FUNDING_TYPE_PIVOT.sql
UTF-8
342
3.34375
3
[]
no_license
CREATE VIEW vLSC_TIG_BUDGET_BY_FUNDING_TYPE_PIVOT AS SELECT lsc_tig_budget_id, [1], [2], [3], [4] FROM (SELECT lsc_tig_budget_id, lsc_tig_budget_funding_type_id, funding_type_total FROM vLSC_TIG_BUDGET_BY_FUNDING_TYPE) AS lines PIVOT (SUM(funding_type_total) FOR lsc_tig_budget_funding_type_id IN ([1], [2],...
true
167b0c97beba0330795c85f0e6ee45315068aa25
SQL
alansis/testTaskBittrix
/markers.sql
UTF-8
2,075
3.09375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.6.5.2 -- https://www.phpmyadmin.net/ -- -- Хост: 127.0.0.1 -- Время создания: Дек 01 2017 г., 15:19 -- Версия сервера: 10.1.21-MariaDB -- Версия PHP: 7.1.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIE...
true
4eb7634d3acd88d5e294a54e9aeab521d68e4ff9
SQL
ivansushchyk/myMovies
/movies.sql
UTF-8
5,012
3.203125
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.25, for Linux (x86_64) -- -- Host: localhost Database: movies -- ------------------------------------------------------ -- Server version 5.7.25-0ubuntu0.18.04.2 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET...
true
140fa71f6cdd9c8ab2bc97b1de5437b10a4e4e1b
SQL
yanlinlin82/leetcode
/00262_trips-and-users/200617-1.sql
UTF-8
438
4.03125
4
[ "MIT" ]
permissive
-- https://leetcode-cn.com/problems/trips-and-users/ SELECT Request_at Day, ROUND(SUM(Status != 'completed') / COUNT(*), 2) AS `Cancellation Rate` FROM ( SELECT * FROM Trips WHERE Client_Id IN (SELECT Users_Id FROM Users WHERE Banned = 'No' AND Role = 'client') AND Driver_Id IN (SELECT Users_Id FROM Users WHE...
true
36dcb420cb22ad44e1e10ee0f92766e13ca8f6bd
SQL
alexslo/PlaySquerylBootstrap
/conf/evolutions/default/1.sql
UTF-8
435
2.65625
3
[]
no_license
# --- Created by Ebean DDL # To stop Ebean DDL generation, remove this comment and start using Evolutions # --- !Ups create sequence s_contact_id; create table contact ( id bigint DEFAULT nextval('s_contact_id'), name varchar(255), telephone varchar(255...
true
7742371a41b15ec706bca756dbb097e38c33b016
SQL
dbalinux237/OraclePerfSurvivalGuide
/Ch10/semijoin2.sql
UTF-8
5,061
3.375
3
[]
no_license
/* Formatted on 2008/11/21 22:34 (Formatter Plus v4.8.7) */ SPOOL semijoin SET serveroutput on ALTER SESSION SET tracefile_identifier=semijoin; SET lines 120 SET pages 10000 SET timing on SET echo on DROP TABLE google_customers; DROP TABLE microsoft_customers; CREATE TABLE google_customers (cus...
true
63cb56cd2b32f8d666e2226e5cee340862d2d9df
SQL
yaozd/com.yzd.transaction.root
/com.yzd.transaction.root/.doc/sql/myth-mysql.sql
UTF-8
3,561
3.453125
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : 192.168.1.234-myth Source Server Version : 50724 Source Host : 192.168.1.234:3306 Source Database : myth_account Target Server Type : MYSQL Target Server Version : 50724 File Encoding : 65001 Date: 2019-01-04 17:17:15 */ SET FOREIGN_K...
true
64b6ac29e40d749d56d4d428548b4dcee7fda995
SQL
Strycnine/BDD_Immo
/Requêtes/Full/Requetes.sql
UTF-8
4,815
3.984375
4
[]
no_license
--------------- Question n°1 --------------- -- /!\ BETWEEN inclusif ou exclusif /!\ SELECT count(Datemutation) AS 'Vente semestre 1' FROM data WHERE Typelocal = 'Appartement' AND Datemutation BETWEEN '2020-01-01' AND '2020-06-30'; --------------- Question n°2 --------------- SELECT Nombrepiecesprincipa...
true
f522d269215342b41cc329d2ad1cdde55f531fa8
SQL
Ensembl/ensembl
/sql/patch_37_38.sql
UTF-8
7,671
3.625
4
[ "GPL-1.0-or-later", "Artistic-2.0", "Artistic-1.0", "Apache-2.0", "Artistic-1.0-Perl" ]
permissive
-- Copyright [1999-2015] Wellcome Trust Sanger Institute and the EMBL-European Bioinformatics Institute -- Copyright [2016-2023] EMBL-European Bioinformatics Institute -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may ob...
true
3fcbc7f248652723780f15d3d4027fb616d3375a
SQL
spkellydev/project-2
/app/db/locate.sql
UTF-8
377
3.265625
3
[]
no_license
use helpinghand_db; SELECT id, first_name, last_name, guest_count, X(location) AS 'latitude', Y(location) AS 'longitude', ( GLength( LineStringFromWKB( LineString( location, GeomFromText('POINT(51.5177 -0.0968)') ) ) ) ) ...
true
903b72d70e2f693b207527b20066a3c057f1b1cb
SQL
bafzali/burger
/db/schema.sql
UTF-8
314
3.140625
3
[ "MIT" ]
permissive
-- Drops the burgers_db if it exists currently -- DROP DATABASE IF EXISTS burgers_db; -- Creates the "burgers_db" database -- CREATE DATABASE burgers_db; USE burgers_db; CREATE TABLE burgers ( id INT NOT NULL AUTO_INCREMENT, burger_name VARCHAR(40) NOT NULL, devoured BOOLEAN NOT NULL, PRIMARY KEY (id) );
true
8c02d77aae5421183c7263d1c0693799a8275e00
SQL
rbmayer/popcan2
/backend/vagrant/create_tables.sql
UTF-8
886
3.09375
3
[]
no_license
-- Create MySQL tables USE popcan; CREATE TABLE IF NOT EXISTS location (location_id int PRIMARY KEY, location_name text); CREATE TABLE IF NOT EXISTS material (material_id int PRIMARY KEY, material_name text); CREATE TABLE IF NOT EXISTS recycling (recycling_id int auto_increment PRIMARY KEY, material_id int, location_i...
true
e96109bef62bce1e780a4c4189a1c4d67cca5f25
SQL
davidema79/credit-card-wallet
/wallet-backend/ewallet-script.sql
UTF-8
1,143
3.515625
4
[ "MIT" ]
permissive
DROP DATABASE IF EXISTS `ewallet`; CREATE DATABASE `ewallet`; DROP TABLE IF EXISTS `ewallet`.`users`; CREATE TABLE `ewallet`.`users` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `username` varchar(45) NOT NULL DEFAULT '', `password` varchar(255) NOT NULL DEFAULT '', `role` varchar(10) NOT NULL DEFAULT ''...
true
fe283b1c141ad0b28d25f0abeb0dbd80fc232049
SQL
benjaminhshim/Bamazon
/bamazonDeptSeeds.sql
UTF-8
986
3.078125
3
[]
no_license
USE bamazon; CREATE TABLE departments ( department_id INT NOT NULL AUTO_INCREMENT, department_name VARCHAR(50) NULL, over_head_costs DECIMAL(10,2), PRIMARY KEY (department_id) ); INSERT INTO departments (department_name, over_head_costs) VALUES ('Phones', 25000); INSERT INTO departments (department_name, ov...
true
db2f84210fb1433ace84ec7570e4b3fb169e717f
SQL
DalavanCloud/samza-hello-samza
/src/main/java/samza/examples/sql/samza-sql-stream-table-join/src/main/sql/samza.sql
UTF-8
366
2.5625
3
[ "CPL-1.0", "BSD-3-Clause", "Apache-2.0", "BSD-2-Clause", "MIT" ]
permissive
-- NOTE: Join Operator is currently not fully stable, -- we are actively working on stabilizing it. -- Enrich PageViewEvent with member profile data INSERT INTO kafka.tracking.EnrichedPageVIewEvent SELECT * FROM Kafka.PageViewEvent as pv JOIN Kafka.ProfileChanges.`$table` as p ON pv.memberid = p.memberid ...
true
e15d5ab82f4766f24b67ae2b1333b4191a92ce47
SQL
sailong/zhongkeyun-wanglai
/sqlfile/dbm.soulv.com (1).sql
UTF-8
23,148
3.453125
3
[ "Apache-2.0" ]
permissive
-- phpMyAdmin SQL Dump -- version 3.5.7 -- http://www.phpmyadmin.net -- -- 主机: dbm.soulv.com -- 生成日期: 2014 年 03 月 10 日 17:26 -- 服务器版本: 5.1.36-log -- PHP 版本: 5.3.13 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_CHARA...
true
5848f503d3182ff1e7898ddd873d95f17b498b01
SQL
singleparadox/BakaAG
/project-eshop.sql
UTF-8
24,365
3.078125
3
[ "Apache-2.0" ]
permissive
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Apr 08, 2018 at 09:24 PM -- Server version: 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_CL...
true
b0222c04039b519a1d3e30a8173476e1cfbb8f75
SQL
samurairukasu/Desarrollo
/CONTROLES CABA/OLD/Control - Pagos que no estan en Tdetallespago vs Tdatosturnoshistorial.sql
UTF-8
1,141
3.203125
3
[]
no_license
--Controlar que todos pagoidverificacion (pagos) asociados a los turnos con inspecciones Obligatorias --que no pertenecen a Excentos, se encuentren descargados en Tdetallespago select fechaturno, turnoid, dvdomino, pagoidverificacion, ausente, facturado, reviso from cabasm.tdatosturnohistorial where fechaturno >= to_da...
true
887c174328f0ee146b967696170c9042037b0cb1
SQL
google-code/app-zhang
/AppZhang/files/db.sql
UTF-8
4,435
2.953125
3
[]
no_license
/* Navicat MySQL Data Transfer Source Server : localhost_3306 Source Server Version : 50151 Source Host : localhost:3306 Source Database : udb_weihuaronaldo Target Server Type : MYSQL Target Server Version : 50151 File Encoding : 65001 Date: 2013-07-26 14:17:11 */ S...
true
5063d01cd7744de724fbc8a81d03c735913ba7dd
SQL
FenglinAmiee/docMan
/docman/init_table_and_data.sql
UTF-8
2,837
3.078125
3
[ "MIT" ]
permissive
/* SQLyog Ultimate v12.09 (64 bit) MySQL - 5.7.28-log : Database - docman ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE=''*/; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREI...
true
6efc153bf2a24733217b4941f6403e7d733be2bd
SQL
bcahlit/supplier_manage_system_graduation_design
/db/development.sqlite3.sql
UTF-8
34,954
2.890625
3
[]
no_license
BEGIN TRANSACTION; CREATE TABLE IF NOT EXISTS `users_roles` ( `user_id` integer, `role_id` integer ); INSERT INTO `users_roles` (user_id,role_id) VALUES (1,1); INSERT INTO `users_roles` (user_id,role_id) VALUES (2,1); CREATE TABLE IF NOT EXISTS `users` ( `id` integer NOT NULL PRIMARY KEY AUTOINCREMENT, `user_name` ...
true
19d12359e550eca948976514801ff8da0ab131d4
SQL
Juandavid9909/cursoSQLServer
/04. Operadores.sql
ISO-8859-10
2,027
3.6875
4
[]
no_license
-- AND SELECT * FROM Producto WHERE PrecioEspecial > 8 AND Stock <= 8; -- OR SELECT * FROM Producto WHERE ProductoID > 6 OR Stock > 5; SELECT * FROM Producto WHERE ProductoId > 4 OR Nombre = 'Pan'; -- IN SELECT * FROM Maestro WHERE Nombre IN ('Elmer', 'Mirna'); SELECT * FROM Maestro WHERE Edad IN (20, 18); -- LIKE S...
true
dfdaaadc808d0ccd79b4620d4c97d2318a12d897
SQL
582496630/Project-20
/JavaPrj_18/18.sql
UTF-8
3,437
3.25
3
[]
no_license
-- -------------------------------------------------------- -- 主机: 127.0.0.1 -- 服务器版本: 5.7.15-log - MySQL Community Server (GPL) -- 服务器操作系统: Win64 -- HeidiSQL 版本: 9.3.0.4999 -- --------------------------------------------------------...
true
d1ac35a21539356c4b5f9d86afab94cd263b3296
SQL
kulsxyz7/MySql
/many_to_many/challenge6.sql
UTF-8
807
4.03125
4
[]
no_license
-- CHALLENGE 6 - REVIEWERS STATS SELECT first_name, last_name, COUNT(rating) AS COUNT, IFNULL(MIN(rating), 0) AS MIN, IFNULL(MAX(rating), 0) AS MAX, ROUND(IFNULL(AVG(rating), 0), 2) AS AVG, CASE WHEN COUNT(rating) >= 10 THEN 'POWER USER' WHEN COUNT(rating) > 0 THEN 'ACTIVE'...
true
3b5b337b6f9ce09a06cbcaafeaa8ac6ceaba2ed5
SQL
deniscpaula/TG-Fatec-code
/banco.sql
UTF-8
5,798
3.625
4
[]
no_license
drop schema devops; CREATE SCHEMA devops DEFAULT CHARACTER SET utf8; create table devops.empresa ( codigo int NOT NULL AUTO_INCREMENT, nome_fantasia varchar(70) NOT NULL, razao_social varchar(150), status boolean, CONSTRAINT pk__empresa__codigo PRIMARY KEY (codigo) ); create table devops.usuario ( codigo int NO...
true
fd3e569d1e7b566692eaf99f51f8bddc1e6644ba
SQL
zhouwenbin00/xc-service
/other/mysql/xc_order_task.sql
UTF-8
3,237
2.875
3
[]
no_license
/* SQLyog v10.2 MySQL - 5.7.21-log : Database - xc_order ********************************************************************* */ /*!40101 SET NAMES utf8 */; /*!40101 SET SQL_MODE = ''*/; /*!40014 SET @OLD_UNIQUE_CHECKS = @@UNIQUE_CHECKS, UNIQUE_CHECKS = 0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS = @@FOREIGN_KEY_C...
true
533b7650612fe466dca17f99958524bc61d36fb5
SQL
ezenteam2/EzenCrowdFunding
/gr2_kht/Servers/Scripts/b04_change_structure.sql
UTF-8
4,334
4.28125
4
[]
no_license
/* # 테이블 구조 변경 1. alter table => 컬럼추가, 삭제, 타입이나 길이를 재정의 2. 컬럼 추가 - alter table ... add - 추가된 컬럼은 테이블의 마지막 컬럼 다음에 추가, 위치 지정 불가능 => 위치 지정이 필요한 경우 테이블을 복사하는 형식으로 임시 테이블을 만들고, 기존의 테이블을 drop - 추가된 컬럼에도 기본 값 지정 가능 - 수정할 테이블에 기존 데이터가 존재하는 경우 컬럼 값은 null로 입력 가능 - 기본 형식 alter table 테이블명 add 컬럼명 데이터type d...
true
6fb3bec529381faf0b8eb55a3cf1993e81f55a86
SQL
Bhavadharini15/MYSQL
/player/update.mysql
UTF-8
488
2.875
3
[]
no_license
create database company; use company; create table employee ( ID int, NAME char(10), AGE int, ADDRESS char(20), SALARY int); INSERT INTO employee values('1','Ramesh','32','ahmedabad','2000'),('2','khilan','25','delhi','1500'),('3','kaushik','23','kota','2000'),('4','chaitali','25','mumbai','6500'),('5','hardik','...
true
6fe37402e75e15b56fb5602f08a23b14f099f79d
SQL
Dule-martins/X-Messenger-v1.0
/database/im.sql
UTF-8
8,595
3.046875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Dec 04, 2019 at 12:59 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
5b08000b95ccb0e577ef67e81211ea929a78bf15
SQL
thebravoman/elsys-db-practices
/exam_2014/exam_third/12a_28_filipmostafa/task.sql
UTF-8
1,267
3.234375
3
[]
no_license
1 CREATE TABLE Article (url VARCHAR(256), published_on DATE, content LONGTEXT); CREATE TABLE Category (id INT, created_by STRING, name VARCHAR(256)); CREATE TABLE User (id INT, created_on DATE, age INTEGER, password VARCHAR); A CREATE TABLE Tag (id INT, Tag priority INTEGER, name VARCHAR(256)); 2 ALTER TABLE Category A...
true
1300e819cafe8d597bc19ce07cfa44f6263741e2
SQL
mattbishop/sql-event-store
/sqlite-event-store.ddl
UTF-8
2,500
4.625
5
[ "Unlicense" ]
permissive
-- SQLITE event store PRAGMA foreign_keys = ON; DROP TABLE IF EXISTS events; DROP TABLE IF EXISTS entity_events; CREATE TABLE entity_events ( entity TEXT NOT NULL, event TEXT NOT NULL, PRIMARY KEY (entity, event) ON CONFLICT IGNORE ); CREATE TABLE events ( entity TEXT NOT NULL, entityKey TE...
true
5cbe2379ae1752587bbc110542b9f42f1f478fb4
SQL
devatsrs/neon.web
/dbv-2/data/schema/prc_autoUpdateTrunk.sql
UTF-8
1,560
3.109375
3
[ "MIT" ]
permissive
CREATE DEFINER=`root`@`localhost` PROCEDURE `prc_autoUpdateTrunk`( IN `p_CompanyID` INT, IN `p_CompanyGatewayID` INT ) BEGIN UPDATE RMCDR3.tblUsageDetails INNER JOIN RMCDR3.tblUsageHeader ON tblUsageDetails.UsageHeaderID = tblUsageHeader.UsageHeaderID INNER JOIN Ratemanagement3.tblCustomerTrunk ON tblCustomer...
true
1267e6eb4534750787003168fef24b6436979824
SQL
kerecsenlaci/ClientRegistry
/Data/registrydataTest.sql
UTF-8
8,201
3.140625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.0 -- https://www.phpmyadmin.net/ -- -- Gép: 127.0.0.1 -- Létrehozás ideje: 2017. Okt 12. 09:19 -- Kiszolgáló verziója: 10.1.26-MariaDB -- PHP verzió: 7.1.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_...
true
d8e9d6af7b3a3aa761cc4482da4e9817e7fe531d
SQL
joeytierney/gerrys-jukebox
/SQL_Dump/gerrys_db_users.sql
UTF-8
2,794
2.96875
3
[]
no_license
-- MySQL dump 10.13 Distrib 5.7.17, for Win64 (x86_64) -- -- Host: localhost Database: gerrys_db -- ------------------------------------------------------ -- Server version 5.7.20-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS *...
true
82431b495b15557efbee970500048e399bd5487b
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/low/day27/select1114.sql
UTF-8
262
3
3
[]
no_license
SELECT sen.name FROM SENSOR sen, SENSOR_TYPE st, COVERAGE_INFRASTRUCTURE ci WHERE sen.SENSOR_TYPE_ID=st.id AND st.name='WiFiAP' AND sen.id=ci.SENSOR_ID AND ci.INFRASTRUCTURE_ID=ANY(array['4204','3208','5044','3221','4084','2019','5048','5234','6032','6049'])
true
0495d8d9d6572f497e35ec2308fc84f967f78c80
SQL
issamYahiaoui/ModarisKas
/modarskas.sql
UTF-8
38,004
2.953125
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.7.7 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Apr 25, 2018 at 05:27 PM -- Server version: 5.6.38 -- PHP Version: 7.2.1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Database: `spoc` -- -- ------------------------------------...
true
de6b982007e4a3e5ecc804b52a7665aa6905bde6
SQL
vldzm1015/Oracle-SQL-study
/[ 복습 ] DDL + DML.sql
UHC
5,271
3.59375
4
[]
no_license
CREATE TABLE GOGEK ( ID VARCHAR2(16), NAME VARCHAR2(10) NOT NULL, TEL CHAR(12), CONSTRAINT PK_GOGEK_ID PRIMARY KEY ( ID ), CONSTRAINT uq_GOGEK_GOGEK UNIQUE (TEL) ); CREATE TABLE SANGPUM ( NO VARCHAR2(12), TITLE VARCHAR2(20) NOT NULL, DETAIL V...
true
f27c547f058b9134ed993190af069348b08d7779
SQL
syobj/CBLabsSource
/DB_DDL.sql
UTF-8
4,342
2.96875
3
[]
no_license
/* Navicat Premium Data Transfer Source Server : localhost Source Server Type : MySQL Source Server Version : 50719 Source Host : localhost:3306 Source Schema : test1 Target Server Type : MySQL Target Server Version : 50719 File Encoding : 65001 Date: 28/02/2018 08:2...
true
58fa2f1746f3505e45cacb56658b04f781e671c7
SQL
AUnderwood9/finalproject
/server/src/sql/tables/tables.sql
UTF-8
2,659
3.5625
4
[]
no_license
DROP TABLE IF EXISTS Users; CREATE TABLE Users ( id int(11) NOT NULL AUTO_INCREMENT, firstname varchar(60) DEFAULT NULL, lastname varchar(60) DEFAULT NULL, email varchar(80) NOT NULL, password varchar(256) NOT NULL, handle varchar(70) NOT NULL, _created datetime DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (...
true
6aa7dc3070bb0e5f737fb0d39efded5a6eb01a5c
SQL
mahendrakalkura/nashboard.com
/files/3.sql
UTF-8
447
3.1875
3
[]
no_license
SET FOREIGN_KEY_CHECKS = 0; DROP TABLE IF EXISTS `visitors`; CREATE TABLE IF NOT EXISTS `visitors` ( `id` INT(11) UNSIGNED NOT NULL AUTO_INCREMENT, `email` VARCHAR(255) COLLATE utf8_unicode_ci NOT NULL, `timestamp` DATETIME NOT NULL, PRIMARY KEY (`id`), UNIQUE KEY `email` (`email`), KEY `timest...
true
d3217aa34801939e30bcc7049925750f98d47786
SQL
DeyanParushev/MyStudentProjects
/MS SQL/More Excercises/Exam Prep 1/Problem 8.sql
UTF-8
223
4.15625
4
[]
no_license
SELECT F.Id, F.[Name], CONVERT(NVARCHAR(50), F.Size) + 'KB' AS [Size] FROM Files AS F LEFT JOIN Files AS FA ON F.Id = FA.ParentId WHERE FA.Id IS NULL ORDER BY F.Id ASC, F.[Name] ASC, F.Size DESC
true
493188fe54e85ac1e1945f029512acdd76f2503d
SQL
YanfeiC/HappyForum
/src/main/resources/schema.sql
UTF-8
2,471
3.8125
4
[]
no_license
CREATE TABLE users ( username VARCHAR(50) NOT NULL PRIMARY KEY, password VARCHAR(255) NOT NULL, enabled BOOLEAN NOT NULL, email VARCHAR(255), join_time DATETIME NOT NULL, avatar VARCHAR(255) NOT NULL, description VARCHAR(255), last_visit DATETIME, credit INT(11) ...
true
7f9e2447d5da930a0e78f34f7f8164c408fc9eb0
SQL
AbhijithNaagarjuna/Review-API
/src/main/resources/db/migration/V1_2__create_comment.sql
UTF-8
994
4
4
[]
no_license
CREATE TABLE IF NOT EXISTS product ( prod_id INT AUTO_INCREMENT, prod_name VARCHAR(200) NOT NULL, prod_description VARCHAR(500) NOT NULL, created_time TIMESTAMP NOT NULL, constraint order_pk primary key (prod_id) ); CREATE TABLE IF NOT EXISTS review ( review_id INT AUTO_INCREMENT, review_ti...
true
bf11c84c339b463af970d79e7e93fe942f3ead57
SQL
jiandongc/ecommerce
/product/src/main/database/deltas/0021_create_price_table.sql
UTF-8
258
2.8125
3
[]
no_license
CREATE TABLE price ( id serial PRIMARY KEY, price double precision not null, start_date date not null, end_date date, discount_rate varchar(50), creation_time timestamp default now(), sku_id integer REFERENCES sku (id) NOT NULL );
true
dc502b81701cf868e918b46cb2751636f6f3784e
SQL
shailkan/OnlineEditor
/src/main/resources/migrations/V5__comments.sql
UTF-8
389
2.765625
3
[]
no_license
CREATE TABLE IF NOT EXISTS comments( commentId SERIAL PRIMARY KEY, commentText TEXT, timeOfComment TIMESTAMP, contentId SERIAL REFERENCES data(contentId), ...
true
08254bbbaeebfe19019ff6e5ccf300a72479a3b7
SQL
thaabit-jacobs/School-Management-System
/target/heroku/app/target/classes/scripts/create_tables.sql
UTF-8
2,212
3.484375
3
[]
no_license
create table if not exists admins( id int primary key not null, first_name varchar(225) not null, last_name varchar(225) not null, email varchar(225) not null, mobile_no varchar(225) not null, dob timestamp not null, role varchar(225) not null, date_created timestamp not null ); create ...
true
cc4bf5dddbca862ce1d19db28cfa0cf3dc36825d
SQL
bmcveigh/Reception
/lib/reception_DB_setup.sql
UTF-8
5,520
3.5
4
[]
no_license
/* -------------- Set up tables portion ---------------- */ DROP TABLE IF EXISTS `RESERVATION`; DROP TABLE IF EXISTS `GUEST`; DROP TABLE IF EXISTS `ROOM`; DROP TABLE IF EXISTS `ROOM_CATEGORY`; DROP TABLE IF EXISTS ADMIN; CREATE TABLE IF NOT EXISTS `GUEST` (`G_ID` int(10) PRIMARY KEY,`G_FIRST` CHAR(50),`G_LAST` CHAR(50...
true
9563df27b547705aaf4ef4515f0cf96e79ee41dd
SQL
HoChangSUNG/DatabaseWithOraclePractice
/A. SQL Practice/NtileAndRank.sql
UHC
1,638
4.625
5
[]
no_license
-- --NTILE() ̿Ͽ μ ޿ հ -- ޿ հ ū ->1, ->4 bucket() , Bucket() select department_id, sum(salary),ntile(4) over(order by sum(salary) desc) as "Bucket#" from employees group by department_id order by 3; --1 -- Ҽӵ μ ޿ -- rank(),dense_rank(),row_number() ̿ select employee_id,last_name,salary,department_id ...
true
6b4427336b76a6b2a8e117cdf6abd8b2398f6949
SQL
silence-do-good/stress-test-Postgres-and-MySQL
/dump/high/day15/select0031.sql
UTF-8
178
2.671875
3
[]
no_license
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o WHERE timestamp>'2017-11-14T00:31:00Z' AND timestamp<'2017-11-15T00:31:00Z' AND temperature>=45 AND temperature<=94
true
261ea7c298c2aae1c4082944dc3fa5bfd9dbed48
SQL
xeonye/x-collaborative-framework
/src/Membership/Membership/db/Functions_MySQL/func_GetDepartmentLevelByOrganizationUnitId.sql
GB18030
1,024
3.546875
4
[]
no_license
DROP FUNCTION IF EXISTS `func_GetDepartmentLevelByOrganizationUnitId`; CREATE FUNCTION `func_GetDepartmentLevelByOrganizationUnitId`(OrganizationUnitId VARCHAR(50)) RETURNS varchar(50) BEGIN DECLARE OrganizationUnitType VARCHAR(10); DECLARE BackwardCount INT; SET BackwardCount = 1; SELECT Id, Type INTO Organi...
true
0baa3b8601f56bbf558bbddf07bec26d3a9a822a
SQL
pinalikefruit/SQL
/project_library/Other Queries.sql
UTF-8
2,627
4.1875
4
[]
no_license
--Other Queries INSERT INTO `clients`(`name`,email,birthdate,gender,active) VALUES('Jose Hidalgo','Jose.05903641R@random.names','1973-08-13','M',0) ON DUPLICATE KEY UPDATE active= VALUES(active); SELECT * FROM clients WHERE client_id = 100\G; SHOW TABLES LIKE '%i%' -- Querys Anidados INSERT INTO books(title, author_...
true
a003788429eab0735598ac1b79fb9533bde841e7
SQL
iliankostov/SoftUni
/Databases/Homework/05-Advanced-SQL-Homework/04-SQL-query-to-find-the-average-salary-in-the-department-one/EmployeesAvgSalaryOnDepartment1.sql
UTF-8
124
3
3
[]
no_license
select avg(Salary) from Employees as e inner join Departments as d on e.DepartmentID=d.DepartmentID where d.DepartmentID = 1
true
d47ce5665830f686794c786163071fecff034347
SQL
eversonclei/vue-vuex-axios-jwt-auth-api-node-postgresql
/database/Scritps.sql
UTF-8
874
3.4375
3
[ "MIT" ]
permissive
/* Scripts: Autenticação de usuários em Vue + Bootstrap-Vue + Vue-Gravatar + Vue-Toasted + Axios + JWT + Backend NodeJS + PostgreSQL !!! Autor: Everson Clei */ CREATE DATABASE auth WITH OWNER = postgres ENCODING = 'UTF8'; CREATE TABLE public.users ( id SERIAL, name VARCHAR(100), email VARCHAR(100), pas...
true
81f5a0bb5cc1bc951a02f29a2fb228deb1380e16
SQL
ReactFox/601235-yeticave-10
/schema.sql
UTF-8
1,655
3.484375
3
[]
no_license
CREATE DATABASE yeticave_db DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci; USE yeticave_db; CREATE TABLE categories ( id INT(12) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY, category_title CHAR(64) NOT NULL UNIQUE, symbolic_code CHAR(64) NOT NULL UNIQUE );...
true
ea264c4876c24ede8470151ceac842dad73872f6
SQL
cosimosimeoneTR/sqlScripts
/oracle/sas.sql
UTF-8
477
3.296875
3
[]
no_license
break on tablespace skip 1 on qcsid skip 1 compute sum label QCSID of BLOCKS on qcsid compute sum label QCSID of MEGA on qcsid compute sum label TABLESPACE of BLOCKS on TABLESPACE compute sum label TABLESPACE of MEGA on TABLESPACE select a.sid ,b.tablespace ,b.blocks ,((b.blocks * 32)/1024)...
true
4c00c6740fc4d113fee4be0dabb69247be1bc5ef
SQL
chimerast/karatachi-portus
/portus-core/src/main/java/org/karatachi/portus/core/dao/NodeDao_selectReplicationSource.sql
UTF-8
155
3.25
3
[]
no_license
SELECT node.* FROM node JOIN storedinfo ON node.id=storedinfo.node_id WHERE status=1 AND file_id=/*file_id*/ ORDER BY random() LIMIT 1
true
7592153261d4a12301b9b9962dd6f5a22c1fd5c1
SQL
staplezz/bdd2019
/Practica 9/DML/inserciones.sql
UTF-8
33,182
2.640625
3
[]
no_license
--Inserciones para la nueva base de datos. --Tabla Persona. insert into Persona (idPersona, Nombre, APaterno, AMaterno, FechaNac, Direccion) values (1, 'Meghann', 'Blackler', 'Tevlin', '1947-02-01', '3894 Mitchell Avenue'); insert into Persona (idPersona, Nombre, APaterno, AMaterno, FechaNac, Direccion) values (2, 'Mi...
true
7248e85d23f245cc88c4c730fb3bee44542c99c7
SQL
MDshuey/Portfolio
/Part 5- Knotkeeper/KhipuDB_SQL/collca_termiantion_dc.sql
UTF-8
2,436
2.9375
3
[]
no_license
CREATE DATABASE IF NOT EXISTS `collca` /*!40100 DEFAULT CHARACTER SET latin1 */; USE `collca`; -- MySQL dump 10.13 Distrib 5.5.16, for osx10.5 (i386) -- -- Host: khipu-web01.fas.cloud.huit.harvard.edu Database: collca -- ------------------------------------------------------ -- Server version 5.5.61-log /*!40101 ...
true
269ab5ecd55c4171b284d666da4b89e689825044
SQL
rt-oliveira/Programas-e-Exercicios-de-tutoriais
/SQL/Função MAX.sql
UTF-8
706
3.921875
4
[]
no_license
-- Exemplo de uso da função MAX -- Neste exemplo, é retornado o maior valor do campo -- 'daily_typing_pages' dentre todos os registros da tabela -- employee_tbl. SELECT MAX(daily_typing_pages) FROM employee_tbl; -- No segundo exemplo, abaixo, é consultado o maior valor de -- 'daily_typing_pages' considerando, desta v...
true
444002140ed942d435959edb178b0622edbe9f59
SQL
pkptissera080/COVID-19
/Database/covid-19.sql
UTF-8
2,576
3.375
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Aug 19, 2020 at 01:43 AM -- 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
b9fc6452142a2e6ac56044b1d14ad8e9172dec08
SQL
Nazar32/SocialNetwork
/others/base_city/base_city.sql
ISO-8859-1
65,471
2.828125
3
[]
no_license
DROP DATABASE IF EXISTS base_city; CREATE DATABASE base_city DEFAULT CHARACTER SET 'utf8'; USE base_city; create table cities ( city_id int(11) NOT NULL AUTO_INCREMENT, zone_id int(11) NOT NULL, name varchar(50) NOT NULL, free_shipping int NOT NULL, PRIMARY KEY (city_id) ) engine=InnoDB; create table regions...
true
396e5a288e069c8fc090e814bb2056ab139ea922
SQL
anujpal82/Training-Feb-2021
/Modules/SQL/Day10/Jinal Shah/Assignment.sql
UTF-8
1,247
4.1875
4
[]
no_license
/* Using cursor implement the following task employee Update the salary of the employee using following condition Salary between 30000 and 40000 — 5000 hike Salary between 40000 and 55000 — 7000 hike Salary between 55000 and 65000 — 9000 hike */ SELECT EmployeeID,Salary FROM Employees WHERE Salary>30000...
true
8197c7d274581e635386a412a856643b310b43e1
SQL
steven938/Shopify-Data-Science-Challenge
/answers.sql
UTF-8
1,543
4.15625
4
[]
no_license
select product, placed_on, price from order_items left join product_variations on order_items.product_variation=product_variations.id left join orders on order_items.order = orders.id order by product, placed_on; # Counts number of price changes select product, count(distinct price) as number_changes from order_item...
true
1aa381a9b1ee77f70f535e9d59547e3da3586a9c
SQL
UmaruChan23/backend
/docker/db/initDB.sql
UTF-8
334
2.515625
3
[]
no_license
CREATE DATABASE sensors; CREATE TABLE IF NOT EXISTS metrics ( id BIGINT PRIMARY KEY , version integer NOT NULL, sensor_id integer NOT NULL , time_stamp bigint NOT NULL , sensor_value smallint NOT NULL ); CREATE TABLE IF NOT EXISTS detectors ( sensor_id BIGINT PRIMARY KEY , name VARCH...
true
0c43a8aabdb2ce7db3582116eeba355851bd1d00
SQL
rakanugro/backoffice
/backoffice.sql
UTF-8
3,723
2.6875
3
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
-- phpMyAdmin SQL Dump -- version 5.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jul 28, 2020 at 09:56 AM -- Server version: 10.4.11-MariaDB -- PHP Version: 7.2.28 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
true
8da108e5bdaacdeb32e0ae8c4e6386b414a6a1ad
SQL
dxcv/repo_dp
/DPP/Desarrollo/Python/informe_rentabilidades/querys/Respaldo Querys/AUM.sql
UTF-8
318
3.640625
4
[]
no_license
select ltrim(rtrim(c.codigo_fdo)) as codigo_fdo, SUM(c.monto) as AUM from ZHIS_Carteras_Main as c INNER JOIN fondosir as f ON f.Codigo_fdo = c.codigo_fdo collate database_default where fecha ='AUTODATE' and f.shore= 'onshore' and f.estrategia in ('renta fija' , 'credito', 'retorno absoluto') GROUP BY c.codigo_fdo
true
3f45bbda202302afeae7ad8fb360692caddda8f1
SQL
pierophp/pinyin
/api/sql/dictionary.sql
UTF-8
1,198
2.828125
3
[]
no_license
-- DICIONARIO SELECT SUM(IF(definition_unihan IS NOT NULL AND definition_unihan != 'null', 1, 0)) definition_unihan, SUM(IF(definition_cedict IS NOT NULL AND definition_cedict != 'null', 1, 0)) definition_cedict, SUM(IF(definition_pt IS NOT NULL AND definition_pt != 'null', 1, 0)) definition_pt, SUM(IF(definition...
true
5b2901826b6839d51974216bd6e39b85c9b73f27
SQL
lomo-y/RandL
/project/db/user_primary_info_tb.sql
UTF-8
884
2.6875
3
[]
no_license
SET FOREIGN_KEY_CHECKS=0; -- ---------------------------- -- Table structure for user_primary_info_tb -- ---------------------------- DROP TABLE IF EXISTS `primary_user_info_tb`; CREATE TABLE `primary_user_info_tb` ( `user_id` bigint(20) NOT NULL, `username` varchar(255)BINARY DEFAULT NULL, `nickname` nvarchar(2...
true
0f9279e5f0a4a504e9e7cb152dfe1f949afb20c2
SQL
NShekhar012/abcd
/sql/abcd_db.sql
UTF-8
27,382
3.0625
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.9.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 22, 2020 at 06:22 PM -- Server version: 10.3.16-MariaDB -- PHP Version: 7.3.7 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @O...
true
098c4c7bf662d4c2e18e2595837bb11e20e5e70e
SQL
theboocock/OtagoGalaxy
/src/ensembl-variation/modules/t/test-genome-DBs/homo_sapiens/variation/read_coverage.sql
UTF-8
607
2.53125
3
[]
no_license
-- MySQL dump 10.9 -- -- Host: ecs2 Database: _test_db_homo_sapiens_variation_dr2_25_11_12432 -- ------------------------------------------------------ -- Server version 4.1.12-log -- -- Table structure for table `read_coverage` -- CREATE TABLE `read_coverage` ( `seq_region_id` int(11) NOT NULL default '0', `...
true
4effcdd32ccb3990530818cd77395f8759961482
SQL
JetBrains/NuGetOperations
/Source/NuGetGallery.Operations/Scripts/DownloadReport_RecentPopularityByPackage.sql
UTF-8
517
3.6875
4
[ "Apache-2.0" ]
permissive
SELECT Dimension_Package.PackageVersion, SUM(DownloadCount) 'Downloads' FROM Fact_Download INNER JOIN Dimension_Package ON Dimension_Package.Id = Fact_Download.Dimension_Package_Id INNER JOIN Dimension_Date ON Dimension_Date.Id = Fact_Download.Dimension_Date_Id WHERE Dimension_Date.[Date] >= CONVERT(DATE, DATEADD(day,...
true
2121ed6ab83d40daca3f90db29dbb8101119489f
SQL
Sunksat/aowow_comments
/aowow_comments_dbvanilla/aowow_comments_rates_wh.sql
UTF-8
525
2.609375
3
[ "MIT" ]
permissive
SET FOREIGN_KEY_CHECKS=0; -- ---------------------------- -- Table structure for `aowow_comments_rates_wh` -- ---------------------------- DROP TABLE IF EXISTS `aowow_comments_rates_wh`; CREATE TABLE `aowow_comments_rates_wh` ( `commentid` bigint(20) unsigned NOT NULL DEFAULT '0' COMMENT 'Comment ID', `use...
true
0bd6761fe55da780cf0d4a7e2cba028be2d2f771
SQL
ahermundson/prime-solo-sql
/solution.sql
UTF-8
840
3.640625
4
[]
no_license
-- 1. SELECT * FROM syntax_practice WHERE city = 'chicago'; --2. SELECT * FROM syntax_practice WHERE username LIKE '%a%'; --3. UPDATE syntax_practice SET account_balance = 10.00 WHERE account_balance = 0.00 and transactions_attempted = 0; --4. SELECT * FROM syntax_practice WHERE transactions_attempted >= 9; --5. SE...
true