sql stringlengths 6 1.05M |
|---|
BEGIN TRANSACTION;
INSERT INTO GameObjectContainers (GameObjectContainerId, Description) VALUES (1, "Arathi Basin");
COMMIT;
|
ALTER TABLE `logs_logbooks` DROP COLUMN `state`,
DROP COLUMN `created`,
DROP COLUMN `status_id`,
DROP INDEX `logs_logbooks_status_id_fk`,
DROP FOREIGN KEY `logs_logbooks_status_id_fk`; |
<reponame>jeffersonfantasia/SQL_Scripts<gh_stars>1-10
SELECT F.CODFILIAL,
P.CODPRODMASTER CODPROD_PAI,
(
SELECT DESCRICAO
FROM PCPRODUT
WHERE CODPROD = P.CODPRODMASTER
) DESCRICAO_PAI,
P.CODPROD,
P.DESCRICAO,
F.ENVIARFORCAVENDAS ENVIARFORCAVE... |
<reponame>timshadel/subdivision-list
CREATE TABLE subdivision_WS (id VARCHAR(6) NOT NULL, name VARCHAR(255), level VARCHAR(64) NOT NULL, PRIMARY KEY(id));
INSERT INTO "subdivision_WS" ("id", "name", "level") VALUES ('WS-AL', 'Aiga-i-le-Tai', 'district');
INSERT INTO "subdivision_WS" ("id", "name", "level") VALUES ('WS... |
create procedure [CommonSchemaTests].[test log4Private.SqlException column structure]
as
begin
create table CommonSchemaTests.expected
(
ExceptionId int not null
, UtcDate datetime not null
, SystemDate datetime not null
, ErrorContext nvarchar(512) not null
, ErrorNumber int not null
, ErrorSeverity int n... |
<filename>dbqueries/crawled_data_in_db.sql
SELECT cities.city_fullname, COUNT (*) FROM data INNER JOIN cities ON data.city = cities.city_shortname WHERE cities.crawled = TRUE AND data.source = 'c' GROUP BY cities.city_fullname |
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- =============================================
-- Author: <NAME>
-- Create date: 29/11/2019
-- Description: Update a matrix to set the Update flag. This flag indicates that this matrix has data.
-- Typically where multiple languages are represented in a single relea... |
create table maestro_materia(
id integer(10) unsigned not null primary key auto_increment,
maestro_id integer(10) unsigned not null,
FOREIGN KEY (maestro_id) REFERENCES maestros(id),
materia_id integer(10) unsigned not null,
FOREIGN KEY (materia_id) REFERENCES materias(id),
ciclo_id integer(10) unsigned not null... |
<filename>apex/f130/application/shared_components/files/js_ast_js.sql
prompt --application/shared_components/files/js_ast_js
begin
-- Manifest
-- APP STATIC FILES: 130
-- Manifest End
wwv_flow_api.component_begin (
p_version_yyyy_mm_dd=>'2021.10.15'
,p_release=>'21.2.2'
,p_default_workspace_id=>969097893618861... |
-- Copyright 2004-2019 H2 Group. Multiple-Licensed under the MPL 2.0,
-- and the EPL 1.0 (http://h2database.com/html/license.html).
-- Initial Developer: H2 Group
--
select length(null) en, length('This has 17 chars') e_17;
> EN E_17
> ---- ----
> null 17
> rows: 1
SELECT LEN(NULL);
> exception FUNCTION_NOT_FOUND_1... |
DELETE FROM `sys_objects_cmts` WHERE `ObjectName` = 'bx_videos' OR `ObjectName` = 'bx_videos_albums';
INSERT INTO `sys_objects_cmts` (`ObjectName`, `TableCmts`, `TableTrack`, `AllowTags`, `Nl2br`, `SecToEdit`, `PerView`, `IsRatable`, `ViewingThreshold`, `AnimationEffect`, `AnimationSpeed`, `IsOn`, `IsMood`, `RootS... |
-- add enum name to term table in old CLB for mappings
alter table term add column enum text;
update term set enum='I' where id=12000;
update term set enum='II' where id=12100;
update term set enum='III' where id=12200;
-- means
update term set enum='NATIVE' where id=5000;
update term set enum='INTRODUCED' where id=5... |
<filename>backend/resources/db/migration/common/R__metric_data_views.sql<gh_stars>10-100
create or replace view "metric-data-ext" as
select
point,
"app-id",
scope,
name,
"server-id",
"call-count",
"total-call-time",
"total-exclusive-time",
"min-call-time",
"max-call-time",
"sum-of-squares"
from "m... |
<gh_stars>100-1000
-- Licensed to the Apache Software Foundation (ASF) under one or more
-- contributor license agreements. See the NOTICE file distributed with
-- this work for additional information regarding copyright ownership.
-- The ASF licenses this file to You under the Apache License, Version 2.0
-- (the ... |
-- start_ignore
! gpconfig -c gp_vmem_limit_per_query -v '20MB' --skipvalidation
! gpconfig -c gp_vmem_protect_limit -v '60'
! gpconfig -c runaway_detector_activation_percent -v 0
! gpstop -rai;
-- end_ignore
|
<filename>db/characters/get_char_by_category.sql<gh_stars>10-100
SELECT * FROM characters
WHERE category ilike $1
ORDER BY char_id; |
-- @testpoint: round函数入参为空或者负数
drop table if exists tb;
create table tb (nem numeric);
insert into tb values ('');
insert into tb values (null);
insert into tb values (-9.56);
select round(nem) from tb;
drop table tb; |
<filename>db_alterations.sql
create table team_has_users(team_id int(10) not null, user_id int(10) not null, created_at timestamp, updated_at timestamp);
|
INSERT INTO cocktail_accessory (cocktail_id, accessory_category_id, pieces)
VALUES (
(SELECT id FROM cocktail WHERE cocktail.name = 'Gin & Tonic'),
(SELECT id FROM accessory_category WHERE accessory_category.name = 'Cucumber'),
2
);
|
ALTER TABLE patient ADD start_bmi varchar(20) AFTER start_bsa//
ALTER TABLE patient ADD bmi varchar(20) AFTER sa// |
-- phpMyAdmin SQL Dump
-- version 4.9.5
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: Jun 10, 2021 at 01:54 PM
-- Server version: 5.7.24
-- PHP Version: 7.4.1
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHA... |
<reponame>EugenJantshenko/E-commerce-.
INSERT INTO `manufacturer` (`manufacturer_name`) VALUES ('manufacturerId 1');
INSERT INTO `manufacturer` (`manufacturer_name`) VALUES ('manufacturerId 2');
INSERT INTO `manufacturer` (`manufacturer_name`) VALUES ('manufacturerId 3');
INSERT INTO `manufacturer` (`manufacturer_name`... |
--insert usuario
merge into usuario (nome_usuario, senha, nome) key (nome_usuario)
values ('luiz', '123', '<NAME>');
--insert example values
merge into entrada (horario, descricao, prioridade, id_usuario) key (horario)
values ('2014-10-14 08:00:00', 'Curso Spring MVC', 'I', 1);
merge into entrada (horario, ... |
IF NOT EXISTS (SELECT * FROM sys.schemas WHERE name = 'read')
BEGIN
EXEC('CREATE SCHEMA [read]')
END |
<filename>itunes.sql
-- database creation
drop database if exists itunes;
create database itunes;
use itunes;
-- table creation
create table song
(
Name varchar(64) not null,
Artist varchar(64) not null,
Kind varchar(64) not null, -- the audio file format
Total_Time int not null, -- the duration of... |
/*
Navicat Premium Data Transfer
Source Server : mysql-database
Source Server Type : MySQL
Source Server Version : 80024
Source Host : localhost:3306
Source Schema : zhihu_spider_db
Target Server Type : MySQL
Target Server Version : 80024
File Encoding : 65001
Date: ... |
-- file:alter_generic.sql ln:508 expect:true
ALTER TEXT SEARCH CONFIGURATION alt_ts_conf1 RENAME TO alt_ts_conf2
|
<reponame>lucascr91/mais
/*
Query para publicar a tabela.
Esse é o lugar para:
- modificar nomes, ordem e tipos de colunas
- dar join com outras tabelas
- criar colunas extras (e.g. logs, proporções, etc.)
Qualquer coluna definida aqui deve também existir em `table_config.yaml`.
# Além disso, sinta-se à... |
ALTER TABLE db_version CHANGE COLUMN required_7643_02_mangos_mangos_string required_7662_01_mangos_spell_chain bit;
DELETE FROM `spell_chain` WHERE spell_id IN (50288, 53191, 53194, 53195);
INSERT INTO `spell_chain` VALUES
(50288, 0, 50288, 1, 0),
(53191, 50288, 50288, 2, 0),
(53194, 53191, 50288, 3, 0),
(53195, 53194... |
CREATE EXTERNAL TABLE region (
r_regionkey INT,
r_name VARBINARY(15),
r_comment VARBINARY(250)
) AS COPY FROM '/local/hajiang/tpch/5/vertica/region.parquet' PARQUET; |
<filename>doc/ccmanage.sql
/*
Navicat MySQL Data Transfer
Source Server : localhost
Source Server Version : 50715
Source Host : localhost:3306
Source Database : ccmanage
Target Server Type : MYSQL
Target Server Version : 50715
File Encoding : 65001
Date: 2019-03-18 23:31:10
*/
SET... |
<reponame>cuba-platform/cuba-thesis
-- $Id$
-- Description:
create table SEC_TAB_HISTORY (
ID uuid,
CREATE_TS timestamp,
CREATED_BY varchar(50),
CREATOR_ID uuid,
CAPTION varchar(255),
URL varchar(4000),
primary key (ID)
);
alter table SEC_TAB_HISTORY add constraint FK_SEC_HISTORY_USER foreign key (C... |
-- Use this file to run an end to end test
------------------
-- Replace <USERNAME> with your current user
------------------
-- USE ROLE ACCOUNTADMIN;
-- GRANT ROLE ROLE_INGEST TO USER <USERNAME>;
-- GRANT ROLE ROLE_TRANSFORM TO USER <USERNAME>;
-- GRANT ROLE ROLE_REPORT TO USER <USERNAME>;
------------------
-- ... |
DROP TABLE hosts,disks,loadavg,memory,ioblocks,cpustats,swap,cputimes,ionets; |
<gh_stars>0
CREATE SEQUENCE cwf_workflowitem_seq;
CREATE SEQUENCE cwf_collectionrole_seq;
CREATE SEQUENCE cwf_workflowitemrole_seq;
CREATE SEQUENCE cwf_claimtask_seq;
CREATE SEQUENCE cwf_in_progress_user_seq;
CREATE SEQUENCE cwf_pooltask_seq;
CREATE TABLE cwf_workflowitem
(
workflowitem_id INTEGER PRIMARY KEY,
ite... |
<filename>datafiles/schemas/inno_b.sql
DROP TABLE IF EXISTS inno_b;
CREATE TABLE IF NOT EXISTS innodb_compact2 (
id INT AUTO_INCREMENT PRIMARY KEY,
username VARCHAR(100) NOT NULL,
userlastname VARCHAR(77) ,
email VARCHAR(100),
sex ENUM('Male', 'Female') NOT NULL,
interest ENUM('Male', 'Female',... |
<gh_stars>1-10
-- Based on the information in the below fits file
-- spAll-master.fits
create table catalogdb.sdssv_boss_spall (
programname text, -- format = '12a'
chunk text, -- format = '17a'
survey text, -- format = '7A'
platequality text, -- format = '4a'
platesn2 real, -- format = 'e'
... |
-- Kyaru
-- Author: liuxi, chjimmy
--------------------------------------------------------------
INSERT INTO LocalizedText (Language, Tag, Text)
VALUES
('zh_Hant_HK', 'LOC_AGENDA_PCR_KYARU_NAME',
'傲嬌的貓咪'
),
('zh_Hant_HK', 'LOC_AGENDA_PCR_KYARU_DESCRIPTION',
'喜歡幸福快樂的文明,討厭幸福度低的文明。'
),
('zh_Hant_HK', 'LOC_DIPLO_... |
<gh_stars>1-10
-- Any app on "Home" is always featured.
-- On category browse pages the top three apps with 16px icons are featured.
update download_sources set name = 'mkt-category-featured' where name = 'mkt-featured';
-- Add separate ones for /apps/.
insert into download_sources (name, type, created)
values ('m... |
<filename>siremis/modules/contact/mod.uninstall.sql
DROP TABLE IF EXISTS `contact`;
DROP TABLE IF EXISTS `contact_type`;
|
-- @testpoint: 创建行存表以及行存表Gin索引
drop table if exists table_t3;
create table table_t3(a int, b text);
DROP INDEX if exists gin_test;
create index cgin_test on table_t3 using gin(to_tsvector('ngram', b));
DROP INDEX if exists gin_test;
drop table if exists table_t3; |
<filename>database/web-innomedic.sql
# Host: localhost (Version 8.0.17)
# Date: 2020-07-02 10:33:47
# Generator: MySQL-Front 6.0 (Build 2.20)
#
# Structure for table "t_areas"
#
DROP TABLE IF EXISTS `t_areas`;
CREATE TABLE `t_areas` (
`Id` int(11) NOT NULL AUTO_INCREMENT,
`name` varchar(255) DEFAULT NULL,
`... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.9.0.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Jul 03, 2020 at 01:00 PM
-- Server version: 10.3.15-MariaDB
-- PHP Version: 7.3.6
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!... |
-- phpMyAdmin SQL Dump
-- version 4.5.1
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: 18 Okt 2017 pada 18.11
-- Versi Server: 10.1.13-MariaDB
-- PHP Version: 7.0.5
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT ... |
<reponame>krachi9/Todos
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Gép: 127.0.0.1
-- Létrehozás ideje: 2020. Jún 03. 12:27
-- Kiszolgáló verziója: 10.4.11-MariaDB
-- PHP verzió: 7.4.6
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @... |
<reponame>SkillsFundingAgency/DC-Alpha-EasyWrapperPaaS
-- =====================================================================================================
-- Cranked by hand
-- Date: 8TH JUNE 2017
-- Profile:
-- Rulebase Version: ILR NCS Validation, Version 1718.01
-- =============================================... |
<reponame>ahsteele/ahsteele-ysod<gh_stars>0
if not exists(select * from Sites where Sites.Name = 'StackOverflow')
insert into Sites(
Id,
TinyName,Name,LongName,
Url,ImageUrl,IconUrl,
DatabaseName,
Tagline,
TagCss,
ODataEndpoint) values
(1,
'so', 'StackOverflow', 'Stack Overflow',
'http://stac... |
SET NOCOUNT ON;
/* Create Database */
IF NOT EXISTS (select * from sys.sysdatabases as s where s.name = 'DBA')
BEGIN
CREATE DATABASE [DBA]
ON
( NAME = N'DBA', FILENAME = N'C:\MSSQL12.MSSQLSERVER\MSSQL\DATA\DBA.mdf' , SIZE = 512000KB , FILEGROWTH = 204800KB )
LOG ON
( NAME = N'DBA_log', FILENAME = N'C:\MSSQL12.M... |
# --- !Ups
ALTER TABLE transactions ADD COLUMN archived boolean NOT NULL DEFAULT(false);
# --- !Downs
ALTER TABLE transactions DROP COLUMN archived; |
<reponame>skrilladeville/admin<filename>database/dumps/patient_profiles.sql
CREATE TABLE `patient_profiles` (
`id` INTEGER(11) NOT NULL AUTO_INCREMENT,
`firstname` VARCHAR(255) COLLATE utf8_unicode_ci NOT NULL,
`lastname` VARCHAR(255) COLLATE utf8_unicode_ci NOT NULL,
`birthday` MEDIUMTEXT,
`home_phone` VARCH... |
USE [ANTERO]
GO
/****** Object: View [dw].[v_amos_kustannuskysely_tili] Script Date: 27.4.2020 18:43:51 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER VIEW [dw].[v_amos_kustannuskysely_tili] AS
SELECT
[Tilastovuosi] = f.vuosi
,[Koulutuksen järjestäjä] = d1.organisaatio_fi
,[Taso 0] = d... |
TRUNCATE TABLE KRIM_PHONE_TYP_T DROP STORAGE
/
INSERT INTO KRIM_PHONE_TYP_T (ACTV_IND,DISPLAY_SORT_CD,LAST_UPDT_DT,OBJ_ID,PHONE_TYP_CD,PHONE_TYP_NM,VER_NBR)
VALUES ('Y','b',TO_DATE( '20081113140635', 'YYYYMMDDHH24MISS' ),'5B97C50B03906110E0404F8189D85213','HM','Home',1)
/
INSERT INTO KRIM_PHONE_TYP_T (ACTV_IND,DISPLA... |
/****** Object: StoredProcedure [dbo].[sp_iMart_Transform_dim_Date] Script Date: 4:40:40 PM ******/
CREATE procedure [dbo].[sp_iMart_Transform_dim_Date]
(
@BeginDate date = '2001-08-01',
@nbrYears int = 1
)
as
-- ============================================================================
-- Script UTC date: 20... |
<filename>components/automate-workflow-server/schema/verify/oauth_user_aliases.sql<gh_stars>100-1000
-- Verify delivery:user_oauth_aliases on pg
BEGIN;
SELECT user_id,
oauth_app_id,
alias
FROM oauth_user_aliases
WHERE FALSE;
SELECT id,
enterprise_id,
name,
ssh_pub_key,
first... |
<gh_stars>0
/*
Navicat MySQL Data Transfer
Source Server : wqcms
Source Server Version : 50554
Source Host : 192.168.127.12:3306
Source Database : wqcms
Target Server Type : MYSQL
Target Server Version : 50554
File Encoding : 65001
Date: 2017-07-24 15:41:55
*/
SET FOREIGN_KEY_CHEC... |
<gh_stars>1-10
DELETE from dbo.tb_Person where name = 'some name'
SELECT t.Name
,t.Age
FROM tb_Account t
left join tb_Balance b
ON t.AccountID = b.AccountID
WHERE t.Name = 'Person with no Name'
AND b.Balance > 0
SELECT t.Name
,Age
FROM tb_Account t
inner join tb_AccountInfo a
ON t.AccountID... |
DROP VIEW IF EXISTS view_persediaan_barang4_bppkp;
CREATE VIEW view_persediaan_barang4_bppkp AS
SELECT
*,
saldo * harga AS jumlah_harga
FROM
view_persediaan_barang3_bppkp
WHERE
1 = 1 AND
saldo > 0 AND
id_skpd = 15;
GRANT ALL PRIVILEGES ON view_persediaan_barang4_bppkp TO lap_bppkp;
REVOKE INSERT, UPDATE, DELETE... |
LOOP
-- some computations
EXIT WHEN count > 100;
CONTINUE WHEN count < 50;
-- some computations for count IN [50 .. 100]
END LOOP;
|
<gh_stars>0
/*
Navicat MySQL Data Transfer
Source Server : 127.0.0.1_3306
Source Server Version : 50553
Source Host : 127.0.0.1:3306
Source Database : shop
Target Server Type : MYSQL
Target Server Version : 50553
File Encoding : 65001
Date: 2018-08-18 14:57:53
*/
SET FOREIGN_KEY_C... |
select title
from book_catalogue
where publisher = ’McGraw Hill Education’ |
<filename>MS SQL - September 2019/02. Basic CRUD - Exercises/16.CreateViewEmployeesWithSalaries.sql
CREATE VIEW v_EmployeesSalaries AS
SELECT e.FirstName,
e.LastName,
e.Salary
FROM Employees AS e |
<reponame>djfrailey/zephyr
CREATE TABLE `users` (
`email_address` VARCHAR(255) NOT NULL,
`username` VARCHAR(255) NOT NULL,
`name` VARCHAR(255) NOT NULL,
PRIMARY KEY (`email_address`)
) ENGINE=InnoDB DEFAULT charset=utf8mb4 COLLATE=utf8mb4_unicode_ci;
CREATE TABLE `metrics` (
`email_address` VARCHAR... |
CREATE TABLE nicknames (
id INT UNSIGNED NOT NULL AUTO_INCREMENT,
user_id INT UNSIGNED NOT NULL,
discord_guild_id BIGINT NOT NULL,
name varchar(100) NOT NULL,
created_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
updated_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
deleted_at timestamp NULL DEFAULT... |
DEF title = 'SQL Using Literals or Many Children (GV$SQL GV$SQLAREA)';
DEF filename = 'SqlLiterals.html';
DEF nextpage = 'SqlPlanBaselines.html';
DEF prevpage = 'BlockingSql.html';
@@00_begin.sql
PRO
PRO
SET MARK HTML OFF;
PRO <h2>SQL using literals or many children:</h2>
SET MARK HTML ON TABLE "class=sort... |
<reponame>VaclavElias/Emsi
CREATE TABLE [Skills] (
[Id] TEXT NOT NULL
, [InfoUrl] TEXT NOT NULL
, [Name] TEXT NOT NULL
, [RemovedDescription] TEXT NULL
, CONSTRAINT [PK_Skill] PRIMARY KEY ([Id])
);
CREATE TABLE [Metas] (
[LatestVersion] text NOT NULL
, CONSTRAINT [sqlite_autoindex_Metas_1] PRIMARY KEY ([LatestVers... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 5.0.1
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Feb 20, 2020 at 05:49 AM
-- Server version: 10.4.11-MariaDB
-- PHP Version: 7.4.1
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40... |
SELECT
*
FROM
projects
ORDER BY start_date , name
LIMIT 10; |
SELECT a_int FROM types_i WHERE a_int = 1
|
<filename>HealthCheck/MonitorAGReplicaRoles.sql
------------------------------
-- Monitor AG Replica Roles
-- Author: MLavery
-- Date: 18/06/2018
--
-- When Who What
-- 2018-07-04 MLavery Added NOCOUNT
--
------------------------------
SET NOCOUNT ON;
-- 1. Monitor Replica Roles of the AG
-- Alternati... |
<filename>Database Basics/MSSQL Server Exam - 24 April 2017/MSSQL Server Exam - 24 April 2017/20. Vendor Preference.sql
WITH CTE_PartsByMechanicAndVendor(MechanicId, [Mechanic Full Name], [Vendor], [Parts])
AS(
SELECT m.MechanicId,
m.FirstName + ' ' + m.LastName AS [Mechanic Full Name],
v.Name AS [Vendor]... |
UPDATE oppdrag
SET status = 'AKSEPTERT'
WHERE fagsystem_id = 'POMGJZFCQFGZVLG2O5SCLDVPIQ'
AND avstemmingsnokkel = '1618823296742431266'; |
<filename>src/main/resources/oracle/V1__init.sql<gh_stars>1-10
CREATE TABLE books (
id NUMBER GENERATED by default on null as IDENTITY,
name varchar(255),
author varchar(255)
); |
USE hyperparameter;
ALTER TABLE Algorithm
ADD INDEX ind_Algorithm(Algorithm_ID);
ALTER TABLE Dataset
ADD INDEX ind_Dataset(Dataset_ID);
ALTER TABLE DataSet_Description
ADD INDEX ind_DataSet_Description(Column_ID);
ALTER TABLE DRF_Hyperparameters
ADD INDEX ind_DRF_Hyperparameters(Model_name);
ALTER... |
SELECT "MLB_65"."league" AS "league" FROM "MLB_65" GROUP BY "MLB_65"."league" ORDER BY "league" ASC ;
|
<filename>plugins/git/db/uninstall.sql<gh_stars>1-10
DROP TABLE IF EXISTS plugin_git_post_receive_mail;
DROP TABLE IF EXISTS plugin_git_post_receive_notification_user;
DROP TABLE IF EXISTS plugin_git_post_receive_notification_ugroup;
DROP TABLE IF EXISTS plugin_git_log;
DROP TABLE IF EXISTS plugin_git_ci;
DROP TABLE IF... |
-- file:brin.sql ln:322 expect:false
IF NOT plan_ok THEN
RAISE WARNING 'did not get bitmap indexscan plan for %', r
|
<filename>php/zavod.sql
CREATE or replace TABLE typ_zavodu (
id smallint NOT NULL AUTO_INCREMENT,
nazev varchar(32) not null,
vaha decimal(4,2) not null default 1,
comment varchar(100),
typ smallint COMMENT '#1=mistrovsky, 2=nemistrovsky, 3=druzstva, 9=turnajpripravek',
sortorder smallint default 9,
PRIMARY KEY ... |
<gh_stars>0
-- Remove all boxes with a value lower than $100.
delete from boxes where value < 100;
select * from boxes where value <100; |
<reponame>tharangar/k8s-webserver
-- POCOR-3068
-- code here
INSERT INTO `security_functions` (`id`, `name`, `controller`, `module`, `category`, `parent_id`, `_view`, `_edit`, `_add`, `_delete`, `_execute`, `order`, `visible`, `modified_user_id`, `modified`, `created_user_id`, `created`) VALUES ('5032', 'Backup', 'Data... |
USE ${keyspace};
CREATE TABLE IF NOT EXISTS ${table} (
blobid blob,
group ascii,
chunkid int,
data blob,
PRIMARY KEY (blobid, group, chunkid)
) WITH COMPACT STORAGE
AND compression = {'sstable_compression' : 'LZ4Compressor'}; |
ALTER TABLE {$NAMESPACE}_pholio.pholio_image
ADD UNIQUE KEY `keyPHID` (`phid`);
|
set define off;
@@xlib/XLIB_UTL_PCK.pks
show errors;
@@xlib/XLIB_UTL_PCK.pkb
show errors;
@@xlib/xlib_log_install.sql
@@xlib/xlib_conf_install.sql
@@xlib/xlib_sec_install.sql
@@xlib/XLIB_HTTP_PCK.pks
show errors;
@@xlib/XLIB_HTTP_PCK.pkb
show errors;
@@xlib/XLIB_CONTEXT_PCK.pks
show errors;
@@xlib... |
-- @testpoint:opengauss关键字duplicate(非保留),作为序列名
--关键字不带引号-成功
drop sequence if exists duplicate;
create sequence duplicate start 100 cache 50;
drop sequence duplicate;
--关键字带双引号-成功
drop sequence if exists "duplicate";
create sequence "duplicate" start 100 cache 50;
drop sequence "duplicate";
--关键字带单引号-合理报错
drop sequ... |
-- ----------------------------
-- Table structure for td_admin
-- ----------------------------
CREATE TABLE IF NOT EXISTS `td_admin` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'ID',
`rid` int(11) NOT NULL DEFAULT '0' COMMENT '角色ID',
`mobile` char(11) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '' COMMENT '手机... |
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Nov 05, 2020 at 03:16 PM
-- Server version: 10.4.14-MariaDB
-- PHP Version: 7.4.10
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIE... |
<reponame>nagasudhirpulla/wrldc_codebook<filename>sqls/checkIfElementIsOut.sql
SELECT
rto.REVIVED_DATE
FROM
REPORTING_WEB_UI_UAT.REAL_TIME_OUTAGE rto
WHERE
to_char(rto.OUTAGE_DATE , 'YYYY-MM-DD')|| ' ' || rto.OUTAGE_TIME = (
SELECT
MAX(to_char(OUTAGE_DATE , 'YYYY-MM-DD')|| ' ' || OUTAGE_TIME) AS out_date_time
F... |
-- =============================================
-- Author: dbo
-- Create date: 2020-10-13
-- Description: adding new user to user table, Auth system
-- =============================================
CREATE PROCEDURE [dbo].[spUsers_AddUser_Auth]
@UserId nvarchar(128)
,@UserName nvarchar(256)
,@Email nvarchar (256... |
/**
mysql --user bl -p < ~/beehive.dev/src/Papyrillio/BeehiveBundle/Resources/data/loadProdIntoDev.sql
**/
TRUNCATE TABLE `bl_dev`.`correction_register`;
TRUNCATE TABLE `bl_dev`.`register`;
TRUNCATE TABLE `bl_dev`.`task`;
TRUNCATE TABLE `bl_dev`.`index_entry`;
TRUNCATE TABLE `bl_dev`.`ext_translations`;
TRUNCATE TAB... |
<reponame>DamyGenius/risk
prompt Importing table t_migraciones...
set feedback off
set define off
insert into t_migraciones (ID_MIGRACION, DESCRIPCION)
values ('mig_000014', 'Registrar usuario sin correo electrónico.');
prompt Done.
|
/*
Navicat MySQL Data Transfer
Source Server : localhost_3306
Source Server Version : 50505
Source Host : localhost:3306
Source Database : endogasin
Target Server Type : MYSQL
Target Server Version : 50505
File Encoding : 65001
Date: 2020-04-26 14:40:23
*/
SET FOREIGN_KEY_CHECKS=0... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 2.10.0-beta1
-- http://www.phpmyadmin.net
--
-- Serveur: localhost
-- Généré le : Mercredi 30 Mai 2007 à 22:05
-- Version du serveur: 5.0.33
-- Version de PHP: 5.2.1
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
--
-- Base de données: `stargate`
--
-- ------------------------... |
IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_WebSites_Published]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[WebSite] DROP CONSTRAINT [DF_WebSites_Published]
END
GO
IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_WebSites_VersionOfId]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].... |
<filename>Snipets/Queries/UNIFI/GetContentItemDetailsFromLast28Days.sql
SELECT CON_ITEM.ITEMID,
CON_ITEM.ITEMDATAID,
CON_ITEM.ISSUBITEM,
CON_ITEM.ITEMROOTID,
CON_ITEM.VERSIONNO,
CON_ITEM.ISLASTVERSION,
CON_ITEM.DATANODEID,
CON_ITEM.ITEMTYPEID,
Con_Itemtype.NAME,
CON_ITEM.COMMONNAME,
CON_ITEM.COMMONS... |
<gh_stars>1-10
CREATE TABLE AKTOER_ID_TO_VEILEDER (
AKTOERID VARCHAR(20) NOT NULL,
VEILEDER VARCHAR(20) NOT NULL,
PRIMARY KEY (aktoerId)
); |
USE [Koski_SA]
GO
/****** Object: StoredProcedure [sa].[p_lataa_tutkinnot_ja_tutkinnonosat_aikajaksot] Script Date: 23.10.2019 17:56:16 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[sa].[p_lataa_tutkinnot_ja_tutkinnonosat_aikajaksot]... |
<filename>db/schema.sql<gh_stars>1-10
DROP DATABASE IF EXISTS jointeffort_db;
CREATE DATABASE jointeffort_db; |
-- Setting is_current to false for older Filing Actions
UPDATE opencivicdata_filingaction
SET is_current = false,
updated_at = now()
FROM opencivicdata_filingaction fa
-- get latest amend_id for each filing
LEFT JOIN (
SELECT filing_id, MAX((extras->>'amend_id')::int) as amend_id
FROM opencivicdata_fili... |
-- depends: 0001.create-public.media_metadata_staging
CREATE INDEX IF NOT EXISTS media_hash_code_index ON public.media_metadata_staging USING btree (media_hash_code);
|
CREATE TABLE favorites (
"user" INTEGER REFERENCES users ON DELETE CASCADE,
article INTEGER REFERENCES articles ON DELETE CASCADE,
PRIMARY KEY ("user", article)
);
|
<reponame>VladimirKryat/BooksWorld
ALTER TABLE IF EXISTS book
ADD COLUMN filename varchar(255) NOT NULL DEFAULT('default.jpg'); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.