sql stringlengths 6 1.05M |
|---|
# --- !Ups
DROP TABLE NEWS_ITEM_CATEGORY;
# --- !Downs
|
<reponame>ishadi123/muthuhara<filename>preschooldb.sql
-- phpMyAdmin SQL Dump
-- version 5.1.0
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Feb 15, 2022 at 10:28 PM
-- Server version: 10.4.19-MariaDB
-- PHP Version: 7.4.19
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_... |
SELECT title, description FROM film;
SELECT * FROM film WHERE length >=60 AND length <= 75;
SELECT * FROM film WHERE rental_rate = 0.99 AND (replacement_cost =12.99 OR replacement_cost = 28.99);
SELECT last_name FROM customer WHERE first_name = 'Mary'; -- Answer: Smith
SELECT * FROM film WHERE NOT(length > 50) AND NOT(... |
<reponame>williancarvalho/database-utils
/*
DESCRIPTION:
This script will generate a summary report of the stored procedures,
views, functions and triggers in the current database to show the
number of lines of code, the number of referenced objects and the
number of parameters. These metrics can be used to judge th... |
ALTER TABLE `submission`
DROP FOREIGN KEY `item_id`;
ALTER TABLE `submission`
ADD COLUMN `post_id` INT UNSIGNED NULL AFTER `is_graded`,
ADD INDEX `fk_submission_2_idx` (`post_id` ASC);
ALTER TABLE `submission`
ADD CONSTRAINT `fk_submission_1`
FOREIGN KEY (`item_id`)
REFERENCES `item` (`id`)
ON DELETE CASCADE
... |
use ScaCompanyDB
SELECT
GL52002 as account_number,
GL52003 as cc,
GL52004 as alt_product_group,
GL52025 as January_20, -- p1creditamt
GL52026 as February_20, -- p2creditamt
GL52027 as March_20, -- p3creditamt
GL52028 as April_20, -- p4creditamt
GL52029 as May_20, -- p5creditamt
GL52030 as June_20, --... |
<filename>db/schema/init.sql
CREATE DATABASE IF NOT EXISTS dogs;
USE dogs;
CREATE TABLE IF NOT EXISTS dog (
id INT UNSIGNED PRIMARY KEY AUTO_INCREMENT,
breedId INT UNSIGNED REFERENCES breed(id),
name VARCHAR(60) NOT NULL
);
CREATE TABLE IF NOT EXISTS breed (
id INT UNSIGNED PRIMARY KEY AUTO_INCREMENT... |
IF OBJECT_ID('zdm.DropDefaultConstraint') IS NOT NULL
DROP PROCEDURE zdm.DropDefaultConstraint
GO
CREATE PROCEDURE zdm.DropDefaultConstraint
@tableName nvarchar(256),
@columnName nvarchar(128)
AS
SET NOCOUNT ON
SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED
DECLARE @sql nvarchar(4000)
SELECT @sql =... |
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `table` (
`param1` varchar(255) NOT NULL,
`param2` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL CHECK (json_valid(`changedData`)),
`param3` int(11) NOT NULL,
`param4` b... |
<gh_stars>1-10
-- phpMyAdmin SQL Dump
-- version 3.5.5
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Czas wygenerowania: 14 Sty 2018, 00:57
-- Wersja serwera: 5.5.21-log
-- Wersja PHP: 5.4.10
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SE... |
<reponame>vishal142/InfiniteScroll
-- phpMyAdmin SQL Dump
-- version 4.4.14
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: Jan 23, 2019 at 08:00 AM
-- Server version: 5.6.26
-- PHP Version: 5.6.12
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SE... |
<reponame>trentford/iem
CREATE EXTENSION postgis;
-- Boilerplate IEM schema_manager_version, the version gets incremented each
-- time we make an upgrade script
CREATE TABLE iem_schema_manager_version(
version int,
updated timestamptz);
INSERT into iem_schema_manager_version values (4, now());
--- Tables loaded by ... |
<filename>morelos/postalCode_morelos.sql
insert into postal_code(id, code)
values(UUID_TO_BIN('15d9e213-ab2f-419a-b89d-88ae3d309c63'), '62000');
insert into postal_code(id, code)
values(UUID_TO_BIN('1ecaea83-4003-4444-9891-f06db04b1ff6'), '62009');
... |
DROP TABLE "public"."tasks";
|
----------------------------------------------------------------
--Input arguments
----------------------------------------------------------------
--$u{graph_uri}: URI of the graph to dump
--$u{dump_file_path}: Initial filename where to dump the graph
--$u{file_length_limit}: Dump file size limit. If exceeded, dump is... |
<reponame>skdevelopers/php-mlm-matrix
-- ----------------------------
-- Table structure for matrix
-- ----------------------------
DROP TABLE IF EXISTS `matrix`;
CREATE TABLE `matrix` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`depth` tinyint(4) unsigned NOT NULL DEFAULT '3' COMMENT 'Уровни матрицы',
`pow`... |
<reponame>jaydeesimon/vetd-app
DROP VIEW IF EXISTS vetd.categories_by_round;
--;;
CREATE OR REPLACE VIEW vetd.categories_by_round AS SELECT "rc"."id" AS "rcid", "rc"."round_id", "rc"."id" AS "ref_id", "rc"."deleted" AS "ref_deleted", "c"."id", "c"."idstr", "c"."created", "c"."cname", "c"."deleted" FROM "round_category"... |
<gh_stars>1-10
ALTER TABLE `spell_proc_event`
ADD COLUMN `SpellFamilyName` smallint(6) unsigned NOT NULL default '0' AFTER `SkillID`,
ADD COLUMN `SpellFamilyMaskNew` bigint(11) unsigned NOT NULL default '0' AFTER `SpellFamilyMask`;
UPDATE `spell_proc_event`
SET `SpellFamilyMaskNew` = `SpellFamilyMask` WHERE `Spe... |
CREATE FUNCTION calculate_avg_age_4_2(roomtypearg varchar) returns table("Age In Years" double precision, "Info" text)
AS
$$
BEGIN
RETURN QUERY
SELECT AVG(ages."Age in Years"), CONCAT('Room Type : ',roomtypearg) from
(SELECT *, DATE_PART('year', NOW()) - DATE_PART('year', dates."dateofbirth") AS "Age in Years"
from
(S... |
/*
Navicat MySQL Data Transfer
Source Server : mysql
Source Server Type : MySQL
Source Server Version : 80020
Source Host : localhost:3306
Source Schema : phpmyblog
Target Server Type : MySQL
Target Server Version : 80020
File Encoding : 65001
Date: 26/05/2021 20:38:... |
with base as (
select *
from {{ ref('stg_jira__field_option_tmp') }}
),
fields as (
select
{{
fivetran_utils.fill_staging_columns(
source_columns=adapter.get_columns_in_relation(ref('stg_jira__field_option_tmp')),
staging_columns=get_field_option_col... |
insert into cdm_synthea_v2.cdm_source (
cdm_source_name,
cdm_source_abbreviation,
cdm_holder,
source_description,
source_documentation_reference,
cdm_etl_reference,
source_release_date,
cdm_release_date,
cdm_version,
vocabulary_version
)
select 'Synthea',
'cdm_synthea_v2',
... |
<filename>HibernateSpringBootCalculatePropertyPostLoad/src/main/resources/data-mysql.sql<gh_stars>100-1000
INSERT INTO `book` (`id`, `isbn`, `title`, `price`) VALUES (1,'Isbn_1','Title_1',10.99);
INSERT INTO `book` (`id`, `isbn`, `title`, `price`) VALUES (2,'Isbn_2','Title_2',23.05);
INSERT INTO `book` (`id`, `isbn`, `... |
<reponame>jinjin123/switch-mysql-postgresql
CREATE OR REPLACE FUNCTION sch_chameleon.fn_refresh_parts()
RETURNS VOID as
$BODY$
DECLARE
t_sql text;
r_tables record;
BEGIN
FOR r_tables IN SELECT unnest(v_log_table) as v_log_table FROM sch_chameleon.t_sources
LOOP
RAISE DEBUG 'CREATING TABLE %', ... |
/* Scottish Parliament
Scottish Parliament
The data includes all Members of the Scottish Parliament (MSPs) in 1999. Most MSPs belong to a political party. Some parties have a leader who is an MSP. There are two tables:
msp
name party constituency
Adam MSP, Brian SNP North East Scotland
Aitken MSP, Bill Con Glasgow
Ale... |
<filename>blog.sql
-- phpMyAdmin SQL Dump
-- version 4.8.5
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Mar 19, 2019 at 07:52 AM
-- Server version: 10.1.38-MariaDB
-- PHP Version: 7.2.15
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";... |
/*L
Copyright SAIC
Distributed under the OSI-approved BSD 3-Clause License.
See http://ncip.github.com/cabio/LICENSE.txt for details.
L*/
ALTER TABLE ZSTG_MERGED_SNP_RSIDS_MAPPING
DROP PRIMARY KEY CASCADE
/
DROP TABLE ZSTG_MERGED_SNP_RSIDS_MAPPING CASCADE CONSTRAINTS PURGE
/
--
-- ZSTG_MERGED_SNP_RSIDS_MAP... |
-- insert and query data which table to reference to the table of create range partition with int field having boundary values and maxvalue
set system parameters 'create_table_reuseoid=no';
create table ident (id int,
name char(10),
zzz varchar(50))
partition by range (id) (
partition p0 values less than (3),
par... |
<reponame>iPaich/fakultet<filename>database/fakultet/Original backup/nastavnik.sql
-- --------------------------------------------------------
-- Host: 127.0.0.1
-- Server version: 10.1.10-MariaDB - mariadb.org binary distribution
-- Server OS: Win32
-- HeidiSQL ... |
<reponame>manju4ever/hapi-moleculer-starter
CREATE SCHEMA IF NOT EXISTS main;
SET
search_path TO main,
public;
CREATE TYPE utype as ENUM ('EMPLOYER', 'EMPLOYEE');
CREATE TABLE "Users" (
"id" bigserial NOT NULL,
"uuid" uuid NULL,
"email" varchar(150) NULL,
"password" varchar(256),
"username" varc... |
<gh_stars>0
DELETE FROM [BookAuthors] WHERE ([BookId] = 1 AND [AuthorId] = 1)
DELETE FROM [BookAuthors] WHERE ([BookId] = 2 AND [AuthorId] = 2)
DELETE FROM [BookAuthors] WHERE ([BookId] = 3 AND [AuthorId] = 3)
DELETE FROM [BookAuthors] WHERE ([BookId] = 4 AND [AuthorId] = 4)
DELETE FROM [BookAuthors] WHERE ([BookId] =... |
<gh_stars>0
INSERT INTO "InvoiceLine" ("InvoiceLineId","InvoiceId","TrackId","UnitPrice","Quantity") VALUES
(1,1,2,0.99,1)
,(2,1,4,0.99,1)
,(3,2,6,0.99,1)
,(4,2,8,0.99,1)
,(5,2,10,0.99,1)
,(6,2,12,0.99,1)
,(7,3,16,0.99,1)
,(8,3,20,0.99,1)
,(9,3,24,0.99,1)
,(10,3,28,0.99,1)
,(11,3,32,0.99,1)
,(12,3,36,0.99,1)
,(13,4,42... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.7.4
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Sep 26, 2018 at 02:41 PM
-- Server version: 10.1.28-MariaDB
-- PHP Version: 5.6.32
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!4... |
-- phpMyAdmin SQL Dump
-- version 4.8.5
-- https://www.phpmyadmin.net/
--
-- Servidor: 127.0.0.1
-- Tiempo de generación: 29-05-2019 a las 05:22:23
-- Versión del servidor: 10.1.39-MariaDB
-- Versión de PHP: 7.3.5
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
... |
DROP DATABASE IF EXISTS top_songsDB;
CREATE database top_songsDB;
USE top_songsDB;
CREATE TABLE topSongs (
position INT NOT NULL,
artist VARCHAR(100) NULL,
song VARCHAR(100) NULL,
year INT NULL,
raw_total DECIMAL(10,4) NULL,
raw_usa DECIMAL(10,4) NULL,
raw_uk DECIMAL(10,4) NULL,
raw_eur DECIMAL(10,4) ... |
CREATE OR REPLACE function fn_get_citizenship_custinfo (as_proposal_number OSP$EPS_PROPOSAL.PROPOSAL_NUMBER%type)
return varchar2 is
ls_citizenship varchar2(50);
ls_person_id osp$eps_prop_investigators.person_id%type;
--valid enumeration values:
--"U.S. Citizen or noncitizen national"
--"Permanent Resident of... |
TRUNCATE TABLE PUR_CONTR_MGR_T DROP STORAGE
/
INSERT INTO PUR_CONTR_MGR_T (CONTR_MGR_CD,OBJ_ID,VER_NBR,CONTR_MGR_NM,CONTR_MGR_PHN_NBR,CONTR_MGR_FAX_NBR,CONTR_MGR_DLGN_DLR_LMT,ACTV_IND)
VALUES (10.0,'DC110C03-D20F-A572-E1E6-0037D4AD2D58',2.0,'<NAME>','555-555-5555','444-444-4444',15000.0,'Y')
/
INSERT INTO PUR_CONTR_M... |
CREATE DATABASE taptalkdiaries;
USE taptalkdiaries;
CREATE TABLE master_users (
id Bigint auto_increment primary key not null,
username varchar(32) UNIQUE not null,
email varchar(64) UNIQUE not null,
birthday varchar(10) not null,
full_name varchar(16) not null,
created_at datetime not null,
... |
<reponame>conversionlogic/snowplow<gh_stars>0
-- Copyright (c) 2013-2015 Snowplow Analytics Ltd. All rights reserved.
--
-- This program is licensed to you under the Apache License Version 2.0,
-- and you may not use this file except in compliance with the Apache License Version 2.0.
-- You may obtain a copy of the Apa... |
CREATE TABLE `{$NAMESPACE}_ponder`.`ponder_question` (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`title` varchar(255) NOT NULL,
`phid` varchar(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
`voteCount` int(10) NOT NULL,
`authorPHID` varchar(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
`content`... |
/*
Arquivo: functions.sql
*/
mysql>delimiter $$
mysql> create function rt_nome_cliente(vn_numeclien int)
returns varchar(50)
begin
declare nome varchar(50);
select c_nomeclien into nome
from comclien
where n_numeclien = vn_numeclien;
return nome;
end $$
mysql> de... |
-- SENTRY-327
ALTER TABLE `SENTRY_DB_PRIVILEGE` ADD `WITH_GRANT_OPTION` CHAR(1) NOT NULL DEFAULT 'N';
|
--
-- app2
--
INSERT INTO APPLICATIONS (
NAME,
UID,
CREATION_TIMESTAMP,
RESOURCE_VERSION,
GENERATION,
DATA
) VALUES (
'app2',
'4e185ea6-7c26-11eb-a319-d45d6455d220',
'2020-01-01 00:00:00',
'A0EEBC99-9C0B-4EF8-BB6D-6BB9BD380A11',
0,
'{
"spec": {
"trustAnchor... |
-- Revert delivery_role
BEGIN;
DROP TYPE IF EXISTS delivery_role;
COMMIT;
|
--
-- PARTITION_JOIN
-- Test partitionwise join between partitioned tables
--
-- Enable partitionwise join, which by default is disabled.
SET enable_partitionwise_join TO TRUE;
--
-- partitioned by a single column
--
CREATE TABLE prt1 (
a int,
b int,
c varchar
)
PARTITION BY RANGE (a);
CREATE TABLE prt1... |
<gh_stars>0
CREATE SEQUENCE public.table_goods_tag_id_seq
INCREMENT 1 START 1 MINVALUE 1 MAXVALUE 9223372036854775807 CACHE 1;
ALTER SEQUENCE public.table_goods_tag_id_seq
OWNER TO soglad;
-- Table: public.goods_tag
-- DROP TABLE public.goods_tag;
CREATE TABLE public.goods_tag
(
id BIGINT ... |
-- Table: public.brands
CREATE TABLE public.brands
(
"id" uuid NOT NULL,
"name" character varying(45) NOT NULL,
"created_at" timestamp with time zone NOT NULL,
"updated_at" timestamp with time zone NOT NULL,
"deleted_at" timestamp with time zone,
CONSTRAINT "brands_pkey" PRIMARY KEY ("id")
)
WITH (OIDS = FALSE)
T... |
delete from books;
delete from author; |
-- grabs a snapshot of each set's position at midnight UTC of each day
-- drop view if exists dune_user_generated.set_protocol_daily_positions;
create or replace view setprotocol.view_daily_positions as
with initial_components as (
-- Get the initial components from the create function
select output_0 as set_add... |
--------------------------------------------
-- Create the database and all of its tables
--------------------------------------------
CREATE DATABASE pizza_restaurant
GO
USE [pizza_restaurant]
GO
DROP TABLE pizza
GO
CREATE TABLE pizza
(
id TINYINT IDENTITY(1,1) PRIMARY KEY NOT NULL,
name VARCHAR(25) NOT NULL UNI... |
-- MySQL dump 10.13 Distrib 8.0.12, for osx10.13 (x86_64)
--
-- Host: localhost Database: TripChat
-- ------------------------------------------------------
-- Server version 8.0.12
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;... |
<reponame>somyadoshi/Employee-Tracking-System
-- @Author: <NAME>.
CREATE FUNCTION CalcTotalEscalationAcrossTeam(@PK INT)
RETURNS INT
AS
BEGIN
DECLARE @RET INT = (
SELECT COUNT(*) AS TotalEscalations
FROM tblTeam T
JOIN tblTeam_Employee TE ON T.TeamID = TE.TeamID
JOIN tblEmployee_Event E ON TE.T... |
=========================================== 1532068515
ALTER TABLE services ALTER COLUMN order_id integer DEFAULT 0;
ALTER TABLE services ADD COLUMN timeout integer DEFAULT 30;
=========================================== 1530841150
ALTER TABLE core ADD COLUMN use_cdn bool DEFAULT FALSE;
================================... |
create database newsRss;
use newsRss;
create table noticia
(
not_id INT NOT NULL PRIMARY KEY AUTO_INCREMENT,
not_author VARCHAR(50),
not_title VARCHAR(100),
not_description TEXT,
not_url VARCHAR(200),
not_urlToImage VARCHAR(200),
not_publishedAt VARCHAR (30),
not_content TEXT
);
|
create database dbpersona;
use dbpersona;
create table tpersona
(
idPersona int auto_increment not null,
nombre varchar(70) not null,
apellido varchar(70) not null,
correoElectronico varchar(700) not null,
contrasenia text not null,
extensionAvatar varchar(20) not null,
fechaNacimiento datetime not null,
estatura floa... |
# ************************************************************
# Sequel Pro SQL dump
# Version (null)
#
# https://www.sequelpro.com/
# https://github.com/sequelpro/sequelpro
#
# Host: localhost (MySQL 8.0.20)
# Database: skeezrxcco
# Generation Time: 2020-06-26 21:21:29 +0000
# *****************************************... |
EXEC [EST].[Proc_yjbb_Ins] @Code = N'600213',@CutoffDate = N'2017-09-30',@EPS = N'0.11',@EPSDeduct = N'0',@Revenue = N'13.39亿',@RevenueYoy = N'-24.47',@RevenueQoq = N'-15.02',@Profit = N'2456.17万',@ProfitYoy = N'-43.38',@ProfiltQoq = N'28.79',@NAVPerUnit = N'0.7077',@ROE = N'17.23',@CashPerUnit = N'1.5426',@GrossProfit... |
<filename>udf/parse_url.sql
CREATE OR REPLACE FUNCTION udf.parse_url(url STRING)
RETURNS STRUCT<
scheme STRING,
authority STRING,
domain STRING,
username STRING,
password STRING,
port STRING,
path STRING,
query STRING,
fragment STRING
>
LANGUAGE js
AS
"""var rollup=function(){\"use strict\";\n/*! http... |
-- phpMyAdmin SQL Dump
-- version 4.9.5
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: May 01, 2021 at 08:01 PM
-- Server version: 10.2.37-MariaDB-cll-lve
-- PHP Version: 7.3.27
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!... |
<filename>static/sk_user.sql
/*
Navicat MySQL Data Transfer
Source Server : outline_中网科技
Source Server Version : 50719
Source Host : 192.168.0.50:3306
Source Database : zhonweb
Target Server Type : MYSQL
Target Server Version : 50719
File Encoding : 65001
Date: 2018-05-10 16:08:32
... |
-- Upgrade the anthropology collectionobject extension. Move nagpra cultural determinations into
-- the the note field in the new nagpra determination group (DRYD-820).
DO $$
DECLARE
trow record;
maxpos int;
uuid varchar(36);
BEGIN
-- For new install, if collectionobjects_nagpra_nagpraculturaldetermin... |
-- menu top
UPDATE `sys_menu_top` SET `Picture` = 'check-empty' WHERE `Name` = 'Board';
-- objects: actions
UPDATE `sys_objects_actions` SET `Icon` = 'check-empty' WHERE `Type` = 'bx_photos' AND `Eval` LIKE '%_board_action_paint%';
-- chart
DELETE FROM `sys_objects_charts` WHERE `object` = 'bx_bo... |
create or replace function management.get_instances
()
returns table
(
instance_name varchar,
hostname varchar,
http_management_port integer,
last_config_get_date timestamp
)
as $$
select
i.instance_name,
i.hostname,
i.http_management_port,
i.last_config_get_date
from configuration.instance i;
$$ lang... |
SELECT COUNT(response_) as q_completed FROM response
where assignment_ = :assignment and student_ = :student
|
--------------------------------------------------------------------------------
-- Copyright (c) 2016 Oracle and/or its affiliates
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
... |
-- Role Data
INSERT INTO PUBLIC.ROLE (ROLE_INDEX, ROLE_NAME, ROLE_TARGET_HOSTS, ROLE_SHORT_DESC, ROLE_LONG_DESC) VALUES (1, 'master_controller_lead_varification', 'master', 'Master Controller Lead Verification', 'Who is the lead controller among masters?');
INSERT INTO PUBLIC.ROLE (ROLE_INDEX, ROLE_NAME, ROLE_TARGET_H... |
<gh_stars>0
/*
Navicat MySQL Data Transfer
Source Server : localhost_3306
Source Server Version : 50714
Source Host : localhost:3306
Source Database : mall
Target Server Type : MYSQL
Target Server Version : 50714
File Encoding : 65001
Date: 2020-04-21 00:33:36
*/
SET FOREIGN_KEY_C... |
startcode PostgreSql_TimeoutRemoveBySagaIdSql
delete from "public"."EndpointNameTimeoutData"
where "SagaId" = @SagaId
endcode
|
<reponame>kuro-channel/knowledge-1<gh_stars>100-1000
SELECT * FROM PASSWORD_RESETS
WHERE
ID = ?
;
|
create or replace view analysis_pii.regional_partner_stats_csp_csd_view
AS
with completed as
(
select
studio_person_id,
case when cc.course_name = 'csp' then 'CS Principles'
when cc.course_name in ('csd','csd_half') then 'CS Discoveries'
end as course,
school_year
from analysis.csp_csd_co... |
CREATE TABLE `clientes` ( `idclientes` int(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY, `nome` varchar(45), `telefone` varchar(15), `email` varchar(80), `foto` varchar(80));
INSERT INTO `clientes` VALUES (1,'<NAME>','4899454776','<EMAIL>','teste1.png');
INSERT INTO `clientes` VALUES (2,'<NAME>','4899454776','<EMAIL>',... |
<filename>src/SharedPipelineComponents/DataLockEvents/DeployDataLock/sql/ddl/datalockevents.transient.ddl.views.periodend.sql
IF NOT EXISTS (SELECT [schema_id] FROM sys.schemas WHERE [name] = 'DataLockEvents')
BEGIN
EXEC('CREATE SCHEMA DataLockEvents')
END
GO
-------------------------------------------------------... |
<reponame>nabeelkhan/Oracle-DBA-Life<gh_stars>0
REM indexBy.sql
REM Chapter 8, Oracle9i PL/SQL Programming by <NAME>
REM This file contains several examples of index-by tables.
DECLARE
TYPE NameTab IS TABLE OF students.first_name%TYPE
INDEX BY BINARY_INTEGER;
TYPE DateTab IS TABLE OF DATE
INDEX BY BINARY_I... |
-- phpMyAdmin SQL Dump
-- version 4.7.0
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Mar 05, 2018 at 04:26 PM
-- Server version: 10.1.25-MariaDB
-- PHP Version: 7.1.7
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD... |
<gh_stars>0
CREATE TABLE SENSOR (
SENSOR_ID SERIAL PRIMARY KEY,
DESCRIPTION VARCHAR(100)
);
CREATE TABLE DATA_TYPE (
DATA_TYPE_ID SERIAL PRIMARY KEY,
DESCRIPTION VARCHAR(20)
);
CREATE TABLE DATA (
DATA_ID SERIAL PRIMARY KEY,
VALUE REAL NOT NULL,
DATA_TYPE_ID INTEGER NOT NULL,
TIME ... |
/*
Navicat MySQL Data Transfer
Source Server : xampp
Source Server Version : 50624
Source Host : localhost:3306
Source Database : ci_ajax
Target Server Type : MYSQL
Target Server Version : 50624
File Encoding : 65001
Date: 2015-06-27 10:30:24
*/
SET FOREIGN_KEY_CHEC... |
--https://www.hackerrank.com/challenges/revising-aggregations-the-count-function/problem
/*
Enter your query here.
Please append a semicolon ";" at the end of the query and enter your query in a single line to avoid error.
*/
SELECT COUNT(*)
FROM CITY
WHERE POPULATION > 100000;
|
-- phpMyAdmin SQL Dump
-- version 5.0.4deb2ubuntu5
-- https://www.phpmyadmin.net/
--
-- Servidor: localhost:3306
-- Tiempo de generación: 15-02-2022 a las 19:06:06
-- Versión del servidor: 8.0.28-0ubuntu0.21.10.3
-- Versión de PHP: 7.4.27
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:... |
<reponame>devotox/platform-base
\i domains/gender.sql;
|
<reponame>G-Simeone/Learning_Accident_Occurence_on_Dutch_Highways<filename>database/archive/find_nearest_hecto_per_loop.sql
-- NOTE: This file is not currently being used. We are using the dataset provied by CSResearch, rws_raw.utrecht_rws_loops to get the closest hecto
-- This file may be useful when we need to query... |
<filename>data/train/sql/ba54a952ce4343fa3d726a8106d61a6a55f5df31BAREME_CONSTRAINT.sql
--------------------------------------------------------
-- Constraints for Table BAREME
--------------------------------------------------------
ALTER TABLE "G11_FLIGHT"."BAREME" ADD CONSTRAINT "PK_BAREME" PRIMARY KEY ("CAT_NUM"... |
<reponame>Shuttl-Tech/antlr_psql
-- file:domain.sql ln:210 expect:true
SELECT cast('1' as dnotnull)
|
<filename>src/test/resources/sql/drop_operator_class/acb8b392.sql
-- file:drop_if_exists.sql ln:218 expect:true
DROP OPERATOR CLASS IF EXISTS test_operator_class USING btree
|
<reponame>chengwenxin/sqlite-parser<filename>test/sql/official-suite/check-1.sql
-- original: check.test
-- credit: http://www.sqlite.org/src/tree?ci=trunk&name=test
CREATE TABLE t1(
x INTEGER CHECK( x<5 ),
y REAL CHECK( y>x )
)
;INSERT INTO t1 VALUES(3,4);
SELECT * FROM t1
;SELECT * FROM t1
;SEL... |
<gh_stars>10-100
-- 1
CREATE TABLE salary_raise(
Instructor_ID NUMBER(5),
Raise_date DATE,
Raise_amt NUMERIC(10,2)
);
DECLARE
CURSOR raise_cursor IS
SELECT * FROM Instructor WHERE dept_name = 'Biology' FOR UPDATE;
raise_amt NUMERIC(8, 2);
BEGIN
FOR i IN raise_cursor
LOOP
raise_amt := i.salary ... |
<reponame>samszo/MEDAS-1_20-21
-- MySQL Script generated by MySQL Workbench
-- Tue May 4 10:40:17 2021
-- Model: New Model Version: 1.0
-- MySQL Workbench Forward Engineering
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQ... |
<gh_stars>1-10
/*
Navicat MySQL Data Transfer
Source Server : wvanheem_core_local
Source Server Version : 50509
Source Host : 127.0.0.1
Source Database : core
Target Server Version : 50509
File Encoding : utf-8
Date: 06/22/2012 17:54:34 PM
*/
SET NAMES utf8;
SET FOREIGN_KEY_C... |
CREATE SCHEMA `sc2021` ;
drop table sc2021.author;
drop table sc2021.post;
drop table sc2021.comment;
drop table sc2021.candidate;
drop table sc2021.login;
CREATE TABLE IF NOT EXISTS sc2021.`author` (
`author_Id` INT UNSIGNED unsigned NOT NULL AUTO_INCREMENT,
`author_name` varchar(255) CHARACTER SET utf8mb4 COLLA... |
<filename>importer/src/main/resources/scripts/component-centric/component-centric-snapshot-description-casesignificanceid.sql
/********************************************************************************
component-centric-snapshot-description-casesignificanceid
Assertion:
Case-sensitive terms have appropriate... |
<gh_stars>1-10
select * from users;
-- alter table users add column date varchar(30); |
<reponame>Rob--W/phabricator<filename>resources/sql/patches/056.slowvote.sql<gh_stars>1000+
CREATE TABLE {$NAMESPACE}_slowvote.slowvote_poll (
id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
question VARCHAR(255) NOT NULL,
phid VARCHAR(64) BINARY NOT NULL,
UNIQUE KEY (phid),
authorPHID VARCHAR(64) BINARY... |
SELECT
c.oid,
c.conparentid::bigint
FROM
pg_catalog.pg_constraint c
|
INSERT INTO active_operating_systems_t(_id, name)
VALUES (0, 'common'),
(1, 'Mac'),
(2, 'Mac32'),
(3, 'Mac64'),
(4, 'Win'),
(5, 'Win32'),
(6, 'Win64');
|
create table auto_bid_history (
task_id int not null,
miner_id int not null,
create_at bigint not null,
constraint pk_auto_bid_history primary key (create_at,miner_id,task_id)
) engine = innodb
partition by range (create_at) (
partition part_max values less than maxvalue
) |
<filename>prisma/init/17.13.sql
INSERT INTO "Jutsu" ("id", "name", "description", "kanji", "romaji", "portugues", "games", "mangaPanini", "tvBrasileira", "range", "rank", "handSeals") VALUES
(1514, E'Liberação de Água: Técnica da Grande Cachoeira', E'Esta técnica estende água sobre ondas em larga escala e sobe até vár... |
<reponame>Jake-Gillberg/Vocabulary-v5.0
--add new vocabulary_id='CCAM' and new concept_class [AVOF-2780]
DO $_$
BEGIN
PERFORM VOCABULARY_PACK.AddNewVocabulary(
pVocabulary_id => 'CCAM',
pVocabulary_name => 'Common Classification of Medical Acts',
pVocabulary_reference => 'https://www.ameli.fr/accueil-de-la-ccam/... |
<gh_stars>0
CREATE TABLE `venue` (
`venue_id` int(11) NOT NULL AUTO_INCREMENT,
`venue_name` varchar(45) COLLATE utf8_unicode_ci DEFAULT NULL,
`venue_address` varchar(45) COLLATE utf8_unicode_ci DEFAULT NULL,
`latitude` varchar(45) COLLATE utf8_unicode_ci DEFAULT NULL,
`longitude` varchar(45) COLLATE utf8_unic... |
<gh_stars>0
-- SPDX-License-Identifier: Apache-2.0
-- Licensed to the Ed-Fi Alliance under one or more agreements.
-- The Ed-Fi Alliance licenses this file to you under the Apache License, Version 2.0.
-- See the LICENSE and NOTICES files in the project root for more information.
-- remove foreign keys
IF EXISTS(SELEC... |
CREATE TABLE `mdl_elp_course_info` (
`id` bigint(10) NOT NULL AUTO_INCREMENT,
`course_title` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
`course_id` bigint(10) NOT NULL DEFAULT 0,
`section_title` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
`section_id` bigint(10) NOT NULL DEFAULT 0,
`section_ord... |
SET NOCOUNT ON;
DECLARE @ErrorTable TABLE ([Col1] INT PRIMARY KEY);
INSERT INTO @ErrorTable ([Col1]) VALUES (1);
INSERT INTO @ErrorTable ([Col1]) VALUES (1);
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.