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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
03bf279972d9f965d2bddbec632a72edc83ed6cc | SQL | jackryan135/COEN178Lab | /labs/lab6/jryanLab6/bankTables.sql | UTF-8 | 486 | 3.390625 | 3 | [] | no_license | Create table BANKCUST_6 (
custno VARCHAR(5) Primary Key,
custname VARCHAR(20),
street VARCHAR(30),
city VARCHAR(20)
);
Create table ACCOUNTS_6 (
AccountNo VARCHAR(5) Primary Key,
accountType VARCHAR(10),
amount NUMBER(10,2),
custno varchar(5),
CONSTRAINT accounts_fkey FOREIGN Key (custno)REFERENCES BANKCUS... | true |
7af251b34b1ea24da615ddf0d595de24f13ce432 | SQL | avmi/hackerrank | /sql/draw-the-triangle-2/solution.mysql.sql | UTF-8 | 170 | 2.921875 | 3 | [] | no_license | /*
Enter your query here.
*/
WITH RECURSIVE seq AS (
SELECT 1 AS num
UNION ALL
SELECT num + 1 FROM seq WHERE num < 20
)
SELECT REPEAT('* ', seq.num) FROM seq
| true |
5e653f82215870bb02fa3ca5d605d20cafe0563d | SQL | mxzhu/TEST | /MyInsider/DBScripts/ScriptsWithDefaultData/000. General Scripts/132. Update Script for Inputs for CO & insider login.sql | UTF-8 | 750 | 3.0625 | 3 | [] | no_license |
IF EXISTS (SELECT * FROM com_MassUploadExcel WHERE MassUploadExcelId = 54)
BEGIN
update com_MassUploadExcel set MassUploadName='Employeewise Restricted List Mass Upload',TemplateFileName='EmployeeWiseRestrictedlistTemplate' where MassUploadExcelId=54
END
IF EXISTS (SELECT * FROM mst_Resource WHERE ResourceKey ='usr_... | true |
2f6a9b4b6cdcb17c01c1600ae5357df4eb446026 | SQL | yatsunenko-anatolii/Parser | /DB/parser_props_chain.sql | UTF-8 | 1,875 | 3.078125 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.9.5deb2
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: Nov 03, 2020 at 06:47 AM
-- Server version: 8.0.22-0ubuntu0.20.04.2
-- PHP Version: 7.4.3
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
... | true |
d30e7cb731e037c26e2656451c7172539b987714 | SQL | Niha8030/DBMS-1BM18CS060 | /ORDER.sql | UTF-8 | 3,577 | 3.390625 | 3 | [] | no_license | create table customers
(
cust_no number(10),
cname varchar2(20),
city varchar2(20),
primary key(cust_no)
);
create table orders
(
order_no number(10),
odate date,
cust_no number(10),
order_amount number(10),
primary key(order_no),
foreign key(cust_no) REFERENCES customers(cust_no)
);
create table item
(
item_no numb... | true |
723134383c005251c9a05570b020f4e56d2b834c | SQL | lucky-LuSir/housekeeper | /.svn/pristine/72/723134383c005251c9a05570b020f4e56d2b834c.svn-base | UTF-8 | 1,743 | 3.390625 | 3 | [] | no_license | ---------信息推送表---------
CREATE SEQUENCE seq_hkp_sys_notice
INCREMENT 1
MINVALUE 1
MAXVALUE 9223372036854775807
START 1
CACHE 1;
ALTER TABLE seq_hkp_sys_notice
OWNER TO hkp;
CREATE TABLE t_hkp_sys_notice (
id BIGINT NOT NULL DEFAULT nextval('seq_hkp_sys_notice'::regclass),
notice_code CHARACTER VARYING,
notice_type... | true |
5afd1dd14fa1e5b5c154165eca60cdef60990a7d | SQL | altamira/visualstudio | /Sistema de Informação Altamira/EGISSQL.Database/dbo/Stored Procedures/Procs2/pr_lancamento_visita_vendedor.sql | UTF-8 | 5,643 | 3.265625 | 3 | [] | no_license |
-------------------------------------------------------------------------------
--pr_lancamento_visita_vendedor
-------------------------------------------------------------------------------
--GBS Global Business Solution Ltda 2004
----------------------------------------------... | true |
8e2cba7ead50983ecd2543bbe0161f3bef71cf30 | SQL | sec-chethan/SpringJOOQ | /librairy-service/src/main/resources/db/migration/V1__Initial_Structure.sql | UTF-8 | 626 | 4.03125 | 4 | [] | no_license | CREATE TABLE AUTHOR (
UUID VARCHAR(64) NOT NULL PRIMARY KEY,
FIRST_NAME VARCHAR(50) NOT NULL,
LAST_NAME VARCHAR(50) NOT NULL
);
CREATE TABLE BOOK (
UUID VARCHAR(64) NOT NULL PRIMARY KEY,
TITLE VARCHAR(100) NOT NULL
);
CREATE TABLE AUTHOR_BOOK (
AUTHOR_UUID VARC... | true |
1a68ca732fadd7f19f8604dd05da61de69fc331f | SQL | charan813/Maven-analytics--MYSQL | /Analyzing website Performance/top_website_entry_page_analysis.sql | UTF-8 | 1,095 | 4.375 | 4 | [] | no_license | -- FINDING THE TOP WEBSITE PAGES
SELECT
website_pageviews.pageview_url,
COUNT(DISTINCT website_pageview_id) AS pageview_count
FROM
website_pageviews
WHERE
created_at < '2012-06-09'
GROUP BY website_pageviews.pageview_url
ORDER BY pageview_count DESC;
-- FINDING THE TOP ENTRY/ LANDING PAGES
-- Step 1: ... | true |
de152ce5d43c82c228280c2bace5c33126831575 | SQL | eguaman1990/PDE | /MODELO_FINAL/pde_final1.2.sql | UTF-8 | 11,849 | 3.359375 | 3 | [] | no_license | /*==============================================================*/
/* DBMS name: MySQL 5.0 */
/* Created on: 28-06-2014 10:19:44 */
/*==============================================================*/
drop table if exists pde.tmp_cargosopciones;... | true |
d27a7f24ea9cfb466117269a2c8c6ce7ac89236b | SQL | rckyrnld/inaexport-sp | /DB/itdp_contact_imp.sql | UTF-8 | 1,250 | 2.75 | 3 | [
"MIT"
] | permissive | /*
Navicat Premium Data Transfer
Source Server : Maxx-JKT
Source Server Type : PostgreSQL
Source Server Version : 100010
Source Host : 115.124.73.253:5432
Source Catalog : kemendag
Source Schema : public
Target Server Type : PostgreSQL
Target Server Version : 100010
Fi... | true |
232cda5ae5d540e7c4ec29e1ba6d14eaecfb3d7b | SQL | matos85/GB_MySQL_2020 | /health.sql | WINDOWS-1251 | 22,400 | 3.5 | 4 | [] | no_license | /*
1:
:
-
.
*/
DROP DATABASE IF exists health;
CREATE DATABASE health;
USE health;
--
DROP TABLE IF EXISTS `Event_usefulness`;
CREATE TABLE `Event_usefulness`(
`Id_event_usefulness` SERIAL PRIMARY KEY,
`Event_usefulness` VARCHAR(200) UNIQUE COMMENT ' '
... | true |
835cde95fb53b56dc68259b80909be474c05cc49 | SQL | doc22940/datawrapper | /migrations/012-add-prod-indices.sql | UTF-8 | 2,582 | 3.296875 | 3 | [
"MIT"
] | permissive | -- Create indices that are present in production.
-- Up
CREATE INDEX action_key_IDX ON action (`key`, user_id);
CREATE INDEX action_action_time_IDX USING BTREE ON action (action_time);
CREATE INDEX chart_idx_is_fork ON chart (is_fork);
CREATE INDEX chart_author USING BTREE ON chart (author_id);
CREATE INDEX chart_in_... | true |
613b39dfcfd9cb49474755a2a8ea16c5cb6032c6 | SQL | SharinaS/book_app | /data/books.sql | UTF-8 | 593 | 3.140625 | 3 | [
"MIT"
] | permissive | DROP TABLE IF EXISTS books;
CREATE TABLE books(
id SERIAL PRIMARY KEY,
author VARCHAR(255),
title VARCHAR(255),
ISBN VARCHAR(255),
image VARCHAR,
description TEXT,
bookshelf VARCHAR(255)
);
INSERT INTO books (author, title, ISBN, image, description, bookshelf) VALUES ('Terry Pratchet', 'Good Omens', '123... | true |
cb455bbca311cba6dad7c348c247fcf2e715ebc5 | SQL | TomWallaceJr/poker-ledger-server | /migrations/001.do.create_users_table.sql | UTF-8 | 207 | 2.546875 | 3 | [] | no_license | CREATE TABLE users (
user_id INTEGER PRIMARY KEY GENERATED BY DEFAULT AS IDENTITY,
username VARCHAR(200) NOT NULL UNIQUE,
password VARCHAR(200) NOT NULL,
email VARCHAR(200) NOT NULL UNIQUE
); | true |
c801561a9e5febaf6625025347f281bea30437c5 | SQL | asettelen/realtime_crypto_pfe | /3.architecture_pour_la_prediction/3.5.scheduled_queries/Windowing_And_Interpolation_Launching.sql | UTF-8 | 2,184 | 3.8125 | 4 | [] | no_license | CREATE OR REPLACE TABLE
temp_crypto_batch.batch_hour_interpo AS
SELECT
*
FROM (
WITH
requests AS (
SELECT
*,
IF
(count IS NULL,
NULL,
STRUCT(tumble AS x,
mean AS y) ) AS coord
FROM (
SELECT
symbol,
timeseries.tumble_interval(timestamp,
... | true |
5a272f0e17132fcf1c616358b5f65e5670570e35 | SQL | aleksandar-work/POS | /swpos.sql | UTF-8 | 23,271 | 2.875 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 5.0.0-rc1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Jul 18, 2020 at 02:16 PM
-- Server version: 10.4.8-MariaDB
-- PHP Version: 7.2.23
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET ... | true |
12cd0b6f280fddeafcb79a041789e4dc62e05c5e | SQL | termlex/Vocabulary-v5.0 | /CPT4/load_stage.sql | UTF-8 | 17,732 | 3.671875 | 4 | [
"Unlicense"
] | permissive | /**************************************************************************
* Copyright 2016 Observational Health Data Sciences and Informatics (OHDSI)
*
* 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 Li... | true |
08b583ba025b9afbec8b715cdbd58ec36a253313 | SQL | visantiago99/MYSQL-vocabulary-booster | /mysql-vocabulary-booster/desafio20.sql | UTF-8 | 548 | 3.78125 | 4 | [] | no_license | DELIMITER $$
CREATE PROCEDURE exibir_historico_completo_por_funcionario(IN email varchar(25))
BEGIN
SELECT CONCAT(e.FIRST_NAME,' ', e.LAST_NAME) AS 'Nome completo',
DEPARTMENT_NAME AS 'Departamento',
JOB_TITLE AS 'Cargo'
FROM hr.employees AS e
INNER JOIN hr.departments AS d
INNER JOIN hr.job_... | true |
52e020940349cc9ad455163e7e5005a69c2499fc | SQL | rachid16/casestudy.fullstack_webapplication | /db scripts/generateTables.sql | UTF-8 | 3,561 | 3.4375 | 3 | [] | no_license | -- -----------------------------------------------------
-- Schema full-stack-ecommerce
-- -----------------------------------------------------
DROP SCHEMA IF EXISTS `full-stack-ecommerce`;
CREATE SCHEMA `full-stack-ecommerce`;
USE `full-stack-ecommerce` ;
-- -----------------------------------------------------
-- ... | true |
192b748b51c982b222a218179db38b8e6d6d4d31 | SQL | lucianobezerra/sga_java | /doc/permissions.sql | UTF-8 | 625 | 3.859375 | 4 | [] | no_license | drop table permissions;
CREATE TABLE permissions (
id int(11) NOT NULL AUTO_INCREMENT,
user_id int(11) NOT NULL,
user_access_id int(11) NOT NULL,
window_id int(11) NOT NULL,
created_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (id),
UNIQUE KEY user_id (user_id,window_id),
KEY fk_permissi... | true |
2621181195a9ae6c5bf3da3a8ab6e70240d9d5f1 | SQL | VedangJoshi/MySQL_Queries | /Procedural.sql | UTF-8 | 385 | 2.53125 | 3 | [] | no_license | (1) delimiter $
create procedure Print3()
begin
select 'Hello World!' as message;
end$
delimiter ;
mysql> source Procedural.sql;
Query OK, 0 rows affected (0.02 sec)
mysql> call Print3;
+--------------+
| message |
+--------------+
| Hello World! |
+--------------+
1 row in... | true |
ebd026715d964ccd63131a2ada442ea8ffc61a86 | SQL | jgrzehowiak/Databases | /Project3.sql | UTF-8 | 13,027 | 3.265625 | 3 | [] | no_license | /* Line 1: John Grzehowiak D10
Line 2: COSC 3380 Fall 2015 Project 1
Line 3: This is MY work
Line 4: Will NOT disseminate */
/* CREATE ENTITY SET TABLES*/
DROP TABLE CUSTOMER CASCADE CONSTRAINTS;
CREATE TABLE CUSTOMER(C_ID INTEGER PRIMARY KEY, LAST CHAR(15), FIRST CHAR(20), MI CHAR(1), DOB DATE, ... | true |
39db3d120cbebc721a0cefb8bd2e2d6c3843c1f2 | SQL | bloff182/pharmacy-spring-boot-db | /script/apteczka_user_id.sql | UTF-8 | 8,619 | 3.59375 | 4 | [] | 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 |
df7ed65591db44a82d7391d55770d3ec055bdec2 | SQL | iremmelci/Booking-Web | /booking.sql | UTF-8 | 5,448 | 3.328125 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.9.2
-- https://www.phpmyadmin.net/
--
-- Anamakine: 127.0.0.1:3308
-- Üretim Zamanı: 09 Oca 2020, 23:28:55
-- Sunucu sürümü: 8.0.18
-- PHP Sürümü: 7.3.12
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHAR... | true |
0c6e8841a5c7fedbc6e370351022bbf660ae8c6e | SQL | The-Ark-Informatics/ark | /ark-database/db-scripts/patch/20110322/mysql/20110608_reporting_schemaPatch.sql | UTF-8 | 325 | 3.359375 | 3 | [] | no_license | USE reporting;
-- Add FK to [ark_module] table
ALTER TABLE `reporting`.`report_template`
ADD CONSTRAINT `FK_REPORTTEMPLATE_ARKMODULE`
FOREIGN KEY (`MODULE_ID` )
REFERENCES `study`.`ark_module` (`ID` )
ON DELETE NO ACTION
ON UPDATE NO ACTION
, ADD INDEX `FK_REPORTTEMPLATE_ARKMODULE` (`MODULE_ID` ASC... | true |
1358bc9ffd26b9cd8833d343af1a9fb2a1049525 | SQL | jareddarnell/Project1-Group2 | /SQLQUERIES.sql | UTF-8 | 1,127 | 4.09375 | 4 | [] | no_license | /* This file is for the sql queries */
--1
SELECT
(ConsoleBrand + ConsoleModel) AS [Consoles]
FROM
Consoles_Ref
;
--2
SELECT
GameTitle
FROM
Games_Ref
;
--3
SELECT
GR.GameTitle,
CR.ConsoleModel
FROM
Games G
LEFT JOIN Games_Ref GR ON G.GameRefID = GR.GameRefID
LEFT JOIN Consoles_Ref CR ON CR.ConsoleRefID = G.... | true |
d50c2ee525a83b24962c7524f67d3a9c0e279435 | SQL | IcaroGSiqueira/database_2020 | /comandos5_dml.sql | UTF-8 | 4,139 | 4.15625 | 4 | [] | no_license | select funcionario.nome, departamento.descricao from funcionario left join departamento on coddepartamento = funcionario.cod;
select funcionario.cargo from funcionario right join departamento on departamento.cod = funcionario.coddepartamento
where departamento.sigla like "CTB";
select count(aluno.matricula) from mat... | true |
42c34a1d7f632f1273f5d1956849085b214ae722 | SQL | azikingo/CyberCourse | /src/main/resources/db/migration/V8__Add_column_for_coursePart.sql | UTF-8 | 199 | 2.96875 | 3 | [] | no_license | alter table if exists course_part
add column if not exists quiz_id int8,
add column if not exists active boolean,
add constraint course_part_quiz_fk foreign key (quiz_id) references quiz; | true |
201bca8ebea5daa14532ff320850c73b628b2e76 | SQL | Tsvetelin-Crimson/SoftUni-Csharp-Databases | /SQL Exercises/Fourth Ex Lecture/EX13.sql | UTF-8 | 167 | 3.734375 | 4 | [] | no_license | SELECT PeakName, RiverName, LOWER(LEFT(PeakName, LEN(PeakName) - 1) + RiverName) AS Mix
FROM Peaks, Rivers
WHERE RIGHT(PeakName, 1) = LEFT(RiverName, 1)
ORDER BY Mix | true |
8d6f3d4675a8812b1208e8c8e79e412027d24920 | SQL | opengauss-mirror/openGauss-server | /src/test/regress/sql/create_function_3.sql | UTF-8 | 5,873 | 3.609375 | 4 | [
"LicenseRef-scancode-mulanpsl-2.0-en",
"LicenseRef-scancode-unknown-license-reference",
"PostgreSQL",
"BSD-3-Clause",
"LGPL-2.0-or-later",
"LicenseRef-scancode-unicode",
"LicenseRef-scancode-warranty-disclaimer",
"curl",
"GPL-1.0-or-later",
"LGPL-2.1-or-later",
"LGPL-2.1-only",
"CC-BY-4.0",
... | permissive | --
-- CREATE FUNCTION
--
-- sanity check of pg_proc catalog to the given parameters
--
CREATE USER regtest_unpriv_user PASSWORD 'gauss@123';
CREATE SCHEMA temp_func_test;
GRANT ALL ON SCHEMA temp_func_test TO public;
SET search_path TO temp_func_test, public;
--
-- ARGUMENT and RETURN TYPES
--
CREATE FUNCTION functe... | true |
1793c3605766334cbc8f72133c31619f10dfe316 | SQL | gorun8/easyfk | /src/core/security/entitydef/mysql/security.sql | UTF-8 | 5,281 | 3.34375 | 3 | [
"Apache-2.0"
] | permissive | /*
* Project:Easy Web Framework
* Description:
* EasyFK stands for Easy Web Framework.It's an open source product for E-Business / E-Commerce.It
* was launched by a chinese Hezhiping(QQ:110476592) in 2015.The goal of EasyFK is to provide a
* foundation and starting point for reliable, secure , simple-to-use ,cost... | true |
192b5f43fb1020f86b6dc54160a87628b6603810 | SQL | ACbOntu/ACbs-Projects | /1402031 PSTU e-shop/eshop.sql | UTF-8 | 9,971 | 3.265625 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.5.1
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: Jan 14, 2018 at 05:45 PM
-- Server version: 10.1.13-MariaDB
-- PHP Version: 5.5.37
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CL... | true |
b63548ea800ea4369ce176beb209a9cf032c3555 | SQL | teamProject016/COM2008 | /Teachers.sql | UTF-8 | 1,097 | 3.53125 | 4 | [] | no_license | CREATE TABLE Teachers
(register_num INT(9),
degree_id VARCHAR(100),
core_module VARCHAR(40),
optional_module VARCHAR(40),
);
CREATE TABLE Degrees
(degree_id VARCHAR(100),
credits INT(40),
level_id VARCHAR(10),
);
-- add the degrees
SELECT Students.register_num, Departments.department
FROM Departments
LEFT JO... | true |
6fcad2a5ebdfd902491da7caa1d30e244db5e5bd | SQL | shashanksimpi/Project-App-impersonator- | /Project-App-impersonator.sql | UTF-8 | 1,110 | 3.984375 | 4 | [] | no_license | /*Think about your favorite apps, and pick one that stores your data- like a game
that stores scores, an app that lets you post updates, etc.
Now in this project, you're going to imagine that the app stores your data
in a SQL database (which is pretty likely!), and write SQL statements
that might look like their ow... | true |
cca5971879773f8a1b00221bfac04e1e4496e859 | SQL | jatin1910/Bank-Website | /Dump_database/my_bank_app_user_password.sql | UTF-8 | 2,872 | 2.828125 | 3 | [] | no_license | -- MySQL dump 10.13 Distrib 8.0.26, for Win64 (x86_64)
--
-- Host: localhost Database: my_bank_app
-- ------------------------------------------------------
-- Server version 8.0.26
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;... | true |
b109e5fbd001c8d031907ca6afeb174fb8b991b5 | SQL | jsm-nbb/Map-On | /application/config/mapon_team_db.sql | UTF-8 | 13,015 | 3.15625 | 3 | [
"MIT"
] | permissive | -- phpMyAdmin SQL Dump
-- version 4.5.1
-- http://www.phpmyadmin.net
--
-- Servidor: 127.0.0.1
-- Tiempo de generación: 11-05-2016 a las 11:34:11
-- Versión del servidor: 10.1.10-MariaDB
-- Versión de PHP: 7.0.4
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=... | true |
158aa33b20a56252a7503c8650b52072f6856578 | SQL | shashank364/CafetoriaManagementSystem | /DATABASE/foodsys.sql | UTF-8 | 9,492 | 2.890625 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.9.0.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Oct 29, 2019 at 12:19 PM
-- Server version: 10.4.6-MariaDB
-- PHP Version: 7.1.31
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @O... | true |
230168b5d691c67714b2d5ac9e76e2ba28821a15 | SQL | MaitRaidmae/AppAnalyzerPLSQL2 | /ALL_UT_TEST_IMPL_ARGUMENTS.sql | UTF-8 | 1,215 | 3.09375 | 3 | [] | no_license | --------------------------------------------------------
-- DDL for View ALL_UT_TEST_IMPL_ARGUMENTS
--------------------------------------------------------
CREATE OR REPLACE FORCE EDITIONABLE VIEW "HUNDISILM"."ALL_UT_TEST_IMPL_ARGUMENTS" ("UTI_ID", "ARG_ID", "INPUT_VALUE", "OUTPUT_VALUE", "TEST_OUTVAL") AS
SELE... | true |
fe92238272197dae0a288948e01e504c55598401 | SQL | gouvinb/supinfo-2jva | /paradise.sql | UTF-8 | 2,113 | 3.53125 | 4 | [
"BSD-2-Clause"
] | permissive | USE paradise;
-- phpMyAdmin SQL Dump
-- version 4.6.6
-- https://www.phpmyadmin.net/
--
-- Client : db
-- Généré le : Mer 01 Mars 2017 à 17:08
-- Version du serveur : 5.7.17
-- Version de PHP : 7.0.15
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHAR... | true |
5510fd780b50a281b69737edf8694da1ccd66cc9 | SQL | iservng/bluemark-school-app | /sql/checkif.sql | UTF-8 | 3,029 | 3.59375 | 4 | [] | no_license |
DELIMITER $$
CREATE PROCEDURE ca_isSubject3CA_done(IN inSubjectId INT, IN inClassId INT, IN inCurrentTermId INT, IN inDepartmentName CHAR(32), IN inTermStarted DATE, IN inTermEnds DATE)
BEGIN
IF inCurrentTermId = 1 AND inDepartmentName = 'Nursery' THEN
SELECT SUM(thirdca) AS 'alread... | true |
bac9ef8b4b501725c1d28a4a148402e9b6cb6941 | SQL | akula-srinu/Customization_Test | /custom/NVWB_INV_WIP_Age_Vsat.sql | UTF-8 | 49,314 | 2.609375 | 3 | [] | no_license | -- *******************************************************************************
-- FileName: NVWB_INV_WIP_Age_Vsat.sql
--
-- Date Created: 2019/Aug/28 06:12:39
-- Created By: nemuser
--
-- Source:
-- - Package: Package_2018_P11_B1_DEV_NEW
-- - Environment: EBSPJD1
-- -... | true |
a99da5241a7a1cc2f49c6898c68adb19a0391f7e | SQL | Astrid-Dev/GestionEtudiants | /vuequotas.sql | ISO-8859-1 | 3,412 | 3.875 | 4 | [] | no_license | --QUESTION 1
CREATE TABLE EMP (
EMPNO NUMERIC(4) GENERATED ALWAYS AS IDENTITY(START WITH 1 INCREMENT BY 1),
ENAME VARCHAR2(10),
JOB VARCHAR2(9),
MGR NUMERIC(4),
HIREDATE DATE,
SAL NUMERIC(7,2),
COMM NUMERIC(7,2),
DEPTNO NUMERIC(2),
CONSTRAINT EMP_PK PRIMARY KEY(EMPNO),
CONSTRAIN... | true |
b7c504252428ab7ed48f83cc505935bd99831fec | SQL | PSYSHO/WEBAPP | /src/main/resources/script.sql | UTF-8 | 1,082 | 3.65625 | 4 | [] | no_license | create table city
(
Id int auto_increment
primary key,
NameCity varchar(20) null
);
create table route
(
Id int auto_increment
primary key,
StartPoint int null,
EndPoint int null,
Time int not null,
constraint route_ibfk_1
foreign key (StartPoin... | true |
94fb634da11109eb7112441f5597c54cc20fdb11 | SQL | davidbrucetn/sql-intro-MusicHistory | /Book1Chap20_exercise_MusicHistory/PopAlbum.sql | UTF-8 | 171 | 3.578125 | 4 | [] | no_license | SELECT
Artist.ArtistName,
Genre.Label
From Artist
LEFT JOIN Album on Artist.Id = Album.ArtistId
LEFT JOIN Genre on Album.GenreId = Genre.Id
Where Genre.Label = 'Pop'; | true |
4731a6eee97dffd7b53d139a55a583d330333250 | SQL | tova-moskowitz/Wiki | /db/schema.sql | UTF-8 | 401 | 2.828125 | 3 | [] | no_license |
CREATE DATABASE wiki;
CREATE TABLE authors(id serial primary key, name varchar(50), how_many_entries integer, entry_ids integer);
CREATE TABLE entries(id serial primary key, title varchar(100), author varchar(100), date date, time time, content text, subscriber_ids integer, history text);
CREATE TABLE subscribers(... | true |
9e39eb4a305ebfa60ccad64f98a5a4bee2c0aa45 | SQL | wizardcypress/sicily-recommendation-system | /sql/sicily.sql | UTF-8 | 12,532 | 3.46875 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 3.4.3
-- http://www.phpmyadmin.net
--
-- 主机: localhost
-- 生成日期: 2011 年 11 月 27 日 00:27
-- 服务器版本: 5.0.51
-- PHP 版本: 5.3.6
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_... | true |
5b21f5236524f587da709f7620f3de92fb314e3c | SQL | shengjinbiao/SepeSite | /data/sql/models.sql | UTF-8 | 1,242 | 2.921875 | 3 | [] | no_license | DROP TABLE IF EXISTS supe_[models]items;
CREATE TABLE supe_[models]items (
itemid mediumint(8) unsigned NOT NULL auto_increment,
catid smallint(6) unsigned NOT NULL default '0',
uid mediumint(8) unsigned NOT NULL default '0',
tid mediumint(8) unsigned NOT NULL default '0',
username char(15) NOT NULL default ... | true |
d9c131a30f35face0e3033b9cff36bc14fe10149 | SQL | mleeker/mySQL_Homework | /SQL_Homework.sql | UTF-8 | 4,245 | 4.0625 | 4 | [] | no_license | USE sakila;
#1A
SELECT first_name, last_name FROM actor
#1B
SELECT CONCAT_WS(first_name, " ", last_name) AS 'Actor Name'
FROM actor
#2A
SELECT actor_id, first_name, last_name FROM actor
WHERE first_name = 'JOE'
#2B
SELECT last_name FROM actor
WHERE last_name LIKE '%GEN%'
#2C
SELECT last_name, first_name FROM actor
WHE... | true |
af9a028069ff71472aa52ca693d2688f2a636736 | SQL | vsatheeshk/sample | /Order/src/main/resources/data.sql | UTF-8 | 346 | 2.71875 | 3 | [] | no_license | DROP TABLE IF EXISTS ORDER1;
CREATE TABLE ORDER1 (
ORDER_ID INT PRIMARY KEY,
CUSTOMER_NAME VARCHAR(250),
ORDER_DATE DATE,
SHIPPING_ADDRESS VARCHAR(250) NOT NULL ,
TOTAL_AMT INT
);
INSERT INTO ORDER1 (ORDER_ID, CUSTOMER_NAME, ORDER_DATE, SHIPPING_ADDRESS, TOTAL_AMT) VALUES
('1001', 'abc', '2... | true |
da3238776cace63c6f7426c86cba8aeedbc28b55 | SQL | thlambert/SQL | /Lambertth_Test2.sql | UTF-8 | 4,626 | 3.984375 | 4 | [] | no_license | ------------------------------------------------
-- Name : Thomas Lambert
--
-- UserName: lambertth
--
-- Course : CS 3630
-- Test 2
--
-- Date : May-8-2019
------------------------------------------------
Prompt
Prompt Test 2
Prompt
Prompt
Prompt 2 points on submission
Prompt
Prompt 2 points on st... | true |
90c646f5416ce1069fd60fab01f3d94ad25aab96 | SQL | jkstill/oracle-script-lib | /sql/metric-names.sql | UTF-8 | 398 | 3.265625 | 3 | [
"MIT",
"LicenseRef-scancode-proprietary-license"
] | permissive |
col os_load format 999.99
col begin_time format a20
col metric_name format a45
col group_name format a35
col interval_seconds format 9999 head 'INTERVAL'
col group_id format 9999 head 'GRP|ID'
select m.metric_name
, g.group_id
, g.name group_name
, g.interval_size / 100 interval_seconds
from v$metricname m
join v$... | true |
a28ca8e646195c315c388610de2e06093ce1c76d | SQL | michalbochnak/BikeHike | /.localhistory/C/Users/Michal/Desktop/School/CS 480/Exams/Practice exam/1531688246$question_02.sql | UTF-8 | 480 | 3.421875 | 3 | [] | no_license | CREATE TABLE Table1 (
F1 INT,
F2 NVARCHAR(3)
);
CREATE TABLE Table2 (
G1 INT,
G2 INT,
G3 NVARCHAR(3)
);
INSERT INTO Table1 (F1, F2)
VALUES (10, 'ABC'),
(25, 'DEF'),
(87, 'GHI');
INSERT INTO Table2 (G1, G2, G3)
VALUES (5, 10, 'AAA'),
(10, 87, 'BBB'),
... | true |
1b81807e54c9ed99c7c53493f1682e8c5a7c557d | SQL | rsanchez-macias/CSE-111-Project | /queries/test_queries.sql | UTF-8 | 455 | 3.5 | 4 | [] | no_license |
SELECT *
FROM Books, Author, Stockroom, University
WHERE s_universityid = un_id AND
b_isbn = s_isbn AND
b_authorid = a_authorid AND
s_universityid = 1 AND
a_authorname like '%o%';
select *
from Author
order by a_authorname;
SELECT COUNT(*)
FROM CheckedBooks
WHERE cb_isbn = "60929871" AND
cb_... | true |
9a588ae5e190ee7544705bc619680e6dc875ac9f | SQL | bapplewh/brooke_barker_university_db_mysql_project | /db-creation.sql | UTF-8 | 1,772 | 3.90625 | 4 | [] | no_license | USE mysql_capstone_schema;
CREATE TABLE `mysql_capstone_schema`.`professor` (
`professor_id` INT NOT NULL AUTO_INCREMENT,
`professor_name` VARCHAR(45) NOT NULL,
PRIMARY KEY (`professor_id`),
UNIQUE INDEX `professor_id_UNIQUE` (`professor_id` ASC) VISIBLE);
CREATE TABLE `mysql_capstone_schema`.`student` (
`s... | true |
761feccc74a8c71d138eb2c22fb20499482a8050 | SQL | qyyCat/Wuziqi | /data/Gobang.sql | UTF-8 | 668 | 2.828125 | 3 | [] | no_license | SET NAMES utf8;
DROP DATABASE IF EXISTS Gobang;
CREATE DATABASE Gobang CHARSET=UTF8;
USE Gobang;
CREATE TABLE users(
uid INT PRIMARY KEY AUTO_INCREMENT,
name VARCHAR(64),
pwd VARCHAR(16),
gener INT,
phone VARCHAR(16),
email VARCHAR(64),
reg_time LONG
);
INSERT INTO users(uid,name,pwd,reg_ti... | true |
6c443012d9da9a764229fdf3a4a25e2a8996625f | SQL | qxzsilver1/HackerRank | /SQL/Advanced-Join/Interviews/MySQL/solution.sql | UTF-8 | 994 | 4.09375 | 4 | [] | no_license | /*
Enter your query here.
*/
SELECT CT.contest_id,
CT.hacker_id,
CT.name,
Sum(ts),
Sum(tas),
Sum(tv),
Sum(tuv)
FROM contests CT
INNER JOIN colleges AS CL
ON CL.contest_id = CT.contest_id
INNER JOIN challenges AS CH
ON CH.... | true |
735b1f4e45d44adac694cbdf80aa4a5b993dac42 | SQL | lpstart/hadoopTest | /hdfsUse/hadoop.sql | UTF-8 | 946 | 2.765625 | 3 | [] | no_license | /*
Navicat MySQL Data Transfer
Source Server : localMysql
Source Server Version : 50626
Source Host : localhost:3306
Source Database : hadoop
Target Server Type : MYSQL
Target Server Version : 50626
File Encoding : 65001
Date: 2016-05-04 10:30:49
*/
SET FOREIGN_KEY_CHECKS=0;
-- -... | true |
7a3ee78f83bb1a88ffa877a11bdb2bb77f8f5745 | SQL | konman01/Oracle-SQL | /exists.sql | UTF-8 | 631 | 3.625 | 4 | [] | no_license | -- exists
select * from emp
where exists(select 'Hello' from dual);
select *
from emp
where not exists(select 'hello' from dual);
select *
from emp
where exists(select null from dual);
-- for every row, the exists condition should be met
select *
from emp
where exists(select * from emp where job = 'MANAGER');
... | true |
7c8224bc444386f9a95352c892b7e181bf73c023 | SQL | dnkansah-tieku/IronDennis | /Lab_SQL_Rolling_calculations.sql | UTF-8 | 1,955 | 4.125 | 4 | [] | no_license | ## 1. Get number of monthly active customers.
-- 1
with customer_activity as (
select customer_id, convert(rental_date, date) as Activity_date,
date_format(rental_date, '%M') as Activity_Month,
date_format(rental_date, '%Y') as Activity_year
from sakila.rental
)
select count(distinct customer_id) as Active_use... | true |
8b04ced146419a84f1f3b6945e1e155ab8f858f0 | SQL | srianant/DNN_Hyperparameter_Optimization | /Optimization/nn_dist/data/source_code/data_files/sql/RenLearn_accounts_NCA.sql | UTF-8 | 418 | 3.078125 | 3 | [] | no_license | select student_number as sid
,first_name as sfirst
,last_name as slast
,gender as sgender
,dob as sbirthday
,ethnicity as srace
,grade_level as sgrade
,student_web_id as susername
,student_web_password as spassword
,'AR' as course
,2024 + (-1 * grade_level) as... | true |
0a3458f712779e1ca7efe00d725a45cb0ab4a271 | SQL | yafithekid/IF3110-01-Simple-Blog | /simple_blog.sql | UTF-8 | 2,316 | 3.265625 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.0.4.1
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: Oct 13, 2014 at 02:11 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 |
bf4b187fb3a4ff96bfa721e28b83b437c5bc35f9 | SQL | MitraNami/BootcampX | /4_queries/8_total_cohort_assistance_duration.sql | UTF-8 | 335 | 4.03125 | 4 | [] | no_license | -- Get the total duration of all assistance requests for each cohort.
SELECT cohorts.name as cohort ,sum(completed_at - started_at) as total_duration
FROM assistance_requests
INNER JOIN students ON assistance_requests.student_id = students.id
INNER JOIN cohorts ON cohorts.id = cohort_id
GROUP BY cohorts.name
ORDER BY ... | true |
c09f5d7e6cd0a5e12ee3950ec1d0348777cc14f1 | SQL | johnnycchapman/CPSC-408 | /assign3-cpsc408/DDLStatements.sql | UTF-8 | 807 | 3.171875 | 3 | [] | no_license | use Assign3;
create table BarPhone
(
Bar_ID int(32) auto_increment primary key not null,
Phone varchar(45)
);
create table BarEmail
(
Bar_ID int(32) not null,
Email varchar(45),
primary key (Bar_ID)
);
create table BarInfo
(
Bar_ID int(32) not null,
bar_name varchar(20),
Address varch... | true |
d69a49488db43a25272d9f7c049fafd4f4bfa134 | SQL | akoikelov/fast-credit | /src/main/resources/db/migration/V14__add_deposits.sql | UTF-8 | 741 | 3.828125 | 4 | [] | no_license | create table deposits
(
id INT GENERATED ALWAYS AS IDENTITY,
customer_id INT NOT NULL,
title VARCHAR(255) NOT NULL,
price INT NOT NULL,
notes TEXT,
comment TEXT,
employee_create_id INT NOT NUL... | true |
0a2d8500f75aabf677afc0dfda2a6219eb4b1bd3 | SQL | nc30mtd/docker-reverse-geocoding-pgsql | /opt/sample.sql | UTF-8 | 5,788 | 2.515625 | 3 | [] | no_license | -- 拡張をインストール
CREATE EXTENSION IF NOT EXISTS postgis;
-- テーブル削除
DROP TABLE IF EXISTS m_address_gaiku;
create table m_address_gaiku (
prefectures_nm varchar(100), -- 都道府県名
city_nm varchar(100), -- 市区町村名
oaza_nm varchar(100), -- 大字・丁目名
koaza_nm varchar(100),... | true |
6b2965a182c63d3f1809d287a18ffbe0b8577691 | SQL | imansawi/BootcampX | /1_queries/students_groupby_cohort_id.sql | UTF-8 | 66 | 2.78125 | 3 | [] | no_license | SELECT id, name
FROM students
WHERE cohort_id = 6
Order BY name; | true |
6456e53508fca4a8e57e0f3369b3e49a3f434ad4 | SQL | virtualpatterns/porto | /deployment/mysql/20171215 - create renameProcedure.sql | UTF-8 | 326 | 3.3125 | 3 | [
"ISC"
] | permissive | USE `porto`;
DROP procedure IF EXISTS `renameProcedure`;
DELIMITER $$
USE `porto`$$
CREATE PROCEDURE `renameProcedure` ( in fromName varchar(100),
in toName varchar(100))
BEGIN
update `mysql`.`proc`
set name = toName,
specific_name = toName
WHERE db = 'porto' AND
name = fromName;
END$$
DELIMI... | true |
4e725ec573ff4691b142a113e58bdd593d2c3328 | SQL | elahesems/category_product_mysql | /mysql.sql | UTF-8 | 1,766 | 3.28125 | 3 | [] | no_license | Use srs;
INSERT INTO Contacts(FirstName,LastName,MobilePhone,Address) VALUES ("name","lastName","+49 *** 99 99","142 street");
INSERT INTO Contacts(FirstName,LastName,MobilePhone,Address) VALUES ("name","lastName","+49 *** 55 22","152 street");
INSERT INTO Contacts(FirstName,LastName,MobilePhone,Address) VALUES ("name"... | true |
d46b5b8abbdcbfa4c82aa95eb7238049593b481d | SQL | administradorsistemas/ERPLICEO | /ERP_database/ERP_database/Academico/Stored Procedures/SPACA_013.sql | UTF-8 | 6,608 | 3.109375 | 3 | [] | no_license |
CREATE PROCEDURE [Academico].[SPACA_013]
(
@IdEmpresa int,
@IdAnio int,
@IdSede int,
@IdNivel int,
@IdJornada int,
@IdCurso int,
@IdParalelo int,
@IdParcial int,
@IdAlumno decimal,
@MostrarRetirados bit
)
AS
SELECT mp.IdEmpresa, mp.IdMatricula, mp.IdMateria, mp.IdCatalogoParcial, m.IdAnio, m.IdSede, m.IdNivel, m.IdJo... | true |
c6d799a76af7545b0534631df28c0efef1648140 | SQL | akiryk/gronster2.0 | /_database-backup.sql | UTF-8 | 37,771 | 3.125 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 3.3.9.2
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: Jul 31, 2012 at 05:36 PM
-- Server version: 5.5.9
-- PHP Version: 5.3.6
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_... | true |
9afe566ea8a9d8d670e01418a82b6f44b7a5a21a | SQL | crtlcctrlv/choe-cloudmusic | /scripts/sql/comment_schema.sql | UTF-8 | 2,302 | 3.4375 | 3 | [
"Apache-2.0"
] | permissive | CREATE SCHEMA `comment` DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
drop table if exists t_comment_0;
CREATE TABLE `t_comment_0` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`comment_id` int(11) NOT NULL,
`user_id` int(11) NOT NULL,
`parent_comment_id` int(11) DEFAULT NULL,
`work_id` int(11) NOT NULL,
`... | true |
5b328ae426804e9e42363fd040a342a0c4922f4a | SQL | lvyang555/eclipsegitproject | /PassengerTransportSystem2/src/util/prorandfunc.sql | UTF-8 | 14,712 | 3.15625 | 3 | [] | no_license | -- MySQL dump 10.13 Distrib 8.0.17, for Win64 (x86_64)
--
-- Host: localhost Database: passenger_manager
-- ------------------------------------------------------
-- Server version 8.0.17
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESUL... | true |
02cb0bea14b265c1bc9cf4b3f55ef84af9214499 | SQL | fikretgozutok/GunlukTakip | /SQLQuery1.sql | UTF-8 | 330 | 3.421875 | 3 | [] | no_license | create database Daily_Schedule
create table Schedules
(
Id int identity(1,1) not null,
EventId int not null,
Date datetime not null,
EventStatus bit not null,
primary key(Id),
foreign key(EventId) references Events(Id)
)
create table Events
(
Id int identity(1,1) not null,
EventName nvarchar(255) not null,
primary k... | true |
80a847c9f92cd5965c6d6da35bad027bf0d549b7 | SQL | vijaydairyf/TimelyFish | /SolomonApp/dbo/Views/dbo.vp_03400APBatchUpdate.sql | UTF-8 | 1,226 | 3.1875 | 3 | [] | no_license |
CREATE VIEW vp_03400APBatchUpdate AS
/****** File Name: 0345vp_03400APBatchUpdate.Sql ******/
/****** Prepare records to be used updating batch status. ******/
SELECT b.BatNbr, Status = 'U',
crAmt = SUM(convert(dec(28,3),CrAmt)),
crCuryAmt = SUM(convert(dec(28,3),CuryCrAmt)),
DrAmt = SUM... | true |
e11f7bc20500c6f0f3d09a6f2d81fe1c0af9f782 | SQL | chrpin/MIRROR | /examples/postgresql/example2.sql | UTF-8 | 83,558 | 3.40625 | 3 | [
"Apache-2.0"
] | permissive | -- CREATE TYPE type_sexo AS ENUM ('M', 'F');
-- COMMIT;
-- CREATE TYPE type_sit AS ENUM ('A','C','P','E','F');
-- COMMIT;
-- Copiando estrutura para tabela projetointegrador.per_permissao
CREATE TABLE IF NOT EXISTS "per_permissao" (
"per_id" integer NOT NULL ,
"per_descricao" varchar(100) NOT NULL,
PRIMARY KEY ... | true |
b6ef00bd12563168e9897c3b193d881c9cc5da3e | SQL | radtek/Telecommunication | /K7/DataBase/VIEW/V_LAST_ACCOUNT_LOAD_LOGS.sql | UTF-8 | 377 | 3 | 3 | [] | no_license | CREATE OR REPLACE VIEW V_LAST_ACCOUNT_LOAD_LOGS AS
SELECT
--#Version=2
ACCOUNTS.ACCOUNT_ID,
ACCOUNTS.ACCOUNT_NUMBER,
ACCOUNT_LOAD_TYPES.ACCOUNT_LOAD_TYPE_NAME,
GET_LAST_ACC_LOAD_LOGS_ERRORS(ACCOUNTS.account_id, ACCOUNT_LOAD_TYPES.ACCOUNT_LOAD_TYPE_ID) ERROR_TEXTS
FROM ACCOUNTS
, ACCOUNT_LOAD_TYPES
ORDER BY ACC... | true |
0a54eed5edba58b7b8ce32e0b9fac5379fa2e77d | SQL | eri-areynolds/flsa-prediction | /get_rev_data.sql | UTF-8 | 220 | 2.78125 | 3 | [] | no_license | SELECT erijobid AS job_id
, totalcash AS comp
, revenuem AS cut_point
FROM xa.CompensationByRevenue
WHERE releaseid = (SELECT MAX(releaseid) FROM dbo.ProductJob)
AND erinationid = 193
AND revenuem IN (1, 100000)
| true |
b886eb00112145b231eb324f4d5fcd8bfe31d4da | SQL | VilleDePully/qgep_sigip | /migration/lien_collecteurs_pully.sql | UTF-8 | 1,976 | 2.640625 | 3 | [] | no_license | -- Update case
UPDATE pully_ass.aw_haltung
SET p_fichier_1 = REPLACE(p_fichier_1, 'G:\Vidéos collecteurs','G:\Vidéos Collecteurs');
UPDATE pully_ass.aw_haltung
SET p_fichier_2 = REPLACE(p_fichier_2, 'G:\Vidéos collecteurs','G:\Vidéos Collecteurs');
UPDATE pully_ass.aw_haltung
SET p_fichier_3 = REPLACE(p_fichier_3, 'G:\... | true |
4519bd5dfbf12025d462cc2a914b2dbcd6581d30 | SQL | hatrongvu13/JavaFramework | /migrate-data/Dyve_User_XFriends.sql | UTF-8 | 22,979 | 3.390625 | 3 | [] | no_license | -- SOC_ARTICLES definition
-- Drop table
-- DROP TABLE SOC_ARTICLES GO
CREATE TABLE SOC_ARTICLES
(
ARTICLE_ID int IDENTITY(1,1) NOT NULL,
ENTITY_TYPE_ID int NULL,
ARTICLE_TYPE_ID int NULL,
ARTICLE_TITLE nvarchar COLLATE Vietnamese_CI_AS NULL,
ARTICLE_STUB ... | true |
9002f145521744af004e47cdc8f5a827f8daca6a | SQL | LeoSan/PL-SQL-Oracle | /SQL/CANCELACIÓN_GASTOS.SQL | UTF-8 | 6,872 | 2.78125 | 3 | [] | no_license | SELECT *
FROM ( SELECT DISTINCT
A.IDGASTOMAIN GASTO
, PENDUPM.PCKFACTURACIONGASTO.queConceptoGasto (A.IDGASTOMAIN) CONCEPTO
, IDPROVEEDORDEPOSITO QUIESES
, FCASIGNADEPOSITO AQUIEN
... | true |
bd85540d2b4c7a38bae613c8c90c4c69291e3187 | SQL | intCCP/CCP | /Produzione/Viste/vtmcre0_app_rio_azioni.sql | UTF-8 | 1,689 | 3.109375 | 3 | [] | no_license | /* Formatted on 17/06/2014 18:16:32 (QP5 v5.227.12220.39754) */
CREATE OR REPLACE FORCE VIEW MCRE_OWN.VTMCRE0_APP_RIO_AZIONI
(
COD_ABI_CARTOLARIZZATO,
COD_GRUPPO_ECONOMICO,
COD_NDG,
ID_AZIONE,
DTA_INSERIMENTO,
DTA_SCADENZA,
FLG_STATUS,
NOTE,
COD_AZIONE,
FLG_ESITO,
COD_MACROSTATO,
COD... | true |
62b1fe08417c48a30772caf54b9d720ce285ab5d | SQL | Zhenghao-Liu/LeetCode_problem-and-solution | /1303.求团队人数/solution.sql | UTF-8 | 217 | 3.734375 | 4 | [] | no_license | # Write your MySQL query statement below
SELECT
A.employee_id,
C.team_size
FROM
Employee AS A,
(SELECT team_id,COUNT(*) AS team_size FROM Employee GROUP BY team_id) AS C
WHERE
A.team_id=C.team_id;
| true |
8a0835741d4b1064cb1beba48faab3ccdf4aefd7 | SQL | silence-do-good/stress-test-Postgres-and-MySQL | /dump/low/day11/select0428.sql | UTF-8 | 191 | 2.78125 | 3 | [] | no_license |
SELECT timeStamp, temperature
FROM ThermometerObservation
WHERE timestamp>'2017-11-10T04:28:00Z' AND timestamp<'2017-11-11T04:28:00Z' AND SENSOR_ID='1feb1ed1_3787_4bb0_8e07_3b7731f8680b'
| true |
b92026dcd3bd4725acd6198f9ed6f02a4541b023 | SQL | anggunn/Angela_Gunn | /exercise_1/transforming/Survey_Result.sql | UTF-8 | 691 | 3.328125 | 3 | [] | no_license | --create table based on stage_survey_responses
--note we create a patient_experience_score as the sum of consistency_score and base_score
--as per data definition. (http://www.hcahpsonline.org/Files/Hospital%20VBP%20Domain%20Score%20Calculation%20Step-by-Step%20Guide_V2.pdf)
--scores that are text base are stored as NU... | true |
b23681f86229a62aaf8179617e4225ff1b957930 | SQL | oerpli/MONitERO | /sql/matching/fork_analysis/defs_xmr.sql | UTF-8 | 903 | 2.640625 | 3 | [
"MIT"
] | permissive | -- Definitions that are used in the processing files in this folder
-- To enable processing of an additional currency (<NAME>) do the following:
-- 0. In 0_run_fork_analysis.sql fork-fn add an additional CASE that returns the fork-height of <NAME>
-- 1. Download <NAME>-blockchain
-- 2. Export TX data of <NAME> blockcha... | true |
2da5f74b5aa98340c43e2e8ee801df7ee7f8d19d | SQL | yanglitongs/monster | /WebContent/WEB-INF/classes/table.sql | GB18030 | 19,313 | 3.53125 | 4 | [] | no_license | -- wxdb ݿṹ
DROP DATABASE IF EXISTS `wxdb`;
CREATE DATABASE IF NOT EXISTS `wxdb` /*!40100 DEFAULT CHARACTER SET utf8 */;
USE `wxdb`;
-- wxdb.sys_group ṹ
DROP TABLE IF EXISTS `sys_group`;
CREATE TABLE IF NOT EXISTS `sys_group` (
`UserGroupID` varchar(50) NOT NULL,
`UserGroupName` varchar(50) NOT NULL,
`Rema... | true |
8eb589c4080a8cf87db589c114c1724f94cda676 | SQL | 420Nat20/Nat20 | /api/data/migrations/20210428213229-initial_migration.sql | UTF-8 | 3,103 | 3.65625 | 4 | [] | no_license | -- +migrate Up
create table campaigns (
id serial not null constraint campaigns_pk primary key,
created_at timestamp,
updated_at timestamp,
deleted_at timestamp,
dm varchar(50) not null
);
alter table campaigns owner to doadmin;
create table locations (
id serial not null constraint location_pk ... | true |
356b04596b4d763e30c8c0d604c97f4787837cc6 | SQL | BEGONEROT/Rat-Tracker | /sql/createtables.sql | UTF-8 | 646 | 3.078125 | 3 | [] | no_license | CREATE DATABASE IF NOT EXISTS begone_rot;
USE begone_rot;
CREATE TABLE IF NOT EXISTS App_User (
username varchar(50) NOT NULL,
password integer NOT NULL,
date_joined timestamp,
is_admin boolean NOT NULL,
PRIMARY KEY (username)
);
CREATE TABLE IF NOT EXISTS Sighting (
unique_key INT UNSIGNED N... | true |
c88df1ed4db2f2fb1101420192a24162ad2986fb | SQL | drupalhu/drupal.hu | /hooks/scripts/db-scrub.stage.mysql | UTF-8 | 2,934 | 2.625 | 3 | [] | no_license | --
-- Scrub important information from a Drupal database.
--
-- The SQL commands are grouped by modules in alphabetical order.
--
SET @dhu_dummy_host = 'nagyontitkos.hu';
SET @dhu_dummy_ip = '42.42.42.42';
-- Core.block.
TRUNCATE TABLE cache_block;
-- Core.comment.
UPDATE
comment
SET
name = 'Anonymous',
mai... | true |
6ff2eeded474274542ecb53225085e0cc319db92 | SQL | rkfka0419/public | /universitySQL/SELECT15-컴과개설과목수강학생.SQL | UHC | 316 | 2.984375 | 3 | [] | no_license | select count(sno)
from enrol, course
where enrol.cno = course.cno and dept = 'ǻ';
select count(distinct enrol.cno)
from enrol, course
where enrol.cno = course.cno and dept = 'ǻ';
select count(sno) / count(distinct enrol.cno)
from enrol, course
where enrol.cno = course.cno and dept = 'ǻ'; | true |
c8bbc35f71d79f8d24a4a8e2cf0a8b7c6eca27f4 | SQL | GordinV/buh70 | /sql/create_view_cur_kulude_taitmine.sql | UTF-8 | 1,767 | 3.296875 | 3 | [] | no_license | DROP VIEW IF EXISTS cur_kulude_taitmine;
CREATE VIEW cur_kulude_taitmine AS
SELECT
month(j.kpv) AS kuu,
year(j.kpv) AS aasta,
j.rekvid,
rekv.nimetus AS asutus,
rekv.parentid,
j1.tunnus AS tunnu... | true |
7eaf92134df09ec8282128748b1bca704990cede | SQL | abhir9/databaserepo | /UserDocuments.sql | UTF-8 | 773 | 3.078125 | 3 | [] | no_license | CREATE DATABASE IF NOT EXISTS `votw`;
USE `votw`;
DROP TABLE IF EXISTS `UserDocuments`;
CREATE TABLE `UserDocuments` (
`id` int(6) NOT NULL AUTO_INCREMENT,
`userid` varchar(8) NOT NULL,
`documenttypeid` int(6) NOT NULL,
`documenttitle` varchar(45) NOT NULL,
`uploaddate` varchar(45) NOT NULL,
`documentpath`... | true |
13089ba6123ba1d8918f7e87d9bb02f2cccbbb74 | SQL | allmp13/IWSSQL | /Fonctions Utilisateurs.sql | UTF-8 | 624 | 4.03125 | 4 | [] | no_license | SELECT
U.N_UTIL AS NOM,
U.PRE_UTIL AS PRENOM,
F.L_FONCTION AS FONCTION,
S2.N_SERVICE AS GROUPEMENT,
S3.N_SERVICE AS SERVICE
FROM
UTILISATEUR U INNER JOIN SERVICE S ON U.C_SERVICE=S.C_SERVICE,
SERVICE S2,
SERVICE S3,
FONCTION F
WHERE U.C_FONCTION LIKE 'CDST' AND S.L_FULLNAMESERVICE ... | true |
49e58314b6e36918949e91268164279f8476e564 | SQL | sebrown0/SUK | /database/salaroo_uk/sql/procGet_Last_Aeo_Deduction_Id.sql | UTF-8 | 689 | 3.734375 | 4 | [] | no_license | CREATE DEFINER=`root`@`localhost` FUNCTION `get_last_aeo_deduction_id`(
taxYear VARCHAR(4),
payFrequency VARCHAR(3),
payrollRunId INT,
empPayrollId VARCHAR(45)) RETURNS int
DETERMINISTIC
BEGIN
DECLARE r_id INT;
SELECT
max(aeo_ded.id) AS last_payroll_ded_id
INTO
r_id
FROM
aeo_deducti... | true |
0ac9e0c86228894fe49f9ffc606490f97da05008 | SQL | clivem/VMGraph | /SnmpGetStats/sql/Script.sql | UTF-8 | 1,593 | 3.5 | 4 | [] | no_license | DROP TABLE IF EXISTS `notes`;
DROP TABLE IF EXISTS `stats`;
--
-- Table structure for table `stats`
--
CREATE TABLE IF NOT EXISTS `stats` (
`stats_id` bigint(20) NOT NULL AUTO_INCREMENT,
`millis` bigint(20) NOT NULL,
`rx_bytes` bigint(20) NOT NULL,
`tx_bytes` bigint(20) NOT NULL,
`created` times... | true |
d1225cc8c896f77b7aeefc2eb0a6d13a8ac75e1f | SQL | KenosSGI/org.kenos.idempiere.lbr | /org.kenos.idempiere.lbr.migration/migration-historic/000000/postgresql/2-100b-100/017-SitTributaria_Order_and_Invoice.sql | UTF-8 | 18,888 | 2.578125 | 3 | [] | no_license | -- 11/02/2008 11h39min55s BRST
-- Default comment for updating dictionary
INSERT INTO AD_Column (AD_Org_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,Is... | true |
870ec061cb60fc07aa31471c761adc423eb18c96 | SQL | rogerpereira123/RandD | /Sql Queries/3E/recipes.sql | UTF-8 | 8,504 | 3.71875 | 4 | [] | no_license | use DBRecipes;
--Master list of units of measurements
insert into UnitOfMeasurement values('Each')
insert into UnitOfMeasurement values('Cup')
insert into UnitOfMeasurement values('Teaspoon')
insert into UnitOfMeasurement values('Tablespoon')
--Master list of ingredients
--Measured in cups
insert into Ingredients (UO... | true |
05db47e4128e1246e4d6d1909fd2327c048a3525 | SQL | wbband/OA | /SMT.Workflow/SourceCode/SMT.SaaS.FlowSystem/WFTools/DB/Tracking/MySql/StoredProcedures/InsertActivityTrackingRecord.sql | UTF-8 | 1,247 | 3.53125 | 4 | [] | no_license | DELIMITER $$
DROP PROCEDURE IF EXISTS InsertActivityTrackingRecord $$
/*
* Insert a single activity tracking record.
*/
CREATE PROCEDURE InsertActivityTrackingRecord
(
IN p_WORKFLOW_INSTANCE_ID BIGINT UNSIGNED
,INOUT p_ACTIVITY_INSTANCE_ID BIGINT UNSIGNED
,IN p_QUALIFIED_NAME VARCHAR(128)
,IN p_CONTE... | true |
ef5df4d66f19e4c3908d08ec1713dc9aa6767d0e | SQL | silence-do-good/stress-test-Postgres-and-MySQL | /dump/high/day25/select1455.sql | UTF-8 | 177 | 2.625 | 3 | [] | no_license |
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o
WHERE timestamp>'2017-11-24T14:55:00Z' AND timestamp<'2017-11-25T14:55:00Z' AND temperature>=0 AND temperature<=52
| true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.