sql stringlengths 6 1.05M |
|---|
<gh_stars>0
CREATE TABLE IF NOT EXISTS public.toothsi_patient_oneview_drive_s3
(
id uuid NOT NULL DEFAULT uuid_generate_v4(),
category toothsi_patient_oneview_drive_s3_category_enum NOT NULL,
"subCategory" toothsi_patient_oneview_drive_s3_subcategory_enum NOT NULL,
category_id character varying COLLATE ... |
INSERT INTO `states` (`id`, `name`) VALUES
(1, 'ANDAMAN AND NICOBAR ISLANDS'),
(2, 'ANDHRA PRADESH'),
(3, 'ARUNACHAL PRADESH'),
(4, 'ASSAM'),
(5, 'BIHAR'),
(6, 'CHATTISGARH'),
(7, 'CHANDIGARH'),
(8, '<NAME>'),
(9, 'DELHI'),
(10, 'DADRA AND <NAME>'),
(11, 'GOA'),
(12, 'GUJARAT'),
(13, 'HIMACHAL PRADESH'),
(14, 'HARYANA'... |
-- phpMyAdmin SQL Dump
-- version 5.0.4
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Sep 04, 2021 at 07:24 AM
-- Server version: 10.4.17-MariaDB
-- PHP Version: 7.4.13
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIE... |
<reponame>sometao/littleGift<gh_stars>0
CREATE TABLE IF NOT EXISTS slides(
id INTEGER PRIMARY KEY AUTOINCREMENT,
author_name VARCHAR(64),
content TEXT NOT NULL,
content_type VARCHAR(64),
access_token VARCHAR(128) NOT NULL,
edit_code VARCHAR(128) NOT NULL,
create_time INTEGER NOT N... |
<filename>api/src/sql/user/select_user.sql
SELECT
*
FROM
archfolio.users
WHERE
(cast(:id AS INT) IS NULL OR id = :id)
AND
(
(cast(:identification AS TEXT) IS NULL OR username = :identification)
OR
(cast(:identification AS TEXT) IS NULL OR email = :identification)
)
ORDER ... |
SELECT * FROM "+w+' WHERE url="'+g+'" and '+(/html/.test(w)?"xpath":"itemPath")+"='"+(o.yql.xpath||"/")+"'";w=="html"&&(nt+=" and compat='html5'"),a=n.extend({url:r()+"query.yahooapis.com/v1/public/yql",dataType:"jsonp",data:{q:nt,format:"json",env:"store://datatables.org/alltableswithkeys",callback:"?"},success:functi... |
<reponame>tushartushar/dbSmellsData<filename>data/open-source/extracted_sql/mbilbille_jpnforphp.sql
SELECT * FROM verbs WHERE kanji = :kanji OR kana = :kana';
CREATE INDEX verbs_kana_idx ON verbs (kana);
CREATE INDEX verbs_kana_idx ON verbs (kana)M+gindexverbs_kanji_idxverbs
CREATE TABLE IF NOT EXISTS verbs ( id ... |
insert into company values ('1234','1234','1234','1234','1234','1234','8148f9b39472a6c94db8416e96b36a72'); |
<filename>User_Defined_Function/udf_CalcWorkingHours.sql<gh_stars>1-10
/*
Programmer: <NAME>
Date: 2014-05-22
Purpose: This function will return working hours between given 2 dates.
This function assumes that the break is between 9:45 AM and 10 AM and that Lunch is between 12:30 PM and 1 PM.
This function also a... |
create index if not exists ad_pinstance_log_ad_pinstance_id_p_date on ad_pinstance_log (ad_pinstance_id, p_date);
comment on index ad_pinstance_log_ad_pinstance_id_p_date is 'helps to speed up displaying the logs of one AD_PInstance in their chronological order';
create index if not exists ad_pinstance_para_perf on ad... |
CREATE DATABASE warehouse_db;
|
ALTER TABLE tokenaccount DROP COLUMN connector;
ALTER TABLE tokentransfer DROP COLUMN connector;
|
version https://git-lfs.github.com/spec/v1
oid sha256:d24e232185b02d22d1df1bd34e1cb0dacb6e13eaa11c9ff7454ca62f18a0e22d
size 3891
|
<gh_stars>1-10
/*
Navicat Premium Data Transfer
Source Server : mysql-local
Source Server Type : MySQL
Source Server Version : 50730
Source Host : localhost:3306
Source Schema : hawthorn
Target Server Type : MySQL
Target Server Version : 50730
File Encoding : 65001
D... |
BEGIN;
ALTER TABLE builds DROP COLUMN drained;
COMMIT;
|
<filename>src/test/resources/jp/co/tis/gsp/tools/dba/mojo/GenerateDdlMojo_test/ddlTemplateFileDir/sqlserver/expected/ddl/40_CREATE_VIEW1.sql<gh_stars>10-100
CREATE OR REPLACE VIEW VIEW1_TEST AS
SELECT
TEST1.TEST_NAME TEST_TBL1_NAME
FROM TEST_TBL1 TEST1
|
<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
-... |
<filename>tests/test_printers_roundtrip/ddl/do.sql
DO $$
some_code
$$ language somelanguage
|
<filename>src/test/tinc/tincrepo/dml/functional/sql/joins_heap_update_6.sql
-- @author prabhd
-- @created 2012-12-05 12:00:00
-- @modified 2012-12-05 12:00:00
-- @tags dml
-- @db_name dmldb
-- @execute_all_plans True
-- @description update_test6: Update and generate_series
\echo --start_ignore
set gp_enable_column_... |
<gh_stars>10-100
drop table ipcr;
drop table patent_assignee;
drop table patent_inventor;
drop table patent_lawyer;
drop table location_assignee;
drop table location_inventor;
drop table rawassignee;
drop table rawinventor;
drop table rawlawyer;
drop table rawlocation;
drop table application;
drop table assignee;
drop ... |
<reponame>alex-myzhao/FE-6083
INSERT INTO User (uemail, uname, nickname, password) VALUES
('<EMAIL>', '<NAME>', 'Alex', '123891828'),
('<EMAIL>', 'hangbo', 'hangbo', '12345678'),
('<EMAIL>', 'lee', 'lee', '12345678'),
('<EMAIL>', 'mingyu', 'mingyu', '12345678'),
('<EMAIL>', 'newuser', 'mu', '12345678'),
('<EMAIL>', '<... |
CREATE TABLE Player (
ID TEXT NOT NULL PRIMARY KEY,
UserName TEXT NOT NULL
);
CREATE TABLE Game (
ID TEXT NOT NULL PRIMARY KEY,
ReplayFileName TEXT NOT NULL,
OrangeScore INT NOT NULL,
BlueScore INT NOT NULL,
MatchLengthSeconds REAL NOT NULL,
MatchDate TIMESTAMP NOT NULL
);
CREATE TABLE... |
--check password
create trigger check_pw on User
for insert, update
as
if(( select len(password_user) from inserted ) < 8)
begin
print 'password phai chua it nhat 7 ky tu'
rollback tran
go
--check lich_su_nghe tối đa (lịch sử nghe lưu đối đa 50 bài hát)
create trigger check_ls_nghe on LichSuNghe
for insert
as
if ((se... |
<gh_stars>0
CREATE TABLE users (
id VARCHAR(36) CONSTRAINT user_id_pkey PRIMARY KEY,
name VARCHAR (128) NOT NULL,
email VARCHAR (128) NOT NULL UNIQUE,
password VARCHAR (128) NOT NULL,
created TIMESTAMP WITH TIME ZONE
);
CREATE TABLE task (
id VARCHAR(36) CONSTRAINT task_id_pkey PRIMARY KEY,
... |
-- phpMyAdmin SQL Dump
-- version 4.7.9
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: May 31, 2018 at 12:01 PM
-- Server version: 10.1.31-MariaDB
-- PHP Version: 5.6.34
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OL... |
<filename>database_migrations/posgresql/2_infb_create_authors_table.sql
CREATE TABLE infb.authors(
id SERIAL PRIMARY KEY,
fullname VARCHAR(255)
);
|
SELECT
id AS t_id,
nummer,
"name",
bedeutung,
CASE
WHEN bedeutung = 'national'
THEN 'Wildtierkorridor von nationaler Bedeutung'
WHEN bedeutung = 'regional'
THEN 'Wildtierkorridor von regionaler Bedeutung'
END AS bedeutung_txt,
abstimmung,
ST_Multi(... |
<gh_stars>1-10
USE [master]
GO
/****** Object: Database [DynThings_1_2_0] Script Date: 2017-09-22 12:35:17 PM ******/
--Database Name: <DataBase_Name, varChar(50) DynThingsDB>
ALTER DATABASE [<DataBase_Name, varChar(50), DynThingsDB>] SET COMPATIBILITY_LEVEL = 120
GO
IF (1 = FULLTEXTSERVICEPROPERTY('IsFullText... |
DROP TABLE IF EXISTS `XXX_bildwechsler`; ##b_dump##
DROP TABLE IF EXISTS `XXX_bildwechsler_config`; ##b_dump##
|
<gh_stars>1-10
CREATE PROCEDURE SP_Clinicas_Eliminar
@idClinica INT,
@ModificadoPor VARCHAR(60)
AS
BEGIN
UPDATE clinicas
SET
Activo = 0,
ModificadoPor = @ModificadoPor,
FechaModificacion = GETDATE()
WHERE
IdClinica = @idClinica
END |
<reponame>jonlabelle/HealthCheck
/********************************************************************
Filename: MissingIndexesForeignKeys.sql
Author: <NAME>
Date: 09/09/15
Comments: Returns FKs on unindexed columns. Deletes on the
the referenced tables will result in scans on the
... |
ALTER TABLE `users` ADD `forceremember` bit(1) NULL DEFAULT NULL; |
-- file:limit.sql ln:40 expect:true
begin
|
<reponame>cxc6922/onlinelearning
drop function if exists `get_categories_parent_list`;
#create function parent
delimiter ;;
create function `get_categories_parent_list`(curId int)
returns varchar(1000)
begin
declare stemp varchar(1000);
declare stempparent varchar(1000);
set stemp = "0";
set stempparent... |
<reponame>wvanheemstra/core
/*
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
*/
SET NAMES utf8;
SET FOREIGN_KEY_CHECKS = 0;
-- ---... |
<gh_stars>0
/*
Navicat Premium Data Transfer
Source Server : local
Source Server Type : MySQL
Source Server Version : 50732
Source Host : localhost:3306
Source Schema : srs
Target Server Type : MySQL
Target Server Version : 50732
File Encoding : 65001
Date: 01/01/202... |
-- #CommonColumnMember#
select member.MEMBER_ID
, member.MEMBER_NAME
, member.REGISTER_DATETIME
, member.REGISTER_USER
, member.REGISTER_PROCESS
, member.UPDATE_DATETIME
, member.UPDATE_USER
, member.UPDATE_PROCESS
from MEMBER member
order by member.MEMBER_ID asc
|
<reponame>mtti/migrator
CREATE ROLE tester WITH LOGIN PASSWORD 'password';
CREATE DATABASE node_migrator_test WITH OWNER = tester;
|
CREATE TABLE IF NOT EXISTS Submissions
(
ID IDENTITY,
User VARCHAR(50),
Name VARCHAR(50),
Timestamp TIMESTAMP DEFAULT NOW(),
Test BOOLEAN,
Submitted BOOLEAN DEFAULT FALSE,
Completed BOOLEAN DEFAULT FALSE,
Input VARCHAR(255),
-- Hadoop jobs only
Hadoop_ID VARCHAR(50)... |
<reponame>cuba-platform/cuba-thesis
-- $Id$ --
-- Add linking columns from SendingMessage and SendingAttachment to sys$File
alter table SYS_SENDING_MESSAGE add column CONTENT_TEXT_FILE_ID uuid;
alter table SYS_SENDING_MESSAGE ADD constraint FK_SYS_SENDING_MESSAGE_CONTENT_FILE
foreign key (CONTENT_TEXT_FILE_ID) re... |
<gh_stars>1-10
-- Deploy test_helpers:create_applications to pg
-- requires: schema_test_helper
-- Function creates a defined number of applications.
-- If create_dependencies is set to True, this function will create the necessary organisations and facilities as well.
begin;
create or replace function test_helper.... |
<filename>hasura/migrations/1614110629223_run_sql_migration/up.sql<gh_stars>1-10
CREATE TYPE public.temp_t_full_stats_for_each as (
zone character varying,
total_txs integer,
total_ibc_txs integer,
ibc_percent numeric,
ibc_tx_out integer,
ibc_tx_in integer,
channels_num integer,
chart js... |
<gh_stars>100-1000
insert into Customer (id, email, firstname, lastname, reg_date) values (1, '<EMAIL>', 'Dave', 'One', DATE '2011-04-03');
insert into Customer (id, email, firstname, lastname, reg_date) values (2, '<EMAIL>', 'Carter', 'Two', DATE '2012-04-03');
insert into Customer (id, email, firstname, lastname, reg... |
-- RDKit cartridge tests.
SELECT
*
FROM
scaffold
WHERE
scafsmi='N1CCCCC1'::mol::VARCHAR
;
--
|
<filename>test.sql
# ************************************************************
# Sequel Pro SQL dump
# Version 4499
#
# http://www.sequelpro.com/
# https://github.com/sequelpro/sequelpro
#
# Host: 192.168.10.10 (MySQL 5.6.19-0ubuntu0.14.04.1)
# Database: homestead
# Generation Time: 2015-11-24 14:48:14 +0000
# *****... |
select hackers.hacker_id,hackers.name,count(*) as c
from hackers
inner join challenges on hackers.hacker_id = challenges.hacker_id
group by hackers.hacker_id,hackers.name
having
-- selecting only max
c = (select count(*)
from challenges
group by challenges.hacker_id
order by count(*) desc
limit 1 )
or
-- selet... |
<gh_stars>0
SET FOREIGN_KEY_CHECKS = 0;
DROP TABLE IF EXISTS Users;
DROP TABLE IF EXISTS History;
DROP TABLE IF EXISTS CITIES;
SET FOREIGN_KEY_CHECKS = 1;
CREATE TABLE Users (
userId int NOT NULL PRIMARY KEY AUTO_INCREMENT,
emailAddress VARCHAR(255) UNIQUE,
password VARCHAR (255),
firstname VARCHAR (255),
lastname... |
#
# @package hubzero-cms
# @copyright Copyright 2005-2019 HUBzero Foundation, LLC.
# @license http://opensource.org/licenses/MIT MIT
#
#
# Last Migration Applied: Migration20140925213032ComTools.php
#
SET NAMES 'utf8';
SET @@SESSION.sql_mode = '';
CREATE TABLE `app` (
`appname` varchar(80) NOT NULL DE... |
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
-- ------------------------------------------------... |
<filename>fetch_users.sql
SELECT * FROM Users; |
update eg_action set ordernumber=5 where name='Search BudgetUploadReport'; |
<reponame>JinodkDevTeam/PickaxeLevel<filename>resources/sqlite.sql
-- #! sqlite
-- #{ pickaxelevel
-- # { init
CREATE TABLE IF NOT EXISTS PickaxeLevel
(
Player VARCHAR(40) NOT NULL,
Level INTEGER NOT NULL DEFAULT 0,
Exp INTEGER NOT NULL DEFAULT 0
);
-- # }
-- # { register
-- # :p... |
INSERT INTO custom_fields (type, name, field_format, searchable, is_filter, is_for_all) VALUES
('UserCustomField', 'external_system_id', 'string', true, true, false),
('ProjectCustomField', 'external_system_id', 'string', true, true, false),
('IssueCustomField', 'external_system_id', 'string', true, true, tr... |
<reponame>dMundov/SoftUni-HomeWorks
SELECT DepartmentID,
MAX(Salary) AS [MaxSalary]
FROM Employees
GROUP BY DepartmentID
HAVING MAX(Salary) NOT BETWEEN 30000 AND 70000 |
<reponame>G-Simeone/Learning_Tuscany_Tourism_Flows<filename>db/ETL/ETL_03_location_number.sql<gh_stars>1-10
--- Database: Redshift
--- Schema: Tuscany
--- Table: Location Mapping
--- location_mapping: This table maps Location IDs to decimal numbers from 1 to N
--- to save space when loading into Python dataframe
... |
-- file:rolenames.sql ln:339 expect:true
DROP USER MAPPING FOR CURRENT_USER SERVER sv1
|
-- Check what data do we have in customer_survey
SELECT * FROM customer_survey limit 5;
-- Array transformation
SELECT UNNEST(STRING_TO_ARRAY(feedback, ' ')) AS word, rating FROM customer_survey limit 10;
-- Standardize the text using the ts_lexize function and using the English stemmer 'english_stem'. We will then... |
/* ================================================
* Oracle XFiles Demonstration.
*
* Copyright (c) 2014 Oracle and/or its affiliates. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"... |
CREATE DATABASE CMPE283;
USE CMPE283;
CREATE TABLE users (
username VARCHAR(45) NOT NULL ,
fname varchar(30) NOT NULL DEFAULT '',
lname varchar(30) NOT NULL DEFAULT '',
email varchar(30) NOT NULL DEFAULT '',
password VARCHAR(60) NOT NULL ,
enabled TINYINT NOT NULL DEFAULT 1 ,
created datetime NOT NULL ... |
<reponame>koyach/dalite
SELECT * FROM question natural join assignment_question
where assignment_ = :assignment
order by assignment_question.`order`
|
create database my_budget_db;
create user 'mybudget'@'%' identified by 'test_password';
grant all on my_budget_db.* to 'mybudget'@'%'; |
CREATE DATABASE plan2dance;
|
insert into certificates (certificate, name, region, request, comments, created_by, org, status, updated, created) values ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10) returning * |
<gh_stars>10-100
SET search_path TO shogun_rev, public;
alter table shogun_rev.applications_rev add column if not exists created_mod bool;
alter table shogun_rev.applications_rev add column if not exists modified_mod bool;
alter table shogun_rev.applications_rev add column if not exists client_config_mod bool;
alter t... |
<reponame>harverywxu/erda<filename>.erda/migrations/cmdb/20211222-dice-member-character.sql
alter table `dice_member` convert to character set utf8mb4 COLLATE utf8mb4_general_ci; |
drop table if exists t_comment;
create table t_comment(id int, b int) comment='basic comments testing';
insert into t_comment values(1,2),(2,3),(3,4);
select id, b from t_comment order by id;
show create table t_comment;
select class_name, comment from db_class where class_name='t_comment';
select class_name, comment ... |
<gh_stars>0
-- +migrate Up
CREATE extension IF NOT EXISTS "uuid-ossp";
-- +migrate Up
CREATE TABLE IF NOT EXISTS projects_data(
created_at timestamp NOT NULL DEFAULT NOW() PRIMARY KEY,
viewer_id uuid NOT NULL,
data jsonb
);
-- +migrate Up
CREATE INDEX ON projects_data (created_at DESC, viewer_id); |
<reponame>saturn72/data-structure<filename>src/Applications/admin/glue-backend/prisma/migrations/20220425184217_init/migration.sql
-- CreateTable
CREATE TABLE `MessageBus` (
`id` VARCHAR(191) NOT NULL,
`comment` VARCHAR(191) NULL,
`createdAt` DATETIME(3) NOT NULL DEFAULT CURRENT_TIMESTAMP(3),
`name` VAR... |
<gh_stars>0
CREATE TABLE accessory
(
id integer DEFAULT nextval('accessory_id_seq'::regclass) PRIMARY KEY NOT NULL,
name varchar(255) NOT NULL,
description varchar(512),
image_link varchar(512),
category_id integer NOT NULL -- accessory_category
);
CREATE UNIQUE INDEX accessory_id_uindex ON accessor... |
create table:(id integer, name TEXT, breed TEXT); |
CREATE TABLE BibleDownload(
requestid TEXT PRIMARY KEY,
bucket TEXT NOT NULL,
datetime DATETIME NOT NULL,
userid TEXT NOT NULL,
operation TEXT NOT NULL,
filename TEXT NOT NULL,
httpStatus TEXT NOT NULL,
prefLocale TEXT NULL,
locale TEXT NULL,
error TEXT NULL,
tranSize TEXT NOT NULL,
fileSize TEXT NOT NULL... |
-- +goose Up
ALTER TABLE `users` ADD COLUMN `org_id` BIGINT REFERENCES organizations(id);
ALTER TABLE `imap` ADD COLUMN `org_id` BIGINT;
ALTER TABLE `campaigns` ADD COLUMN `org_id` BIGINT;
ALTER TABLE `pages` ADD COLUMN `org_id` BIGINT;
ALTER TABLE `results` ADD COLUMN `org_id` BIGINT;
ALTER TABLE `smtp` ADD COLUMN `or... |
<reponame>apostoldevel/db-platform
--------------------------------------------------------------------------------
-- VIEW VerificationCode -------------------------------------------------------
--------------------------------------------------------------------------------
CREATE OR REPLACE VIEW VerificationCode
A... |
-- Table: public.messages
-- DROP TABLE public.messages;
CREATE SEQUENCE public.messages_id_seq;
ALTER SEQUENCE public.messages_id_seq
OWNER to postgres;
CREATE TABLE public.messages
(
device_time bigint,
mosca_time bigint,
socket_time bigint,
mongo_time bigint,
total_messages integer,
... |
/*
Navicat Premium Data Transfer
Source Server : localhost_3306
Source Server Type : MySQL
Source Server Version : 100406
Source Host : localhost:3306
Source Schema : testlar
Target Server Type : MySQL
Target Server Version : 100406
File Encoding : 65001
Date: 17/10/... |
<reponame>adrcesar/proffy
-- SEQUENCE: public.classes_id_seq
-- DROP SEQUENCE public.classes_id_seq;
CREATE SEQUENCE public.classes_id_seq
INCREMENT 1
START 1
MINVALUE 1
MAXVALUE 9223372036854775807
CACHE 1;
ALTER SEQUENCE public.classes_id_seq
OWNER TO postgres; |
<reponame>Justarone/bmstu-db
-- Инструкция SELECT, использующая предикат IN с вложенным подзапросом.
-- Вывод хоккеистов, кто хоть раз забивал более 3 за матч
SELECT firstName, lastName, nationality
FROM player_info
WHERE player_id IN (
SELECT DISTINCT player_id
FROM game_skaters_stats
WHERE goals > 3
);
|
<filename>database/db-file/my_ecom.sql
-- phpMyAdmin SQL Dump
-- version 5.1.0
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Aug 16, 2021 at 06:39 AM
-- Server version: 10.4.18-MariaDB
-- PHP Version: 7.4.16
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";... |
/*
SQLyog Ultimate v13.1.1 (64 bit)
MySQL - 10.2.4-MariaDB : Database - open_platform_user
*********************************************************************
*/
/*!40101 SET NAMES utf8 */;
/*!40101 SET SQL_MODE=''*/;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KE... |
-- Connect to the 'Gringotts' database for execution of this query
USE [Gringotts]
GO
-- Select the deposit group and the largest wand size from the 'WizzardDeposits' table
SELECT [DepositGroup]
, MAX([MagicWandSize]) AS [LongestMagicWand]
FROM [WizzardDeposits]
-- Group by the deposit groups
GROUP BY [... |
<gh_stars>10-100
-- file:drop_if_exists.sql ln:217 expect:true
DROP OPERATOR CLASS test_operator_class USING btree
|
<gh_stars>10-100
-- file:select_views.sql ln:120 expect:true
SELECT * FROM my_credit_card_secure WHERE f_leak(cnum)
|
ALTER TABLE "#__contentitem_tag_map" DROP CONSTRAINT "#__uc_ItemnameTagid", ADD CONSTRAINT "#__uc_ItemnameTagid" UNIQUE ("type_id", "content_item_id", "tag_id");
|
ALTER TABLE cds.import_study ADD COLUMN study_specimen_repository VARCHAR(250);
ALTER TABLE cds.study ADD COLUMN specimen_repository_label VARCHAR(250); |
-- INSERT INTO user(id,enabled,login,password,roles) VALUES (1, 1, 'a', 'aa', 'USER');
-- INSERT INTO user VALUES (2, 1, 'b', 'bb', 'USER,ADMIN');
INSERT INTO User(id,enabled,login,password,roles,humildones,elo,email) VALUES (1, 1, 'a', '$2a$04$N78IYN6VzrWZzpsy6Xvz2uCdUm7Su9FDpAqhXjAcSzCgreVM2sUnC', 'USER,ADMIN',100,50... |
select version();
\set u_libfile '\'/tmp/build/libhlldruid.so\'';
\echo Loading the HLL-Druid library: :u_libfile
CREATE OR REPLACE LIBRARY libhlldruid AS :u_libfile;
CREATE OR REPLACE AGGREGATE FUNCTION HllDruidCreateSynopsis AS LANGUAGE 'C++' NAME 'HllDruidCreateSynopsisFactory' LIBRARY libhlldruid;
CREATE OR REPLA... |
-- Copyright 2018 <NAME>. All rights reserved. More info at http://tanelpoder.com
-- Licensed under the Apache License, Version 2.0. See LICENSE.txt for terms & conditions.
SELECT * FROM (
SELECT
sql_id
, executions
, px_servers_executions px_execs
, physical_read_requests phyrd_rq
, ROUND(physical_read_... |
-- MySQL dump 10.13 Distrib 5.6.27, for debian-linux-gnu (x86_64)
--
-- Host: localhost Database: kreepster
-- ------------------------------------------------------
-- Server version 5.6.27-0ubuntu0.14.04.1
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@... |
-- phpMyAdmin SQL Dump
-- version 4.4.14
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: 24-Dez-2016 às 00:34
-- Versão do servidor: 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_SET_CLIENT=@@CHARACTER_SET_CLIENT */;... |
truncate "public"."perfiles" RESTART IDENTITY;
INSERT INTO "public"."perfiles" (id,descripcion) VALUES (0,'Sin perfil');
INSERT INTO "public"."perfiles" (descripcion) VALUES ('Juez');
INSERT INTO "public"."perfiles" (descripcion) VALUES ('Administrador de juzgado');
INSERT INTO "public"."perfiles" (descripcion) VALUES ... |
<gh_stars>0
SELECT *
FROM [AdventureWorksDW2012].[dbo].[FactResellerSales] frs
INNER JOIN AdventureWorksDW2012.dbo.DimCurrency dc
ON frs.CurrencyKey = dc.CurrencyKey
WHERE dc.CurrencyKey = 100`
ORDER BY ShipDateKey |
ALTER TABLE states MODIFY current_map_element_id CHAR(36) NULL; |
<reponame>abhim8/Programs<filename>College_LABS/SQL(DBMS_LAB)/New folder/24-04-2021.sql<gh_stars>0
show databases;
use college;
show tables;
select *from student;
insert into student values("197R123","ram",12345,"cse",21.45);
select *from student;
insert into student (hno,phno) values("197R123",12345);
select *from stu... |
select * from Departments |
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[spAddReportArgumentQuery]') AND type in (N'P', N'PC'))
DROP PROCEDURE [dbo].[spAddReportArgumentQuery]
GO
if exists (select 1 from dbo.sysobjects where id = object_id(N'[dbo].[spAddReportArgumentQuery]') and OBJECTPROPERTY(id, N'IsProcedure') =... |
-- phpMyAdmin SQL Dump
-- version 4.6.6
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: Jul 18, 2017 at 10:21 AM
-- Server version: 5.6.35
-- PHP Version: 5.6.30
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIE... |
<reponame>BuKpYTkA/turboPush
INSERT INTO turbo.car_info_pages (id, page_alias, brand, brand_addition, models, min_price, max_price, standard, capital, image_path, created_at, updated_at) VALUES (1, 'porsche', 'Porsche', 'Порше', 'Cayenne, Carrera GT, Panamera, Boxster, 911, 968, 928, Macan, Cayenne GTS, Panamera GTS, C... |
<reponame>dsalunga/mPortal
-- Procedure GenericList_Get
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE PROCEDURE [GenericList_Get]
(
@ListId int
)
AS
SET NOCOUNT ON
if(@ListId > 0)
begin
SELECT * FROM GenericList WHERE Id = @ListId
end
RETURN
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER OFF... |
ALTER TABLE oppdrag ADD COLUMN utbetaling_id UUID NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000';
ALTER TABLE oppdrag ALTER COLUMN utbetaling_id DROP DEFAULT |
CREATE DATABASE HotelDatabase
USE HotelDatabase
CREATE TABLE Employees(
Id BIGINT PRIMARY KEY IDENTITY NOT NULL,
FirstName NVARCHAR(20) NOT NULL,
LastName NVARCHAR(20) NOT NULL,
Title NVARCHAR(20),
Notes NVARCHAR(20)
)
INSERT INTO Employees(FirstName,LastName)
VALUES
('Petyr','Petrov'),
('Georgi','Georgie... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.