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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
2eab6cfffacc5afad8af6d8e61aec749615206b9 | SQL | Isx-chs/pids | /WebContent/bd/proyecto_dawi.sql | UTF-8 | 22,405 | 3.140625 | 3 | [] | no_license | /*
Navicat MySQL Data Transfer
Source Server : Principal
Source Server Version : 50524
Source Host : localhost:3306
Source Database : proyecto_dawi
Target Server Type : MYSQL
Target Server Version : 50524
File Encoding : 65001
Date: 2013-01-24 23:36:42
*/
SET FOREIGN_KEY_CHECKS=0;... | true |
d6329274d16f66f0de5ae6288df08a3aac06bba2 | SQL | liwc0329/spring-boot-h2-jpa | /src/main/resources/test.sql | UTF-8 | 260 | 2.84375 | 3 | [] | no_license | DROP TABLE IF EXISTS TEST;
CREATE TABLE TEST(ID INT PRIMARY KEY,
NAME VARCHAR(255));
INSERT INTO TEST VALUES(1, 'Hello');
INSERT INTO TEST VALUES(2, 'World');
SELECT * FROM TEST ORDER BY ID;
UPDATE TEST SET NAME='Hi' WHERE ID=1;
DELETE FROM TEST WHERE ID=2; | true |
c286b3cb76236680f1ae0a3a378b2456ff78ca4b | SQL | SHARKJBB/mvc-demo | /mysql.sql | UTF-8 | 3,321 | 2.84375 | 3 | [] | no_license | create database gzhb;
use gzhb;
show tables;
drop table user;
#�û���
create table user(
id int auto_increment primary key,
gh varchar(20),#���ţ���ע���ʱ���Զ���������ǰ���ڼ�id
name varchar(50),
pwd varchar(50),
phone varchar(20),
pow int default 0,#Ȩ�ޣ�0:��ʾ��ͨԱ����1:��ʾ����Ա��2:��ʾ��������Ա
manager_id int default ... | true |
dcdd0249d7550fba24c16fd3a835c164b511b1e2 | SQL | revaturelabs/forge-review-service | /Portfolio-Review-Service/src/main/resources/data.sql | UTF-8 | 1,151 | 2.65625 | 3 | [] | no_license | insert into user_table values (1,'admin@revature.net','adminFirst',true,'adminLast','admin');
insert into user_table values (2,'user@revature.net','FirstName',false,'LastName','password');
insert into portfolio values(1, 'Pending', 2 );
insert into criteria_table values (1,'aboutMe','0','0');
insert into criteria_tabl... | true |
7c281cbef3474fd0e91a749eece5d852fd86127c | SQL | silence-do-good/stress-test-Postgres-and-MySQL | /dump/high/day21/select0854.sql | UTF-8 | 191 | 2.765625 | 3 | [] | no_license |
SELECT timeStamp, temperature
FROM ThermometerObservation
WHERE timestamp>'2017-11-20T08:54:00Z' AND timestamp<'2017-11-21T08:54:00Z' AND SENSOR_ID='1ac44852_b414_47e6_a7bd_478807f09c0e'
| true |
35ae75f3946a7a7a208366eea8a62662d259ca10 | SQL | tkrizsa/xld | /api-homebudget/src/main/resources/install/expense.sql | UTF-8 | 1,544 | 3.21875 | 3 | [] | no_license | --@xld-modelVersion : 9604b4de8d8f94c7a69a431d09bbaa1a
--@xld-versionHint : initial
CREATE TABLE `homebudget.expense` (
`expenseId` BIGINT,
`expenseKindId` BIGINT,
`expenseName` VARCHAR(200),
PRIMARY KEY(`expenseId`),
CONSTRAINT `fk_expense_expenseKindId` FOREIGN KEY (`expenseKindId`) REFERENCES `ho... | true |
c7aa56635b17cfcd9351533967be7e7540f8dd90 | SQL | saini5um/Misc | /CEL_SBL_Fetch_Price.sql | UTF-8 | 3,798 | 3.40625 | 3 | [] | no_license | alter session set current_schema = SIEBEL;
alter session set nls_date_format = 'dd-Mon-YYYY HH24:MI:SS';
select m.SERIAL_NUM, p.name, p.part_num, count(*)
--select m.SERIAL_NUM, a.prod_id, m.prod_id, p.name, p.part_num, a.row_id, a.PAR_ASSET_ID,
--a.ROOT_ASSET_ID, a1.ATTR_NAME, a1.CHAR_VAL
from s_asset a, s_pr... | true |
39a645e69ca91143df593bb408e4246e04075aab | SQL | s23m/cake-persistence | /org.s23m.cell.persistence/src/main/resources/sql/common_ddl.sql | UTF-8 | 5,022 | 3.875 | 4 | [] | no_license | -- DDL which should execute correctly against PostgreSQL, MySQL, H2
CREATE TABLE IF NOT EXISTS Identity (
uuid varchar(36) NOT NULL,
name varchar(100) NOT NULL,
pluralName varchar(100) NOT NULL,
codeName varchar(100),
pluralCodeName varchar(100),
payload TEXT,
PRIMARY KEY (uuid),
CONSTRAINT uc_name_uui... | true |
0ca2397d0c1ccd3e1cab33b33d5807ae7c5b293e | SQL | NTXpro/NTXbases_de_datos | /DatabaseNTXpro/ERP/Stored Procedures/Procs1/Usp_Sel_CajaChicaDetalle_By_IdCajaChica.sql | UTF-8 | 1,152 | 3.21875 | 3 | [] | no_license |
CREATE PROC [ERP].[Usp_Sel_CajaChicaDetalle_By_IdCajaChica]
@IdMovimientoCajaChica INT
AS
BEGIN
SELECT MCD.ID,
MCD.IdMovimientoCajaChica,
MCD.Orden,
MCD.IdCuenta,
C.Nombre NombreCuenta,
MCD.IdPlanCuenta,
PC.CuentaContable,
MCD.IdProyecto,
P.Numero NumeroProyecto,
MCD.Id... | true |
6929d1c13dffedfd4c8d83019702d1f64ca62127 | SQL | marciellioliveira/2watch | /2watch.sql | UTF-8 | 1,454 | 2.921875 | 3 | [
"MIT"
] | permissive | -- phpMyAdmin SQL Dump
-- version 4.7.0
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Apr 19, 2018 at 09:34 PM
-- Server version: 10.1.24-MariaDB
-- PHP Version: 7.1.6
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD... | true |
1d6d48996a2e55281ec87f666345ac42f9175f32 | SQL | JungWonHong/Spring | /.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/JspSemi/boardupload/JOBS2.sql | UHC | 3,002 | 3.875 | 4 | [] | no_license | SET TERMOUT On
SET ECHO On
GRANT CONNECT,RESOURCE,UNLIMITED TABLESPACE TO jobs2 IDENTIFIED BY semi ;
ALTER USER JOBS2 DEFAULT TABLESPACE USERS;
ALTER USER JOBS2 TEMPORARY TABLESPACE TEMP;
CONNECT jobs2/semi
DROP TABLE ȸ;
DROP TABLE ;
DROP TABLE äԽ;
DROP TABLE Ʈ;
DROP TABLE ıԽ;
DROP TABLE ҽԽ;
DROP TABLE ̷¼;
DROP TABL... | true |
16d92206b266783c7045bc11781fc4ac10d5d38b | SQL | lucascavalcante/rapadura-valley-mapa | /db/places_3.sql | UTF-8 | 591 | 2.6875 | 3 | [] | no_license | CREATE TABLE IF NOT EXISTS `places` (
`id` int(9) NOT NULL AUTO_INCREMENT,
`approved` int(1) DEFAULT NULL,
`title` varchar(100) NOT NULL,
`type` varchar(20) NOT NULL,
`lat` float NOT NULL,
`lng` float NOT NULL,
`address` varchar(200) NOT NULL,
`uri` varchar(200) NOT NULL,
`description` varchar(255) NO... | true |
ee5058a5f4e17e687a7ba86e2218871aa37e8712 | SQL | softlog/postgresql_scripts | /embarcador/v_emb_conhecimentos_embarcados_mgr.sql | UTF-8 | 1,942 | 3.28125 | 3 | [] | no_license | -- View: public.v_emb_conhecimentos_embarcados_mgr
-- DROP VIEW public.v_emb_conhecimentos_embarcados_mgr;
CREATE OR REPLACE VIEW public.v_emb_conhecimentos_embarcados_mgr AS
SELECT DISTINCT c.id_emb_conhecimento_embarcado,
c.codigo_empresa,
c.codigo_filial,
c.serie_conhecimento,
c.numero_conhecimen... | true |
ad2505174ac9d6e519306c8040e315499e970fd3 | SQL | britalodev/poeHarvestSeeds | /target/classes/sql/WILD.sql | UTF-8 | 13,728 | 2.828125 | 3 | [
"MIT"
] | permissive | INSERT INTO seeds.seed
(descricao, nome, tier, tipo_seed)
VALUES('Reveals a random Caster modifier crafting effect when Harvested', 'Ursaling Seed', 'T1', 'WILD');
INSERT INTO seeds.craft
(descricao, seedid)
VALUES
('Reforge a Normal or Magic item as a Rare item with random modifiers, including a Caster modifie... | true |
3a6e6672270f9719c5b987e1f7411e76f31d2ce2 | SQL | julian916/gedesDel2018 | /SCRIPTS_DE_MIGRACION/Migracion_Personas.sql | UTF-8 | 2,622 | 3.96875 | 4 | [] | no_license | /*Genero una consulta utilizando row_number() para contabilizar la cantidad de recurrencia de un documento y un email
para luego filtrar con recurrencia igual a 1 tal que pueda alimentar la entidad personas sin los duplicados*/
with clientes as(
SELECT Cliente_Pasaporte_Nro as nro_documento
,Cliente_Mail as ... | true |
2a31811730dac047ce3fa9c86666277e6223b47b | SQL | Tushar503/hopewellhospital | /databases/tbapt001.sql | UTF-8 | 1,671 | 2.84375 | 3 | [] | no_license | -- --------------------------------------------------------
-- Host: 127.0.0.1
-- Server version: 5.7.21 - MySQL Community Server (GPL)
-- Server OS: Win64
-- HeidiSQL Version: 10.2.0.5599
-- --------------------------------------------------------
/... | true |
8ac8136caa4dc77a76eec17b4314694317254f5b | SQL | tylerj9010/Week-5-JPA-Servlet-JSP | /mySQLdumpEmp.sql | UTF-8 | 3,966 | 3.40625 | 3 | [] | no_license | CREATE DATABASE IF NOT EXISTS `employee` /*!40100 DEFAULT CHARACTER SET latin1 */;
USE `employee`;
-- MySQL dump 10.13 Distrib 8.0.19, for Win64 (x86_64)
--
-- Host: cis175.czi7y22egyxa.us-east-2.rds.amazonaws.com Database: employee
-- ------------------------------------------------------
-- Server version 5.7.22... | true |
98f1ee9130760c0bc243983864fd3dd6d7d5003a | SQL | GloriaBeltran/magic-moon | /database/db.sql | UTF-8 | 895 | 3.203125 | 3 | [] | no_license | SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
CREATE DATABASE IF NOT EXISTS dbmagicmoon;
USE dbmagicmoon;
CREATE TABLE IF NOT EXISTS tblproductos (
id int(11) NOT NULL PRIMARY KEY AUTO_INCREMENT,
nombre varchar(200) NOT NULL,
categoria varchar(250) NOT NULL,
precio varchar(1... | true |
c1449d287e4cd111427ce81e29960c21804ba434 | SQL | Carmen90/BD-SQL | /haycupo.sql | UTF-8 | 629 | 3.09375 | 3 | [] | no_license | create or replace
function "haycupo"
(curso in char) return boolean
is
numeroPlazas cursos.plazas%type;
numeroAlumnosInscritos integer := 0;
existeCurso boolean := false;
begin
select plazas into numeroPlazas
from cursos
where codigo = curso;
existeCurso := true;
select count(id_participante) into numeroA... | true |
5438c1f04212c7fc8910299f770510b45bdf30e8 | SQL | QianSeNianHua/lemonblog_service | /lib/mysql/lemonblog.sql | UTF-8 | 9,711 | 3.296875 | 3 | [] | no_license | /*
Navicat Premium Data Transfer
Source Server : mariadb
Source Server Type : MariaDB
Source Server Version : 100410
Source Host : 127.0.0.1:3306
Source Schema : lemonblog
Target Server Type : MariaDB
Target Server Version : 100410
File Encoding : 65001
Date: 18/12/2... | true |
ec31b8f33b30393481566da34d069211ede1d332 | SQL | alexdev06/ExpressFood | /express_food_bdd.sql | UTF-8 | 10,961 | 3.21875 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.8.4
-- https://www.phpmyadmin.net/
--
-- Hôte : localhost:3306
-- Généré le : lun. 08 juil. 2019 à 18:38
-- Version du serveur : 5.7.24
-- Version de PHP : 7.2.11
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 S... | true |
f0e9cbe28b8cb6c67193f3785614821636c1b608 | SQL | LXW1602/mall | /create.sql | UTF-8 | 1,372 | 3.609375 | 4 | [] | no_license | /*==============================================================*/
/* DBMS name: MySQL 5.0 */
/* Created on: 2018/6/6 15:31:53 */
/*==============================================================*/
create database mall;
use mall;
SET NAMES utf8;
dro... | true |
1c0bb0acada379dad373a3b2d425d613d4f234f8 | SQL | Academia-Hack-Promo2/w7_d34_ch9_hcarreno389 | /facturas.sql | UTF-8 | 2,218 | 3.53125 | 4 | [] | no_license | -- MySQL Script generated by MySQL Workbench
-- lun 06 abr 2015 21:43:29 VET
-- Model: New Model Version: 1.0
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES';
-- ... | true |
1651a87f7d6b0a1bcd29322479aa208c5bf303c9 | SQL | Lagosa/TutorUp | /resources/db/migration/V2_5__create_separate_table_with_dates.sql | UTF-8 | 942 | 3.578125 | 4 | [] | no_license | DELETE FROM tutor_offers;
ALTER TABLE tutor_offers DROP COLUMN dateFrom;
ALTER TABLE tutor_offers DROP COLUMN dateTo;
ALTER TABLE tutor_offers DROP COLUMN parentOfferID;
ALTER TABLE tutor_offers DROP COLUMN inSeriesNumber;
CREATE TABLE tutor_offers_dates
(
dateId bigserial NOT NULL,
offerId int NO... | true |
b1f885b16370738b3c2f35dfcf4ff4324b385152 | SQL | silence-do-good/stress-test-Postgres-and-MySQL | /dump/low/day21/select0816.sql | UTF-8 | 405 | 3.5 | 4 | [] | no_license |
SELECT obs.sensor_id, avg(counts)
FROM (SELECT sensor_id, date_trunc('day', timestamp), count(*) as counts
FROM WiFiAPObservation WHERE timestamp>'2017-11-20T08:16:00Z' AND timestamp<'2017-11-21T08:16:00Z' AND SENSOR_ID = ANY(array['3141_clwa_1500','3146_clwa_6029','wemo_03','3141_clwa_1100','3141_clwa_1427'])... | true |
6d7bd417435ec93489a6f9d48aefce987b829d3b | SQL | BiserHristov/SoftUni | /05. C# DataBase/01. MS SQL/EXAM_MS SQL/01.sql | UTF-8 | 1,082 | 3.53125 | 4 | [
"MIT"
] | permissive | --CREATE DATABASE Bitbucket
CREATE TABLE Users
(
Id INT PRIMARY KEY IDENTITY,
Username VARCHAR(30) NOT NULL,
[Password] VARCHAR(30) NOT NULL,
Email VARCHAR(50) NOT NULL
)
CREATE TABLE Repositories
(
Id INT PRIMARY KEY IDENTITY,
[Name] VARCHAR(50) NOT NULL
)
CREATE TABLE RepositoriesContributors
(
RepositoryId INT R... | true |
9d80be63161d04988f5a50729f0eb6cb2337d75f | SQL | valverdethiago/trading-api | /db/query/account.sql | UTF-8 | 495 | 3.515625 | 4 | [
"MIT"
] | permissive | -- name: GetAccountByUsername :one
SELECT *
FROM account
WHERE username = $1;
-- name: GetAccountById :one
SELECT *
FROM account
WHERE account_uuid = $1;
-- name: ListAccounts :many
SELECT *
FROM account
ORDER BY created_date;
-- name: CreateAccount :one
INSERT INTO account (username, email)
VALUES (... | true |
8eecc3a360ed9233050d53072cfc57f7b661fa76 | SQL | sandroalvesperes/chat | /docs/tables.sql | UTF-8 | 6,088 | 3.796875 | 4 | [] | no_license | SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL';
SET NAMES UTF8 COLLATE utf8_general_ci;
-- -----------------------------------------------------
-- Table `support_user`
-- -----------... | true |
6d364629ba05663304332672b5a04de5e508607a | SQL | rnz269/bamazon | /bamazon.sql | UTF-8 | 801 | 3.140625 | 3 | [] | no_license | CREATE DATABASE bamazon_db;
USE bamazon_db;
CREATE TABLE products (
item_id INTEGER(11)AUTO_INCREMENT NOT NULL,
product_name VARCHAR(30) NOT NULL,
department_name VARCHAR(30),
price INTEGER(11),
stock_quantity INTEGER(11),
PRIMARY KEY (item_id)
);
INSERT INTO products
(product_name, department_name, price, st... | true |
34b7b1247851aec43ffd0fb4e97df7bcbec1fc3a | SQL | LonelehKitten/Marketplace | /update.sql | UTF-8 | 560 | 2.546875 | 3 | [] | no_license | -- Mudar status do Produto 1
UPDATE unidade SET status='Nao disponivel' WHERE anuncioID=1;
-- Mudar endereço do ID 1
UPDATE usuario SET endereco='Alguma rua, 101' WHERE id=2;
-- Mudar status do Pedido para Aprovada
UPDATE pedido SET status='Aprovada',dataAprovacao='2020-06-09 21:53:00' WHERE id=1;
-- Mudar status do... | true |
286634d5b25347c92dd8c6bbd8a0474f9eef5d24 | SQL | martandsingh/dubhold | /sql-assessment_final_sub.sql | WINDOWS-1252 | 4,490 | 4.25 | 4 | [] | no_license | ---- CASE STUDY 1: -----------
-- Sellers table
CREATE TABLE sellers
(
id INTEGER PRIMARY KEY IDENTITY(1,1),
[name] VARCHAR(30) NOT NULL,
rating INTEGER NOT NULL
)
-- items table
CREATE TABLE items
(
id INTEGER PRIMARY KEY IDENTITY(1,1),
[name] VARCHAR(30) NOT NULL,
sellerId INTEGER REFERENCES sellers(id... | true |
cd8a6d9bc361f87d00b35fc1a620caeb7c189a84 | SQL | c1-ra/encheres | /SQL Database/3_Peuplement pour tests.sql | ISO-8859-1 | 3,947 | 2.859375 | 3 | [] | no_license | /* ETATS_VENTE */
INSERT INTO ETATS_VENTE VALUES('Cre');
INSERT INTO ETATS_VENTE VALUES('En cours');
INSERT INTO ETATS_VENTE VALUES('Termine');
INSERT INTO ETATS_VENTE VALUES('Retire');
/* CATEGORIES */
INSERT INTO CATEGORIES VALUES('Ameublement');
INSERT INTO CATEGORIES VALUES('Informatique');
INSERT INTO CA... | true |
1f93732b1569dea5d903feca2536c5577a18ddb5 | SQL | ravinduh/DSHS | /resources/dshs.sql | UTF-8 | 6,088 | 3.703125 | 4 | [] | no_license | SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES';
CREATE SCHEMA IF NOT EXISTS `DSHS` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci ;
USE `DSHS` ;
-- -----------... | true |
7c5909baa3db1734a3c8dc3778fe05d525b75627 | SQL | mskutlu/bonita-migration | /src/main/resources/version/to_7_3_0/configuration/postgres_.sql | UTF-8 | 356 | 2.796875 | 3 | [] | no_license | CREATE TABLE configuration (
tenant_id INT8 NOT NULL,
content_type VARCHAR(50) NOT NULL,
resource_name VARCHAR(120) NOT NULL,
resource_content BYTEA NOT NULL
);
ALTER TABLE configuration ADD CONSTRAINT pk_configuration PRIMARY KEY (tenant_id, content_type, resource_name);
CREATE INDEX idx_configuration ON confi... | true |
7b56131b22acffa072622d60667da2b307800d6c | SQL | prodigyoff/dbLab4-6 | /src/main/resources/lab3DBScript.sql | UTF-8 | 7,835 | 3.75 | 4 | [] | no_license | CREATE SCHEMA IF NOT EXISTS `kit` ;
USE `kit` ;
DROP TABLE IF EXISTS `advertisment_panel_has_advertisment`;
DROP TABLE IF EXISTS `supermarket_has_section`;
DROP TABLE IF EXISTS `advertisment`;
DROP TABLE IF EXISTS `trade_network_has_supermarket`;
DROP TABLE IF EXISTS `trade_network`;
DROP TABLE IF EXISTS `supermarket`... | true |
c3b538843f3c9cc3a13b2c1a9140f2b28cd0e586 | SQL | saphyron/randomstuff | /Databaser og Operativ systemer/Create Relationel Algebra.sql | UTF-8 | 377 | 2.796875 | 3 | [] | no_license | drop table if exists Reserves
drop table if exists Sailors
drop table if exists Boats
create table Sailors(
said int primary key,
sname varchar(20),
rating int,
age int
)
create table Boats(
bid int primary key,
bname varchar(20),
color varchar(10)
)
create table Reserves(
said int FOREIGN KEY REFERENCES sailors(said),... | true |
18ddea5cdac052cd86cd2588d91827d588df4b57 | SQL | coutinho98/desafio-MDS | /banco de dados/escola.sql | UTF-8 | 3,025 | 3.25 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 5.1.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Sep 28, 2021 at 11:45 AM
-- Server version: 10.4.21-MariaDB
-- PHP Version: 8.0.10
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIE... | true |
abc850715cf1d8583557ee5b90c7bdbfcd552e6e | SQL | RTejos73/tareasCodingDojo | /MySQL/normalizacion/JOIN.sql | UTF-8 | 909 | 3.6875 | 4 | [] | no_license | use lead_gen_business;
SELECT c.first_name, c.last_name, b.amount, b.charged_datetime FROM clients c
JOIN billing b on c.id = b.id;
SELECT s.domain_name, l.first_name, l.last_name FROM sites s
JOIN leads l ON s.id = l.id;
SELECT c.first_name AS cients_first, c.last_name AS clients_last, s.domain_name, l.first_name... | true |
e044303bc36e89d93eee580f8821e1ccde599676 | SQL | ingridfc28/estudos-git | /Juntando+consultas.sql | UTF-8 | 1,817 | 3.203125 | 3 | [] | no_license |
SELECT DISTINCT [TABELA DE CLIENTES].BAIRRO FROM [TABELA DE CLIENTES]
SELECT DISTINCT [TABELA DE VENDEDORES].BAIRRO FROM [TABELA DE VENDEDORES]
SELECT DISTINCT [TABELA DE CLIENTES].BAIRRO FROM [TABELA DE CLIENTES]
UNION
SELECT DISTINCT [TABELA DE VENDEDORES].BAIRRO FROM [TABELA DE VENDEDORES]
SELECT DISTINCT [TABEL... | true |
03866a3870e10ffcd88448d0bf2ffa6f1e787bfd | SQL | Learsix1/Laboratorio-BD | /Practica5.sql | ISO-8859-1 | 7,908 | 3.171875 | 3 | [] | no_license | use practica1
insert into Alumnos values (1,'Andres', 'Hernandez', 'Yaez')
insert into Alumnos values (2,'Carlos', 'Hernandez', 'Perez')
insert into Alumnos values (3,'Brayan', 'Fernandez', 'Flores')
insert into Alumnos values (4,'Blanca', 'Pea', 'Ruiz')
insert into Alumnos values (5,'Reyna', 'Alanis', 'Gomez')
... | true |
0103a25323f1717c629e37458a67194190a362c6 | SQL | darrylma/FSND_Tournament_Database | /tournament.sql | UTF-8 | 1,691 | 4.625 | 5 | [] | no_license | -- Table definitions for the tournament project.
--
-- Put your SQL 'create table' statements in this file; also 'create view'
-- statements if you choose to use it.
--
-- You can write comments in this file by starting them with two dashes, like
-- these lines here.
DROP DATABASE IF EXISTS tournament;
CREATE DATABASE... | true |
ba6926b9612dc3b65223539fbc4c88b007258e4d | SQL | linyimeng/novice | /novice/directsales/psql/推荐奖检查.sql | UTF-8 | 314 | 2.59375 | 3 | [] | no_license | select * from awards_directpush(5,1000)
select directpushuser_id
from public.directsales_doubletrack where id = 5;
select identity_id from public.directsales_doubletrack as dd where dd.id = 1;
select da.percentage from public.directsales_awards as da where da.memberlevel_id = 4 and da.keyword='directpush' | true |
0c3cbe459438b8116fb25b184e4e1305a7bf6340 | SQL | grayasm/git-main | /tutorial/postgresql_11.1_doc/08_data_types/06.0_boolean.sql | UTF-8 | 1,389 | 3.40625 | 3 | [] | no_license | /* Cap.8 Data Types
8.5 Boolean Type
psql -d mytestdb -U pgmihai
\i 06.0_boolean.sql
\?
\qecho '\033[2J'
*/
/* PostgreSQL provides the standard SQL type boolean.
It can have 3 states: "true", "false" and "unknown" or SQL null value.
Valid literals for "true": TRUE, 't', 'true',... | true |
8597a792664a7c827b30a9f3609076dad5d97f05 | SQL | ahmetdemirayakk/girgir | /kullanici.sql | UTF-8 | 3,728 | 3.078125 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.7.3
-- https://www.phpmyadmin.net/
--
-- Anamakine: localhost:3306
-- Üretim Zamanı: 02 Ara 2017, 15:37:18
-- Sunucu sürümü: 10.0.33-MariaDB
-- PHP Sürümü: 5.6.30
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET ... | true |
5ac4a6a7a6b260e1a9b53f3d96e2436fb97fb2f0 | SQL | matsuha/tin | /auto/up_ts_heya_tinryo_his_start_ymd_sum.sql | SHIFT_JIS | 2,185 | 3.453125 | 3 | [] | no_license | REM
REM =head1 NAME
REM
REM up_ts_heya_tinryo_his_start_ymd_sum.sql
REM
REM =head1 DESCRIPTION
REM
REM (TS_HEYA_TINRYO_HIS)̏XV
REM
REM ăX^[gtOtĂ镨̏ꍇ
REM
REM R[hɂ́Af[^ςāAꌚAꕔ̏
REM ԒɕύXɂȂꍇB
REM ԂƂẮAPł邪AƂĂ͕R[hɂȂ̂
REM ŏĨR[hɍŏꂽX^[go^Kv
REM
REM =head1 HISTORY
REM
REM =over 4
REM
REM =item 2010/10/25 M.TAKIUCHI CREATED... | true |
2897b11a6e52a69e729e44e9d84d1375da62b436 | SQL | veslo1/apmgr | /migrations/storage/39/aclUnitSearchUp.sql | UTF-8 | 27,636 | 3.03125 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 3.3.2
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: May 28, 2010 at 05:53 PM
-- Server version: 5.1.46
-- PHP Version: 5.3.2
SET FOREIGN_KEY_CHECKS=0;
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!... | true |
a86310d9a3a91552f2f31dcb8b8e9b9f0e537c27 | SQL | silence-do-good/stress-test-Postgres-and-MySQL | /dump/low/day11/select0005.sql | UTF-8 | 178 | 2.625 | 3 | [] | no_license |
SELECT timeStamp, temperature FROM ThermometerOBSERVATION o
WHERE timestamp>'2017-11-10T00:05:00Z' AND timestamp<'2017-11-11T00:05:00Z' AND temperature>=37 AND temperature<=57
| true |
93ca44b6982f183a160986c40df039a5f6532eff | SQL | antarus/mystra-pve | /vagrant-conf/provision-sql/20160809.sql | UTF-8 | 63,330 | 3.3125 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.0.10deb1
-- http://www.phpmyadmin.net
--
-- Client: localhost
-- Généré le: Lun 08 Août 2016 à 22:26
-- Version du serveur: 5.5.50-0ubuntu0.14.04.1
-- Version de PHP: 5.5.9-1ubuntu4.19
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SE... | true |
f3560f74ede16b53a02e29f03f7e1b658aee3804 | SQL | agodinhost/android | /QuestoesGratis/docs/ddl.sql | ISO-8859-1 | 2,900 | 3.890625 | 4 | [] | no_license | -- -------------------------------------------------------- #
-- Essas tabelas so importadas na instalao da aplicao. #
-- -------------------------------------------------------- #
CREATE TABLE questions(
_id INTEGER PRIMARY KEY,
banca TEXT,
ano TEXT,
orgao TEXT,
uf ... | true |
77fc90c8ed584dfbc77a3b199294a4ef46a55a3c | SQL | almogaya1315/FamilyCore | /FCore.Identity.DAL/sql/FCore_Identity_Query.sql | UTF-8 | 256 | 2.59375 | 3 | [] | no_license |
use [FCore.DB.UserIdentity]
select *
from dbo.AspNetUsers
update dbo.AspNetUsers
set Password = 'lkga1315'
where UserName = 'Lior'
update dbo.AspNetUsers
set Password = 'Lkga1315!'
where MemberId = 1
delete
from dbo.AspNetUsers
where MemberId > 0 | true |
c0c20919be5b2289b83feea87afc4c45a843527b | SQL | ganeshbabuNN/Databases | /RDMS/Oracle Database/RegularExpression_REGEXP_COUNT_CountOfWords.sql | UTF-8 | 743 | 3.09375 | 3 | [] | no_license | ---counts number of times of the word "kam"
select regexp_count(street_address,'kam', 1,'i') count1 from locations;
/*
this funciton returns a count of the words "and'in the bookname column
-Backreferences
A Useful features of RE is the abilitye to store sub-expression for resue later.
this is also called backreferen... | true |
aeae7cccf744000c7de3919c3a543fd0869223a7 | SQL | vzdrizhni/SQL-Zoo-project | /more_join.sql | UTF-8 | 3,128 | 4.625 | 5 | [
"MIT"
] | permissive | -- 1. List the films where the yr is 1962 [Show id, title]
SELECT id, title
FROM movie
WHERE yr=1962
-- 2. Give year of 'Citizen Kane'.
SELECT yr
FROM movie
WHERE title = 'Citizen Kane'
-- 3. List all of the Star Trek movies, include the id, title and yr (all of these movies include the words Star Trek in the titl... | true |
4ab359ac59a2fd7577b6c3636f4d14c0b15c7b04 | SQL | CUBRID/cubrid-testcases | /sql/_13_issues/_12_1h/cases/bug_bts_7951.sql | UTF-8 | 1,842 | 2.84375 | 3 | [
"BSD-3-Clause"
] | permissive | create table t(t timestamp,id int auto_increment(2,3),v varchar(100)) partition by list(t) (
partition p0 values in ('1970-3-10'),
partition p1 values in ('1971-2-01'),
partition p2 values in ('1972-2-19'));
insert into t(t) values('1970-3-10'),('1971-2-01'),('1972-2-19');
alter table t promote partition p2;
drop t;
tr... | true |
1cad809d18e726ac9e962169d3cb6d0b9f7e47a3 | SQL | basimar/ub_speicherbibliothek | /speibi_lieferung/korr-item_kass.sql | UTF-8 | 1,014 | 2.90625 | 3 | [] | no_license | /******************************************************************************/
/* Script zum Veraendern von z30-Saetzen mit cursor ueber die temp. Tabelle */
/* barcodes_kass */
/****************************************************************************... | true |
24cba41e88e4a10e5a6cd689c281703dd92eaf96 | SQL | yyyasmin/CBT | /db_back/menta_21_10_2021.sql | UTF-8 | 16,053 | 2.671875 | 3 | [] | no_license | --
-- PostgreSQL database dump
--
-- Dumped from database version 13.4
-- Dumped by pg_dump version 13.4
SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SELECT pg_catalog.set_config('search_path', '', fal... | true |
72ad7487593689d1b1e3d42bd7aa5eccded41f08 | SQL | braccolucianoj/beon-coding-backend | /devops/database/schema.sql | UTF-8 | 1,285 | 3.65625 | 4 | [] | no_license | CREATE TABLE flight (
id SERIAL PRIMARY KEY,
created_at TIMESTAMP WITH TIME ZONE NOT NULL,
updated_at TIMESTAMP WITH TIME ZONE NOT NULL,
flight_date TIMESTAMP WITH TIME ZONE NOT NULL,
deleted BOOLEAN NOT NULL DEFAULT FALSE,
-- This should be normalized
price FLOAT NOT NULL,
origin VARCHAR(255) NOT NULL,... | true |
665a4a791ca32b79206e3a29045aaeadc3280bf0 | SQL | AlRusMil/db_231120 | /topic5/Aggregation.sql | UTF-8 | 2,380 | 4.3125 | 4 | [] | no_license | DROP database IF EXISTS shop;
CREATE database shop;
USE shop;
DROP TABLE IF EXISTS users;
CREATE TABLE users (
id SERIAL PRIMARY KEY,
name VARCHAR(255) COMMENT 'Имя покупателя',
birthday_at DATE COMMENT 'Дата рождения',
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
updated_at DATETIME DEFAULT CURRENT_TIMEST... | true |
63fd1c2424598b1b3b19f006b17d42a4583f8302 | SQL | Dlayer/dlayer | /private/database/tables/structure/user_site_page_structure_column.sql | UTF-8 | 689 | 3.03125 | 3 | [
"MIT"
] | permissive |
CREATE TABLE `user_site_page_structure_column` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`site_id` int(11) unsigned NOT NULL,
`page_id` int(11) unsigned NOT NULL,
`row_id` int(11) unsigned DEFAULT NULL,
`size` tinyint(2) unsigned NOT NULL DEFAULT '12',
`column_type_id` tinyint(3) UNSIGNED NOT NULL DEFAULT... | true |
4985a91bd52f467e97b19ca59674a4d99ec429a5 | SQL | gamingbet/gb | /gamingbets.sql | UTF-8 | 24,621 | 3.296875 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 3.4.5
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Czas wygenerowania: 23 Mar 2013, 16:27
-- Wersja serwera: 5.5.16
-- Wersja PHP: 5.3.8
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!4010... | true |
37151a8d788ca6f62083a40312af83f8d7f86c93 | SQL | sanishmaharjan/spring-scaffold | /src/main/resources/db/migration/V1_001__CreatePersonTable.sql | UTF-8 | 620 | 2.703125 | 3 | [] | no_license | CREATE TABLE persons
(
id SERIAL PRIMARY KEY,
first_name VARCHAR(50) NOT NULL,
middle_name VARCHAR(50) NULL,
last_name VARCHAR(50) NOT NULL,
address VARCHAR(255) NULL,
email VARCHAR(255) NULL,
... | true |
fa35aff3e5de3418665d1d502ddb8058a6f74e75 | SQL | xupt007/crm | /target/classes/crm.sql | UTF-8 | 22,298 | 3.125 | 3 | [] | no_license | /*
Navicat Premium Data Transfer
Source Server : localhost
Source Server Type : MySQL
Source Server Version : 50540
Source Host : localhost:3306
Source Schema : crm
Target Server Type : MySQL
Target Server Version : 50540
File Encoding : 65001
Date: 20/04/2018 13:08:... | true |
22e36fd8f915cc01cbe44a2f832198d299767614 | SQL | anderson-sancto/marketsoap | /DB.sql | UTF-8 | 1,792 | 3.546875 | 4 | [] | no_license | CREATE DATABASE `marketsoap` /*!40100 DEFAULT CHARACTER SET utf8mb4 */;
-- marketsoap.cliente definition
CREATE TABLE `cliente` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`nome` varchar(100) NOT NULL,
`sexo` char(1) NOT NULL,
`dataNascimento` date NOT NULL,
`cpf` varchar(20) DEFAULT NULL,
`telefone` varchar(... | true |
c8d60cd3576f0bff33ba2f975fbc19155c24089c | SQL | AjoyKumarPujari/Audio-Format-Converter | /converter.sql | UTF-8 | 2,125 | 2.984375 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.9.2
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1:3306
-- Generation Time: May 15, 2020 at 01:59 PM
-- Server version: 8.0.18
-- PHP Version: 7.3.12
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CH... | true |
ad6fa9210fb5ee60e5496ace073df11769854f63 | SQL | suziray/nextpath | /schema.sql | UTF-8 | 1,102 | 3.359375 | 3 | [] | no_license | create table usr (
id serial PRIMARY KEY,
first_name text not null,
last_name text not null,
title text,
company text,
education text
);
create table experience (
id serial PRIMARY KEY,
usr_id integer REFERENCES usr (id),
title text,
company text,
duration int,
description text,
tags text,
... | true |
2d45059b430211557fe1c30464e45fe89fec7a8f | SQL | hp-wsp/ts-safe | /src/main/resources/db/V1_11__create_table.sql | UTF-8 | 737 | 2.890625 | 3 | [] | no_license | #-----------------------------------------------------------------------
# 添加是否复查以前查出的隐患字段
#------------------------------------------------------------------------
ALTER TABLE c_check_task ADD is_review TINYINT DEFAULT 0 NOT NULL COMMENT '是否复查以前查出的隐患';
ALTER TABLE c_check_task ADD num CHAR(32) NOT NULL COMMENT '检查任务编... | true |
601b86965577cb5cab386a4a1ee43e0c0407be41 | SQL | bjoernbos/its-hackathon-hamburg | /scripts/sql/buffer_hamburger_streckennetz.sql | UTF-8 | 316 | 3.484375 | 3 | [] | no_license | DROP TABLE IF EXISTS its_hackathon.hamburg_streckennetz_buffer;
CREATE TABLE its_hackathon.hamburg_streckennetz_buffer AS
SELECT
n.id, ST_Buffer(n.geom, 100) AS geom
FROM
its_hackathon.db_streckennetz n,
its_hackathon.hamburg_bounds b
WHERE
ST_Contains(b.geom, n.geom)
OR
ST_Intersects(b.geom, n.geom);
| true |
5598cd4e0f484c937748c67564bb48d5e5f2f550 | SQL | planetacomputer/phpFoment2016 | /sql/ej5-2.sql | UTF-8 | 581 | 3.640625 | 4 | [] | no_license | SELECT e.EMPL_FORNAME, e.EMPL_SURNAME, o.OFFC_CITY, k.KNLN_NAME
FROM t_employees e
INNER JOIN t_offices o ON
e.OFFC_ID = o.OFFC_ID
LEFT OUTER JOIN t_knowledge_lines k ON
e.KNLN_ID = k.KNLN_ID
WHERE o.OFFC_COUNTRY IN ('España', 'Chile')
AND e.EMPL_MENTOR_ID is NULL;
CREATE VIEW V_PROJECTS_EMPLOYEES
(NOMBRE, APELL... | true |
5bba43605503b338586485fe6d0826fe80b50ce9 | SQL | devmountain-lfg/devmtn-lfg | /db/tables.sql | UTF-8 | 1,606 | 3.671875 | 4 | [] | no_license | DROP TABLE IF EXISTS user_events;
DROP TABLE IF EXISTS user_preferences;
DROP TABLE IF EXISTS events;
DROP TABLE IF EXISTS activities;
DROP TABLE IF EXISTS users;
CREATE TABLE users (
user_id SERIAL PRIMARY KEY,
created_date TIMESTAMP NOT NULL DEFAULT NOW(),
first_name varchar(50) NOT NULL,
last_nam... | true |
e7b626998b117dcf3743f0a115b10aa8f948c077 | SQL | mastodonlabs/Football | /sql/create.tbl.user_permissions.sql | UTF-8 | 263 | 2.875 | 3 | [] | no_license |
--
-- Roles: user, pool_admin, site_admin
--
CREATE TABLE role (
id INTEGER PRIMARY KEY NOT NULL AUTO_INCREMENT,
name VARCHAR(20) NOT NULL,
edit_pool ENUM('Y', 'N') DEFAULT 'N'
);
CREATE TABLE user_roles (
a3m_account_id INTEGER,
role_id INTEGER
);
| true |
e9acf346e6ed0394ce84d9de3f3a0737b551ec77 | SQL | aimohi/ot-harjoitustyo | /data/schema.sql | UTF-8 | 269 | 2.875 | 3 | [] | no_license | CREATE TABLE Users
(
id INTEGER PRIMARY KEY,
username TEXT,
password TEXT
);
CREATE TABLE Accounts
(
id INTEGER PRIMARY KEY,
user_id INTEGER REFERENCES Users,
date DATE,
amount INTEGER,
account TEXT,
name TEXT,
currency TEXT
);
| true |
9d2e7492dc14ff7ec425b6c2299aaaa33b59fdc9 | SQL | hayatemiyayoshi/lamp_practice | /lamp_dock/append_schema.sql | UTF-8 | 1,544 | 3.4375 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 5.0.4
-- https://www.phpmyadmin.net/
--
-- ホスト: mysql
-- 生成日時: 2021 年 2 月 11 日 12:35
-- サーバのバージョン: 5.7.32
-- PHP のバージョン: 7.4.11
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
--
-- データベース: `sample`
--
-- -----------------------------------------... | true |
a9117ebec33bd0b5c97b230497318783e347f7f1 | SQL | Tommimehtanen/database-design | /tiep3_koostekyselyt_h6_t9_279330.sql | UTF-8 | 291 | 3.375 | 3 | [] | no_license | --Tietokantojen perusteet 2020
--H6 T9
--tommi.mehtanen@tuni.fi
SELECT DISTINCT artwork.artwork_id AS artwork_id, artwork_name
FROM artwork, displayed_at
WHERE artwork.artwork_id = displayed_at.artwork_id
GROUP BY artwork.artwork_id
HAVING COUNT(*) >= ALL (SELECT COUNT(*) FROM artwork)
ORDER BY artwork.artwork_id; | true |
d16b369a3858eb3d2a32c49419ddb9ca6c78cc6e | SQL | Ares-xhs/spring-cloud | /jta-atomikos/src/main/resources/sql/consumer.sql | UTF-8 | 428 | 3.171875 | 3 | [] | no_license | # DROP DATABASE consumer;
CREATE DATABASE consumer;
USE consumer;
CREATE TABLE consumer (
id BIGINT NOT NULL AUTO_INCREMENT
COMMENT '主键',
name VARCHAR(40) NOT NULL
COMMENT '名称',
recv_time TIMESTAMP NOT NULL
COMMENT '接收时间',
result TINYINT NOT NULL
COMMENT '返回结果',
PRIMARY KEY (id)... | true |
4601cec7c4d71a7a3f4edff65deadf82f55a912f | SQL | miranda-price/CSC-174-Lab-4 | /export.sql | UTF-8 | 1,807 | 3.15625 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.8.3
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: Jul 20, 2021 at 04:40 PM
-- Server version: 5.7.24
-- PHP Version: 7.2.14
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CH... | true |
1b1a81e8d33188c3c9cc77262943cf769659201e | SQL | radtek/abs3 | /sql/mmfo/bars/Function/f_get_typdist.sql | WINDOWS-1251 | 1,444 | 2.8125 | 3 | [] | no_license |
PROMPT =====================================================================================
PROMPT *** Run *** ========== Scripts /Sql/BARS/function/f_get_typdist.sql =========*** Run
PROMPT =====================================================================================
CREATE OR REPLACE FUNCTION BA... | true |
fd0acbeb81287ac39a4469ebc72eb5c32a3cba6e | SQL | algebres/biblioteca-cakephp | /bd/bd.sql | UTF-8 | 1,819 | 3.90625 | 4 | [] | no_license | SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL';
CREATE SCHEMA IF NOT EXISTS `biblioteca` DEFAULT CHARACTER SET utf8 ;
USE `biblioteca` ;
-- -------------------------------------------... | true |
eceed838c392d0f28a2b0191577d439ab022f95c | SQL | johnmcteague/springbox-cloud | /springbox-recommendations/src/main/resources/import.sql | UTF-8 | 274 | 2.65625 | 3 | [] | no_license | CREATE TABLE IF NOT EXISTS ratings (
`user_id` INT NOT NULL,
`movie_id` VARCHAR(45) NOT NULL,
`rating` FLOAT NULL,
`timestamp` BIGINT NULL,
PRIMARY KEY (`user_id`, `movie_id`));
insert into ratings(user_id,movie_id,rating,timestamp) values(1,11,8.0,1460944234);
| true |
6524823465929e2930c4fb2e5d1fd86d1fc60618 | SQL | leeshamiller/PersonalProject | /db/delete_task_inbox.sql | UTF-8 | 163 | 3 | 3 | [] | no_license | DELETE FROM task
WHERE task_id = ${task_id};
select * from task
where task_date = 'inbox'
and completed = false
and t_user_id = ${t_user_id}
order by task_id desc | true |
92f29a5ca8baa2cabadc5344d4ccbb8c26ee1eed | SQL | 2904nando/narguis_sabores | /SQL/selects_nervosos.sql | UTF-8 | 2,860 | 4.03125 | 4 | [] | no_license | -- Database: narguis
-- DROP DATABASE narguis;
-- Select de Essências e códigos de categorias
SELECT
essencia.cd_essencia,
essencia.nm_essencia,
essencia.ds_marca,
essencia.pr_preco_medio,
essencia.ds_descricao,
essencia.ds_foto,
essencia.qt_pacote,
array_agg(categoria.cd_categoria),
array_agg(categoria.nm_c... | true |
4f8045d733fb1b6286c9afb7092afd21f4b7bb3b | SQL | ompal/diagno-lab-doc | /diagnoLab.sql | UTF-8 | 6,989 | 3.15625 | 3 | [] | no_license | use diagno_lab;
CREATE TABLE `permission` (
`id` bigint(20) NOT NULL AUTO_INCREMENT,
`display` varchar(100) DEFAULT NULL,
`name` varchar(50) DEFAULT NULL,
`desc` varchar(200) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8;
CREATE TABLE `role` (
`id` bigi... | true |
45280bbde2696a42429357fe0b3c8e0c110cb71f | SQL | DimolSPA/Dimol-Fix-Carteras | /Dimol.Carteras/Dimol.Carteras.Database/dbo/Stored Procedures/Procs2/Trae_ProvCli_Sucursales.sql | UTF-8 | 462 | 2.859375 | 3 | [] | no_license |
Create Procedure Trae_ProvCli_Sucursales(@pcs_codemp integer, @pcs_pclid integer) as
SELECT provcli_sucursal.pcs_pcsid,
provcli_sucursal.pcs_nombre,
provcli_sucursal.pcs_casamatriz
FROM provcli_sucursal
WHERE ( provcli_sucursal.pcs_codemp = @pcs_codemp ) AND
( provcli_... | true |
aecc1c32e1e5a46b13848ac7269a5900e87c10d9 | SQL | Aadam20/Electronic-Voting-System- | /ElectronicVotingSystem/evsdatabase.sql | UTF-8 | 6,817 | 3.046875 | 3 | [
"MIT"
] | permissive | -- phpMyAdmin SQL Dump
-- version 4.0.10deb1
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: Apr 17, 2017 at 05:37 PM
-- Server version: 5.5.54-0ubuntu0.14.04.1
-- PHP Version: 5.5.9-1ubuntu4.21
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_C... | true |
541a6328923ba1296ccea2cb899824bb97e4721d | SQL | tayduivn/training | /rdbms/update/sacwis_990.sql | UTF-8 | 1,108 | 2.640625 | 3 | [] | no_license | --STGAP00016107 - Release(4.2) MR-075 Add new field
--add new column
ALTER TABLE CAPS.CAPS_RESOURCE
ADD (
IND_HOLD_PLACEMENTS VARCHAR2(1)
);
COMMENT ON COLUMN CAPS.CAPS_RESOURCE.IND_HOLD_PLACEMENTS IS 'Indicator to put home on a hold placements status that would set resource status as inactive on approv... | true |
959669a3bd0f59907b5fcec37b8b6f17892f9a2e | SQL | Oscajunq/HandsON | /HandsON_Oracle/DBA/System_Parameters.sql | UTF-8 | 482 | 3.171875 | 3 | [] | no_license | --* File Name : System_Parameters.sql
--* Author : DR Timothy S Hall
--* Description : Displays a list of all the system parameters.
--* Requirements : Access to the v$ views.
--* Call Syntax : @System_Parameters
--* Last Modified: 15/07/2000
PROMPT
SET LINESIZE 500
SET PAGESIZE 30
SET PAUSE ON
COLUMN "Name... | true |
ad32737c07ad5724c12e19ed4ef3a94e169cc953 | SQL | antihax/esi-isk | /sql/0_users.sql | UTF-8 | 271 | 2.734375 | 3 | [
"MIT"
] | permissive | CREATE TABLE IF NOT EXISTS users (
refresh_token TEXT NOT NULL,
access_token TEXT NOT NULL,
access_expires TIMESTAMP NOT NULL,
character_id INTEGER,
owner_hash TEXT,
last_processed TIMESTAMP,
PRIMARY KEY (refresh_token)
);
| true |
df2dd60e510946607ede7a7f990a715c4c7bc5ae | SQL | Oriinks/PL-SQL-Projekt-na-studiach | /ProjectSQLOracle/Select.sql | UTF-8 | 774 | 3.3125 | 3 | [] | no_license | --Select 1
CREATE VIEW widok_problem_globalny AS
Select Nazwa, count(TelephoneNumber),DataRozpoczecia,DataZakonczenia
FROM GlobalProblem ,GlobalProblemNumber, Usluga
WHERE Global_Problem_Id=global_problemnum_id AND Rodzaj_Id=Id;
CREATE OR REPLACE VIEW widok_problem_globalny AS
Select Nazwa, count(TelephoneNumbe... | true |
1784d0f74c2e148bca804171c5e426f25d2b36ed | SQL | SudhirDeshwal/PHP_Project | /DB_Scripts/coronatravels_april5_phpMyAdmin.sql | UTF-8 | 5,129 | 3.4375 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Apr 05, 2020 at 06:22 AM
-- Server version: 10.4.11-MariaDB
-- PHP Version: 7.4.4
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIEN... | true |
7a9c2f2dda8d119786a75923d302dfa42584f3e7 | SQL | mubtakir-lazuardi/sql-union-then-join-table | /query.sql | UTF-8 | 687 | 2.515625 | 3 | [] | no_license | SELECT * FROM users LEFT JOIN(
SELECT * FROM budaya
UNION
SELECT * FROM bumd
UNION
SELECT * FROM kerajinan_masyarakat
UNION
SELECT * FROM kuliner
UNION
SELECT * FROM pariwisata
) foo ON users.id_user = foo.id_admin
// if so... | true |
4e94343675e7afc218e6d5f06bea84f1ad50f92c | SQL | AntonMolganov/NewHope | /database/scripts/03_insert_main_data.sql | UTF-8 | 4,199 | 3.046875 | 3 | [] | no_license | --заполняем доступные виды транспорта
declare
begin
insert into newhope.transport_types
(transport_type_id,
s_name)
values
(1,
'Автобус');
insert into newhope.transport_types
(transport_type_id,
s_name)
values
(2,
'Троллейбус');
insert into newhope.transport_types
(t... | true |
d4d1c7bc31b0a93652d622d7f27219c2ffb09006 | SQL | tatiananosova/SpringBootApp | /create.sql | UTF-8 | 2,091 | 3.6875 | 4 | [] | no_license | drop table if exists hiber.product cascade;
create table hiber.product
(
id serial not null,
title varchar not null,
cost int,
deleted bool,
version int not null
);
create unique index product_id_uindex
on hiber.product (id);
create unique index product_title_uindex
on hiber.product (title);
a... | true |
9add50fa1c6f6d8375b0a6bbd6684f12363dbd2b | SQL | pstroot/maison.website | /database/maisondesprit_structure_only.sql | UTF-8 | 4,599 | 3.25 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 3.5.2.2
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: Mar 11, 2013 at 10:58 AM
-- Server version: 5.5.27-log
-- PHP Version: 5.4.6
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT *... | true |
49c9f3f410582439d6ae69fbd3dd227e71355db9 | SQL | kaolin244/Game | /gra.sql | UTF-8 | 2,528 | 3.109375 | 3 | [] | no_license | -- phpMyAdmin SQL Dump
-- version 4.5.1
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Czas generowania: 16 Lis 2016, 23:38
-- Wersja serwera: 10.1.16-MariaDB
-- Wersja PHP: 5.6.24
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT *... | true |
917264e6b929f4bf00d0b9e4743bfa61235f1406 | SQL | shdb1/springweb-security | /src/main/resources/script.sql | UTF-8 | 380 | 2.984375 | 3 | [] | no_license |
CREATE TABLE students (
username text NOT NULL DEFAULT '',
password text NOT NULL DEFAULT '',
enabled smallint NOT NULL DEFAULT 1
)
CREATE TABLE roles (
username text NOT NULL DEFAULT '',
role text NOT NULL DEFAULT ''
) ;
INSERT INTO students
VALUES ('johny', 'johnysecured', 1);
INSERT INTO ro... | true |
357778394053834c0485d9a1a8d6f894ad31e3ed | SQL | DanielMuthupandi/FAST | /FAST/vsql/NETSUITEOPENAIR/NO_Schedulerequest.sql | UTF-8 | 4,920 | 3.578125 | 4 | [] | no_license | /****
****Script Name : NO_Schedulerequest.sql
****Description : Incremental data load for NO_Schedulerequest
****/
/* Setting timing on**/
\timing
/**SET SESSION AUTOCOMMIT TO OFF;**/
\set ON_ERROR_STOP on
CREATE LOCAL TEMP TABLE Start_Time_Tmp ON COMMIT PRESERVE ROWS AS select sysdate st from dual;
/* Inserti... | true |
456dc13982469ac249b2d1cb161e2550466f8728 | SQL | jalapa1/assignment-dbms | /SQLQuery555.sql | UTF-8 | 1,000 | 3.28125 | 3 | [] | no_license | create database assignment1
use assignment1
create table data2(
Id int not null,
name varchar(20) not null,
age int not null,
city varchar(15) not null
);
insert into data2 values(101,'varsha',22,'banglore');
insert into data2 values(102,'kavya',32,'hyd');
insert into data2 values(103,'raju',25,'ctc');
inser... | true |
c79153be060caa8e1b13e148cc73fe00fc07b8f6 | SQL | robert-fink/CS3380-Database-Applications-and-Information-Systems | /Lab3/rwfwcb_lab3/rwfwcb_create_tables.sql | UTF-8 | 1,876 | 3.65625 | 4 | [] | no_license | /* Robert Fink
-- rwfwcb 18074424
-- cs3380 lab3
*/
/*A1--Create the pilot table.*/
create table pilot (
fname varchar(15),
lname varchar(15) NOT NULL,
license_num integer AUTO_INCREMENT PRIMARY KEY,
birthdate date NOT NULL
)ENGINE=INNODB;
/*A2--Create the plane table with a foreign key referencing 'pilot'.*/
cr... | true |
5c0328bda386ea797b7c5790fcffae15f306eb23 | SQL | hnifmaghfur/Ankasa-Backend | /file.sql | UTF-8 | 2,889 | 3.5 | 4 | [] | no_license | CREATE TABLE users
(
id INT NOT NULL AUTO_INCREMENT,
email VARCHAR(50) NOT NULL,
password VARCHAR(50) NOT NULL,
created_at DATETIME,
phone VARCHAR(30),
status INT NOT NULL,
gcm_token VARCHAR(200) NOT NULL,
PRIMARY KEY (id)
);
CREATE TABLE cities
(
id INT NOT NULL AUTO_INCREMENT,
name VARCHAR(50) NO... | true |
b700282afee3b880c40a21d45f85b677e5f27cef | SQL | vntrbr/SeederFaker | /seed.sql | UTF-8 | 15,676 | 3.171875 | 3 | [
"MIT"
] | permissive | -- phpMyAdmin SQL Dump
-- version 5.0.3
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Waktu pembuatan: 04 Mar 2021 pada 04.54
-- Versi server: 10.4.14-MariaDB
-- Versi PHP: 7.2.34
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@C... | true |
431b3d4d195ec151d531954262d8373b499a2a07 | SQL | IliaIliev94/SoftUni-Work | /C# MS SQL/CRUD-Databases Exercise/12. Find 5 Best Paid Employees.sql | UTF-8 | 98 | 2.625 | 3 | [] | no_license | -- Get 5 Top Paid Employees
SELECT TOP(5) FirstName, LastName FROM Employees
ORDER BY Salary DESC | true |
b3c480df15f854ca11a141cb755343bfa65c31b2 | SQL | lsauva/PiscinePHP | /d05/ex11/ex11.sql | UTF-8 | 1,342 | 4.1875 | 4 | [] | no_license | -- ### Premiere version sans INNER JOIN
-- SELECT
-- UPPER(last_name) AS NAME,
-- first_name,
-- price
-- FROM
-- user_card,
-- member,
-- subscription
-- WHERE
-- user_card.id_user = member.id_user_card
-- AND member.id_sub = subscription.id_sub
-- AND subscription.price > 42
-- ORDER BY
--... | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.