sql stringlengths 6 1.05M |
|---|
<gh_stars>0
INSERT INTO USER_ (USER_ID, DISTINGUISHED_NAME, SURNAME, FORENAME, PRIVATE, ORGANISATION_ID)
VALUES (1, 'NationalUser', 'User', 'National', 0, 1);
INSERT INTO USER_ (USER_ID, DISTINGUISHED_NAME, SURNAME, FORENAME, PRIVATE, ORGANISATION_ID)
VALUES (2, 'OlIvEr.cOnNoLlY', 'Connolly', 'Oliver', 0, 1);
INSERT ... |
<gh_stars>0
CREATE TABLE [dbo].[Applicant] (
[ApplicantId] INT IDENTITY (1, 1) NOT NULL,
[Name] VARCHAR (100) NOT NULL,
[CreditScore] INT NULL,
[DateOfBirth] DATE NOT NULL,
PRIMARY KEY CLUSTERED ([ApplicantId] ASC)
);
|
<reponame>peace-shillong/Computer-Applications-Theory-and-Practical-Part-2
create or replace trigger first_trigger
before insert on locations
for each row
begin
dbms_output.put_line('Trigger Fired');
dbms_output.put_line('User Name: '||user);
dbms_output.put_line ('Date: '||sysdate());
dbms_output.put_line('Ins... |
/*
Navicat Premium Data Transfer
Source Server : localhost
Source Server Type : MySQL
Source Server Version : 100406
Source Host : localhost:3306
Source Schema : dbpos
Target Server Type : MySQL
Target Server Version : 100406
File Encoding : 65001
Date: 16/11/2020 17... |
<filename>examples/elm-todomvc/schema.sql
-- elm-drec-todomvc schema for PostgREST
create schema api;
create table api.model (
uid INTEGER DEFAULT 0
, field TEXT DEFAULT ''
, visibility TEXT DEFAULT 'All'
, entries JSONB DEFAULT '[]'
);
insert into api.model (uid, visibility) values (0 , 'All');
grant all on sche... |
<reponame>M2mobi/lunr<filename>tests/statics/Gravity/Database/MySQL/input_cte.sql
WITH `teste` AS (
SELECT
`c`.`language` as `lang`,
RAND() as `num`
FROM
`table1` as `c`
LEFT JOIN
`table2` as `fb` ON `c`.`id`=`fb`.`id`
WHERE
COALESCE(NULL,1) = 1
... |
<reponame>technology16/dbreplicator2<filename>src/test/resources/sql_query/sql_update.sql
UPDATE t_table SET _boolean = true, _long = 0, _decimal = 0, _double = 0, _float = 0, _string = 'Update', _byte = 0, _date = now(), _time = now(), _timestamp = now() WHERE _int = 1;
UPDATE t_table1 SET _boolean = true, _long = 0, ... |
<filename>src/main/resources/db/migration/V46__User_Chat_Forum.sql<gh_stars>10-100
ALTER TABLE user drop chat_flag;
ALTER TABLE user drop forum_flag;
ALTER TABLE user add chat_username VARCHAR(25); |
<filename>extension/tpcds/dsdgen/queries/83.sql<gh_stars>1000+
WITH sr_items AS
(SELECT i_item_id item_id,
sum(sr_return_quantity) sr_item_qty
FROM store_returns,
item,
date_dim
WHERE sr_item_sk = i_item_sk
AND d_date IN
(SELECT d_date
FROM date_dim
WHERE d_... |
GRANT USAGE ON LANGUAGE plpythonu TO etl;
|
<reponame>tbowan/luchronia<filename>SQL/structure/01/09/10-ToolCorrection.sql<gh_stars>0
#------------------------------------------------------------------------------
# Création de l'outil du pharmacien
#------------------------------------------------------------------------------
insert into game_ressource_item
... |
<gh_stars>0
--create database icq;
create table if not exists users(
id serial primary key,
name varchar(200)
);
create table if not exists message(
id serial primary key,
message varchar(2000),
id_user int references users(id));
--insert into users(name) values('Vasia'),('Petia'),('Kolia'),('Sasha'),('Natasha');
sele... |
DROP TABLE IF EXISTS groups;
CREATE TABLE groups
(
name varchar(32) NOT NULL,
roles varchar(64) NOT NULL COMMENT '英文逗号分隔',
PRIMARY KEY (name)
)
ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='组对应角色表';
|
<reponame>jambulud/devon4j
-- *** BinaryObject (BLOBs) ***
CREATE TABLE BinaryObject (
id NUMBER(19),
modificationCounter NUMBER(10, 0) NOT NULL,
content BLOB,
filesize NUMBER(10, 0) NOT NULL,
mimeType VARCHAR(255),
CONSTRAINT PK_BinaryObject_id PRIMARY KEY... |
ALTER TABLE domain DROP COLUMN assignment;
ALTER TABLE custom_domain DROP COLUMN assignment;
|
CREATE TABLE [dbo].[Users] (
[Id] INT CONSTRAINT [PK_Users] PRIMARY KEY IDENTITY,
[ExternalId] NVARCHAR (450), -- Subject for human users and ClientId for service accounts
[InvitedAt] DATETIMEOFFSET(7),
[State] AS CAST(IIF([ExternalId] IS NOT NULL, 2, IIF([InvitedAt] IS NOT NULL, 1, 0)) AS TINYIN... |
set max_parallel_workers_per_gather to 0;
set work_mem to 1000000;
set decision_method to dp;
set memory_budget to :v_budget;
set tpch_delta_mode to :v_mode;
set bd_prob to :v_prob;
set enable_incremental to on;
set tpch_updates to 'customer,orders,lineitem';
set iqp_query to 'q3';
set gen_mem_info to off;
select... |
--add DATETIMELTZ columns, using alter ... add statement, no data in the table
set system parameters 'add_column_update_hard_default=no';
drop table if exists ltz;
create table ltz(a int);
--test: add column with default
alter table ltz add c_dtltz1 datetime with local time zone default '2003-01-01 2:00:00.789 -8:00... |
ALTER TABLE "permissions"."GroupRegistrant"
RENAME CONSTRAINT "GroupAttendee_attendeeId_fkey" TO "GroupRegistrant_registrantId_fkey";
ALTER TABLE "permissions"."GroupRegistrant"
RENAME CONSTRAINT "GroupAttendee_groupId_fkey" TO "GroupRegistrant_groupId_fkey";
ALTER TABLE "permissions"."GroupRegistrant"
RENA... |
<gh_stars>0
INSERT INTO oef6 VALUES ("Brent", "Berghmans", 18);
INSERT INTO oef6 VALUES ("Matthijs", "Kaminski", 19);
INSERT INTO oef6 VALUES ("Axel", "Faes", 19);
INSERT INTO oef6 VALUES ("Olivier", "<NAME>", 18);
INSERT INTO oef6 VALUES ("Tina", "Berghmans", 25);
INSERT INTO oef6 VALUES ("Wesley", "Bervoets", 18); |
/*
Navicat MySQL Data Transfer
Source Server : 127.0.0.1
Source Server Version : 50505
Source Host : localhost:3306
Source Database : indoor_location
Target Server Type : MYSQL
Target Server Version : 50505
File Encoding : 65001
Date: 2018-03-26 17:28:45
*/
SET FOREIGN_KEY_CHECKS=... |
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Jan 21, 2022 at 05:29 PM
-- Server version: 10.4.14-MariaDB
-- PHP Version: 7.4.9
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIEN... |
CREATE PROCEDURE [dbo].[Update_Event]
(
@Season int,
@EventCode nvarchar(max),
@DistrictCode nvarchar(max),
@DivisionCode nvarchar(max),
@Name nvarchar(max),
@Type nvarchar(max),
@Venue nvarchar(max),
@Address nvarchar(max),
@City nvarchar(max),
@Country nvarchar(max),
@StateProv nvarchar(max),
@DateStart ... |
-- phpMyAdmin SQL Dump
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
-- --------------------------------------------------------
--
-- Table structure for table `payments`
--
CREATE TABLE `payments` (
`id` int(11) NOT NULL,
`order_id` int(11) NOT NULL,
`paypal_payment_id` text,
`paypa... |
SELECT * INTO STRICT result FROM precompute_queue;
PERFORM assert(result.key = 'test.in2');
|
<gh_stars>1-10
-- ----------------------------------------------------------------------
-- user preferences
--
-- Record preferences for portal users
-- ----------------------------------------------------------------------
-- avoid innocuous NOTICEs about automatic sequence creation
set client_min_messages='WARNING'... |
DROP TABLE if exists semantic.oa CASCADE;
CREATE TABLE semantic.oa AS (
WITH oa_geo AS(
SELECT
oa11cd as oa11,
geometry,
centroid,
snapped_centroid as snapped_centroid, -- Taking only the snapped one
latitude as snapped_latitude,
longi... |
INSERT INTO public.role_permission (role_id, permissions)
VALUES (1, 'DELETE_POST'); |
<reponame>sapiderman/hyper-wallet<filename>migrations/Drop_all_tables.sql
use wallet;
DROP TABLE accounts;
DROP TABLE currencies;
DROP TABLE journals;
DROP TABLE transactions;
|
-- autovacuum.test
--
-- execsql {
-- DROP TABLE av2;
-- SELECT rootpage FROM sqlite_master ORDER BY rootpage;
-- }
DROP TABLE av2;
SELECT rootpage FROM sqlite_master ORDER BY rootpage; |
<gh_stars>100-1000
-- Keycloak table creation
-- Keycloak database Creation
-- Create access role for keycloak
CREATE ROLE keycloak WITH PASSWORD '<PASSWORD>' NOSUPERUSER LOGIN;
-- Create database for keycloak
CREATE DATABASE keycloak;
-- Grant all permissions to user keycloak
GRANT ALL ON DATABASE keycloak TO keyc... |
<filename>order_entry_human_resources/data/oehr_product_information.sql
-- Script generated by PLEX version 2.4.0 - more infos here: https://github.com/ogobrecht/plex
-- Performance Hacks by <NAME>: https://connor-mcdonald.com/2019/05/17/hacking-together-faster-inserts/
-- For strange line end replacements a big thank ... |
/* To prevent any potential data loss issues, you should review this script in detail before running it outside the context of the database designer.*/
BEGIN TRANSACTION
SET QUOTED_IDENTIFIER ON
SET ARITHABORT ON
SET NUMERIC_ROUNDABORT OFF
SET CONCAT_NULL_YIELDS_NULL ON
SET ANSI_NULLS ON
SET ANSI_PADDING ON
SE... |
# --- Created by Ebean DDL
# To stop Ebean DDL generation, remove this comment and start using Evolutions
# --- !Ups
create table diretor (
id bigint not null,
nome varchar(255),
constraint pk_diretor primary key (id))
;
create table filmes_cult (
id ... |
<reponame>devLopez/gerenciamento_locacoes<filename>install/locacao.sql
-- phpMyAdmin SQL Dump
-- version 4.0.10deb1
-- http://www.phpmyadmin.net
--
-- Máquina: localhost
-- Data de Criação: 18-Fev-2015 às 14:21
-- Versão do servidor: 5.5.41-0ubuntu0.14.04.1
-- versão do PHP: 5.5.9-1ubuntu4.6
SET SQL_MODE = "NO_AUTO_VA... |
<filename>dbms/tests/queries/0_stateless/00214_primary_key_order.sql<gh_stars>1-10
DROP TABLE IF EXISTS test.primary_key;
CREATE TABLE test.primary_key (d Date DEFAULT today(), x Int8) ENGINE = MergeTree(d, -x, 1);
INSERT INTO test.primary_key (x) VALUES (1), (2), (3);
SELECT x FROM test.primary_key ORDER BY x;
SELE... |
<filename>searchbox.sql
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Nov 26, 2021 at 11:57 AM
-- Server version: 10.4.14-MariaDB
-- PHP Version: 7.2.33
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET... |
<gh_stars>1-10
BEGIN;
ALTER TABLE updv DROP CONSTRAINT updv_pkey;
ALTER TABLE updv ADD COLUMN id SERIAL PRIMARY KEY;
COMMIT; |
CREATE PROCEDURE [dbo].[GetCustomID]
@length int = 5,
@chars nvarchar(MAX) = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789',
@pattern nvarchar(MAX) = '?????',
@id nvarchar(MAX) OUTPUT
AS
DECLARE
@count int = 0,
@result nvarchar(MAX) = '',
@charlen int = Len(@chars),
@found bit = 0,
@patter... |
<reponame>Stathislyb/VirtualDM
-- phpMyAdmin SQL Dump
-- version 4.7.4
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Dec 27, 2017 at 10:15 AM
-- Server version: 10.1.29-MariaDB
-- PHP Version: 7.2.0
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone ... |
-- Convert schema '/home/hmai/Projekte/Tapper/src/Tapper-Schema/lib/auto/Tapper/Schema/Tapper-Schema-TestrunDB-3.000005-MySQL.sql' to 'Tapper::Schema::TestrunDB v4.001001':;
BEGIN;
SET foreign_key_checks=0;
ALTER TABLE user RENAME TO owner;
ALTER TABLE message CHANGE COLUMN message message text,
... |
<reponame>theresadower/VO-Directory<gh_stars>1-10
USE [VORegTAP]
GO
/****** Object: StoredProcedure [rr].[deletedeprecatedresourcefromtapcache] Script Date: 3/21/2016 12:02:35 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
--TODO: geenrate CREATE TABLE statements from tables after key and index manag... |
<reponame>opengauss-mirror/Yat
-- @testpoint:opengauss关键字old(非保留),作为视图名
--关键字explain作为视图名,不带引号,创建成功
CREATE or replace VIEW old AS
SELECT * FROM pg_tablespace WHERE spcname = 'pg_default';
drop view old;
--关键字explain作为视图名,加双引号,创建成功
CREATE or replace VIEW "old" AS
SELECT * FROM pg_tablespace WHERE spcname = 'pg_defa... |
<filename>web_ii_mi.sql
-- phpMyAdmin SQL Dump
-- version 4.7.9
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Dec 18, 2018 at 07:27 AM
-- Server version: 10.1.31-MariaDB
-- PHP Version: 7.2.3
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:... |
<gh_stars>0
-- operations
CREATE INDEX ix_operations_transactions_source_operation_id
ON tezos.operations USING btree
(source, operation_id)
WHERE kind='transaction';
CREATE INDEX ix_operations_transactions_destination_operation_id
ON tezos.operations USING btree
(destination, operation_id)
... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 5.0.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Apr 12, 2021 at 11:07 AM
-- Server version: 10.4.11-MariaDB
-- PHP Version: 7.4.3
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:... |
-- ***************************************************************************
-- File: 10_17.sql
--
-- Developed By TUSC
--
-- Disclaimer: Neither Osborne/McGraw-Hill, TUSC, nor the author warrant
-- that this source code is error-free. If any errors are
-- found in this source code, please rep... |
<gh_stars>0
CREATE TABLE "checklists" (
"id" SERIAL PRIMARY KEY,
"title" TEXT
);
insert into checklists (title) values
('backend'),
('shopping');
CREATE TABLE "checklistitems" (
"id" SERIAL PRIMARY KEY,
"name" TEXT NOT NULL,
"finished" BOOLEAN NOT NULL,
"checklist" INTEGER NOT NULL... |
<reponame>zettasolutions/zsi-fmis
CREATE PROCEDURE [dbo].[other_income_sel]
(
@other_income_id INT = null
,@user_id INT = NULL
)
AS
BEGIN
DECLARE @stmt VARCHAR(4000);
SET @stmt = 'SELECT * FROM dbo.other_income WHERE 1=1 ';
IF @other_income_id <> ''
SET @stmt = @stmt + ' AND other_income_id'... |
<filename>db.sql
CREATE TABLE IF NOT EXISTS `core_roles` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`name` varchar(255) NOT NULL DEFAULT '',
`is_active_sw` enum('Y','N') NOT NULL DEFAULT 'Y',
`lastupdate` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`description` varchar(255... |
-- --------------------------------------------------------
--
-- Table structure for table `seat_matrix`
--
DROP TABLE IF EXISTS `seat_matrix`;
CREATE TABLE IF NOT EXISTS `seat_matrix` (
`BID` int(11) NOT NULL,
`RID` int(11) NOT NULL,
`SeatNo` int(11) NOT NULL,
`Passenger` int(11) DEFAULT NULL,
`BusDate` ... |
<reponame>aman-gupta-1995/SQL-Data-Analysis-and-Data-Visualisation-Projects
/************ Basic Statistics with SQL ************/
SELECT * FROM company_divisions
LIMIT 5;
SELECT * FROM company_regions
LIMIT 5;
SELECT * FROM staff
LIMIT 5;
/* How many total employees in this company */
SELECT COUNT(*) FROM staff;
... |
-- phpMyAdmin SQL Dump
-- version 4.8.3
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Nov 28, 2018 at 10:09 PM
-- Server version: 10.1.35-MariaDB
-- PHP Version: 7.2.9
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD... |
SELECT
SUBTT_PK AS key,
SUBTT_SPTT_FK AS panelTestType,
SUBTT_STT_FK AS testType
FROM cnprcSrc_srl.SRL_SUB_TEST_TYPES |
<reponame>Agera-CatenaX/SpikeEclipseConnectorPRSTractusx
-- Synthetic data generated for testing/demonstration purposes only
COPY public.part_aspect (name, oneidmanufacturer, objectidmanufacturer, url, effect_time, last_modified_time) FROM stdin;
CE BOSCH PLFVTZL http://aspect-BOSCH/CE/1234 2021-09-06 17:27:11.775054 2... |
alter table bar drop constraint fk_bar_foo_id;
drop index ix_bar_foo_id;
alter table o_address drop constraint fk_o_address_country_code;
drop index ix_o_address_country_code;
alter table animals drop constraint fk_animals_shelter_id;
drop index ix_animals_shelter_id;
alter table attribute drop constraint fk_attribu... |
CREATE TABLE "TACC_DUP"
( "BARCODE" VARCHAR2(255 CHAR),
"FOLDER" VARCHAR2(255 CHAR),
"CHECKSUM" VARCHAR2(255 CHAR),
"STATUS" VARCHAR2(255 CHAR)
) |
<gh_stars>1-10
CREATE FUNCTION migrate() RETURNS void AS $$
DECLARE
next_version int ;
BEGIN
SELECT stage_three + 1 INTO next_version FROM schema_version ;
IF next_version <= 7 THEN
-- Indexes which optimize inserting new rewards
CREATE INDEX idx_stake_address_view ON stake_address USING hash (view);
... |
-- create backups
CREATE TABLE client_authorizations_bak AS SELECT * FROM client_authorizations ;
CREATE TABLE client_authorization_logs_bak AS SELECT * FROM client_authorization_logs ;
CREATE TABLE oauth2_authorization_bak AS SELECT * FROM oauth2_authorization ;
CREATE TABLE client_authorization_tokens_bak AS SELECT *... |
<gh_stars>0
INSERT INTO `specialization` (`profile_id`,`category_id`)
VALUES
(1,2),
(1,1),
(2,3),
(3,4),
(3,1),
(5,5),
(6,2),
(7,6),
(8,4),
(9,2) |
<filename>development/dbchangelog/201703121112_company-type-seed.sql
INSERT INTO
`companyType`
(`id`, `name`)
VALUES
(1, 'Shipper'),
(2, 'Shipping'),
(3, 'Truck Vendor'),
(4, 'Container Depo'); |
<gh_stars>1-10
alter table items
drop column list_id;
--;
drop table lists;
|
CREATE TABLE item(
code VARCHAR(10) PRIMARY KEY ,
title VARCHAR(255) NOT NULL,
image VARCHAR(500) NOT NULL,
rating ENUM('1','2','3','4','5') NOT NULL,
qty INT NOT NULL,
unit_price DECIMAL(5,2) N... |
DROP TABLE IF EXISTS `coffeetime`.`reservations`;
CREATE TABLE `coffeetime`.`reservations` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`date` DATE NOT NULL,
`name` varchar(64) NOT NULL,
`created_at` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
`updated_at` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP ON U... |
--
-- Add email to `user`
--
ALTER TABLE `user` ADD `email` VARCHAR(100) NULL DEFAULT NULL AFTER `password`; |
CREATE PROCEDURE usp_get_employees_salary_above(sal DECIMAL(19,4))
BEGIN
SELECT
first_name,
last_name
FROM `employees`
WHERE salary >= sal
ORDER BY first_name ASC, last_name ASC, employee_id ASC;
END;
|
BEGIN;
CREATE TABLE venue(
id SERIAL PRIMARY KEY,
name TEXT NOT NULL,
description TEXT NOT NULL,
address TEXT NOT NULL,
directions TEXT NOT NULL,
google_maps_url TEXT NOT NULL,
capacity INT NOT NULL
);
INSERT INTO venue (
name,
description,
address,
directions,
google_maps_url,
capacity
) V... |
CREATE PROC [dbo].[h3giCaptureSalesData]
/*********************************************************************************************************************
**
** Procedure Name : h3giCaptureSalesData
** Author : <NAME>
** Date Created : 31/04/2005
** Version ... |
-- phpMyAdmin SQL Dump
-- version 4.8.5
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Jul 03, 2019 at 02:41 PM
-- Server version: 10.1.38-MariaDB
-- PHP Version: 7.3.2
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD... |
<reponame>Shuttl-Tech/antlr_psql
-- file:insert.sql ln:429 expect:true
drop table mcrparted
|
drop view a cascade
|
<gh_stars>10-100
-- DB/POOL GAMEOBJECT: This fix all erros with pool gameobejct
-- Can't include on pools gameobject without pool, only can be on pools chest, mines, deposit, herbs or any gamobject with loot
DELETE FROM `pool_gameobject` WHERE `guid` IN (163683,163682,163681,164080,163680,164079,163679,164078,163678,16... |
<gh_stars>0
CREATE TABLE jhi_authority
(
name CHARACTER VARYING(50) PRIMARY KEY NOT NULL
);
INSERT INTO jhi_authority (name)
values ('ROLE_ADMIN'),
('ROLE_USER');
CREATE TABLE jhi_persistent_audit_event
(
event_id BIGSERIAL PRIMARY KEY NOT NULL,
principal CHARACTER VARYING(50) NOT NULL,
even... |
<filename>src/test/resources/patricia_db_schema/V2.1__create_view_price_list.sql<gh_stars>1-10
-- A schema dump of selected tables from Patricia v5.6.3, taken on 12nd December 2018
CREATE VIEW fv_case_price_list AS
SELECT fv.case_id , fv.case_category_id , fv.case_category_level , cpl.work_code_id , cpl.status_id , cpl... |
<gh_stars>1-10
ALTER TABLE IF EXISTS core.folder ADD COLUMN model_version_tag VARCHAR(255); |
<filename>init.sql<gh_stars>1-10
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf8 */;
/*!50503 SET NAMES utf8mb4 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-... |
DELETE FROM role_assignment_history;
DELETE FROM role_assignment_request;
DELETE FROM role_assignment;
DELETE FROM actor_cache_control;
|
<filename>MemberShip/db/MemberShip_Create_Schema.sql
/*
--------------------------------------------------------
-- MemberShip Table Schema 2015-03-09
--------------------------------------------------------
*/
CREATE DATABASE IF NOT EXISTS ms;
USE ms;
/*
--------------------------------------------------------
-- ... |
<reponame>aliymahmoud/hla
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Jul 03, 2021 at 10:44 PM
-- Server version: 10.4.13-MariaDB
-- PHP Version: 7.4.7
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SE... |
<filename>db/U110__Test.sql
DROP TABLE IF EXISTS `test_110`; |
--
-- Create a new account with same privileges as those of given grantee.
-- Initial password for new account is also duplicated from existing account.
--
DELIMITER $$
DROP PROCEDURE IF EXISTS duplicate_grantee $$
CREATE PROCEDURE duplicate_grantee(
IN existing_grantee TINYTEXT CHARSET utf8,
IN new_grantee ... |
<gh_stars>100-1000
-- bigfile.test
--
-- execsql {
-- SELECT md5sum(x) FROM t2;
-- }
SELECT md5sum(x) FROM t2; |
CREATE TABLE [employer_financial].[Account]
(
[Id] BIGINT NOT NULL PRIMARY KEY,
[Name] NVARCHAR(100) NOT NULL
)
|
SELECT DISTINCT s.site_number, s.name as site_name
FROM site s, site_contact_detail_map d_map, mot_test_current mtc
WHERE mtc.mot_test_type_id IN (1,9)
AND s.id = mtc.site_id
AND d_map.site_id = s.id
AND d_map.contact_detail_id IS NOT NULL
AND s.site_number != "0"
AND s.type_id = 3
LIMIT 30 |
drop table users;
drop view user_infos;
drop table posts;
|
<filename>slim_api.sql
-- phpMyAdmin SQL Dump
-- version 4.6.5.2
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Jun 10, 2017 at 01:24 PM
-- Server version: 10.1.21-MariaDB
-- PHP Version: 7.1.1
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET... |
<gh_stars>10-100
-- file:regex.sql ln:49 expect:true
select regexp_matches('ab', 'a(?<=a)b*(?<=b)c*')
|
-- ========================
-- Information
-- ========================
-- Direct Link: https://www.hackerrank.com/challenges/weather-observation-station-16/problem
-- Difficulty: Easy
-- Max Score: 10
-- DBMS: mySQL
-- ========================
-- Solution
-- ========================
SELECT ROUND(MIN(LA... |
<reponame>dykyi-roman/service-oriented_architecture
CREATE DATABASE IF NOT EXISTS db;
CREATE DATABASE IF NOT EXISTS db_test; |
SET DEFINE OFF
SET SERVEROUTPUT ON
DECLARE
MAXKIM_TYP_ID NUMBER;
MAXKIM_ATTR_DEFN_ID NUMBER;
MAXKIM_TYP_ATTR_ID NUMBER;
MAXPERM_TMPL_ID NUMBER;
MAXPERM_ID NUMBER;
MAXATTR_DATA_ID NUMBER;
MAXROLE_ID NUMBER;
MAXROLE_PERM_ID NUMBER;
MAXGRP_ID NUMBER;
MAXRSP_ID NUMBER;
MAXROLE_RSP_ID NUMBER;
MAXROLE... |
COPY config.clo (alias_name, file_type, table_name) FROM STDIN;
ANCHOR 0 spcwatch
VOR 0 vors
SFSTNS 0 sfstns
MARINE 0 marine
COASTAL 0 coastal
COUNTY 0 county
CITIES 0 cities
VOLCANO 0 volcano
ISLAND 0 island
NEXRAD 0 nexrad
WR_QPF 0 wrqpf
CNTY_BNDS 1 countybnds
CWA_BNDS 1 cwabnds
GREAT_LAKES 1 greatlakesbnds
LAKES 1 l... |
-- テーブル削除
DROP TABLE IF EXISTS test_table;
-- テーブル作成
CREATE TABLE IF NOT EXISTS test_table
(
gid INTEGER PRIMARY KEY,
geom GEOMETRY(POINT, 4612)
);
|
# Inner SELECT filters just the records in which we are interested.
# Outer SELECT performs our analysis, in this case just a count of the genotypes
# at a particular position in chromosome 3.
SELECT
reference_name,
start,
reference_bases,
alternate_bases,
genotype,
COUNT(genotype) AS number_of_individuals,... |
{%- macro next_week_start_date(tz=None) -%}
{{ dbt_date.next_week(1, tz) }}
{%- endmacro -%} |
-- ## Inserting into table: animal_species ## --
-- ## Inserting Item: 0 ## --
INSERT INTO animal_species(common_name,scientific_name,species_class)
VALUES
('American black duck','Anas rubripes','Birds');
-- ## End of item: 0 ## --
-- ## Inserting Item: 1 ## --
INSERT INTO animal_species(common_name,scientific_name,s... |
<filename>sql/function/escape/int8.sql
SELECT pgroonga_escape(292929292929::int8);
SELECT pgroonga_escape(-292929292929::int8);
|
CREATE TABLE [dbo].[Disponibility]
(
[Id] INT NOT NULL PRIMARY KEY IDENTITY,
[Operation] INT NOT NULL,
[Disponible] BIT NOT NULL,
[TimeUpdated] DATETIME2 NULL DEFAULT getutcdate()
FOREIGN KEY (Operation) REFERENCES OPERATION(Id)
)
|
SELECT DISTINCT
month1,
month2
LIMIT 100 |
<reponame>DeeptiVaidhya/jobolytics<filename>jobolytics.sql
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Aug 08, 2020 at 08:42 PM
-- Server version: 5.7.30-0ubuntu0.16.04.1
-- PHP Version: 7.4.7
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Hôte : 127.0.0.1:3306
-- Généré le : sam. 03 juil. 2021 à 19:48
-- Version du serveur : 5.7.31
-- Version de PHP : 7.3.21
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CH... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.