sql
stringlengths
6
1.05M
set @row1:=0; set @row2:=0; select p_start.start_date,p_end.end_date from (select @row1:=@row1+1 as rown, start_date from projects where start_date not in (select end_date from projects)) as p_start inner join (select @row2:=@row2+1 as rown, end_date from projects where end_date not in (select start_date from projects)...
<reponame>nlsy-links/nlsy-links-determination-2017 USE NlsLinks; GO ALTER SCHEMA Enum TRANSFER Metadata.tblLUSurveySource; GO
<reponame>fivetran/dbt-language-server select opportunities_level_0_source.opportunity_id as id, opportunities_level_0_source.* except(opportunity_id), opportunities_level_1_quote_line_item_aggregation.* except(opportunity_id), opportunities_level_1_bookings.* except(opportunity_id), opportunities_level_1_...
CREATE DATABASE Chinook; GO USE Chinook; GO CREATE TABLE album (album_id int IDENTITY(1,1), title nvarchar(160), artist_id int); GO BULK INSERT album FROM '/home/repl/Album-pipe.csv' WITH(FIELDTERMINATOR = ',', ROWTERMINATOR = '|', FIRSTROW = 1); GO CREATE TABLE artist (artist_id int IDENTITY(1,1), name nvarcha...
CREATE SERVICE [sqlwatch_exec] ON QUEUE [dbo].[sqlwatch_exec] ( [DEFAULT] )
<filename>database/atualizador/src/main/resources/db/migration/postgresql/client/V0001/V0000/V0001_0000_00000072__CreateTable_ConnectionsSource.sql CREATE TABLE connectionssource ( id CHAVE NOT NULL, id_connections CHAVE NOT NULL, http_referer CHARACTER VARYING(...
use unjfsc; DELETE FROM entidades_participantes; DELETE FROM proyecto; DELETE FROM datos_generales; DELETE FROM entidades_asociadas; DELETE FROM actividades_infraestructura_beneficios; DELETE FROM fondos_recibidos_del_estado; DELETE FROM proyectos_financiados_ip; DELETE FROM competitividad_empresarial; DELETE FROM diag...
# ************************************************************ # Sequel Pro SQL dump # Version 4096 # # http://www.sequelpro.com/ # http://code.google.com/p/sequel-pro/ # # Host: 127.0.0.1 (MySQL 5.6.25) # Database: u972940147_boos # Generation Time: 2015-06-19 10:30:05 +0000 # *****************************************...
create or replace package FORMATS as function ADD( i_formatid FORMAT.FORMATID%type, i_name FORMAT.NAME%type, i_auduser FORMAT.AUDUSER%type) return number; function FIND( i_name FORMAT.NAME%type) return FORMAT.FORMATID%type; function MODIFY( i_formatid FORMAT.FORMATID%type, i_name FORMAT.NAME%type := null, i...
<gh_stars>0 alter table BACKMON_BACKUP_TARGET add constraint FK_BACKMON_BACKUP_TARGET_ON_FILE_DATA_FETCHER foreign key (FILE_DATA_FETCHER_ID) references BACKMON_FILE_DATA_FETCHER(ID); create index IDX_BACKMON_BACKUP_TARGET_ON_FILE_DATA_FETCHER on BACKMON_BACKUP_TARGET (FILE_DATA_FETCHER_ID);
<reponame>Dittner/GSA SELECT * FROM header
-- MySQL dump 10.13 Distrib 8.0.22, for Linux (x86_64) -- -- Host: localhost Database: crm_haxxj_com -- ------------------------------------------------------ -- Server version 8.0.16 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS *...
-- -- PostgreSQL database dump -- -- Dumped from database version 10.17 -- Dumped by pg_dump version 10.17 SET statement_timeout = 0; SET lock_timeout = 0; SET idle_in_transaction_session_timeout = 0; SET client_encoding = 'UTF8'; SET standard_conforming_strings = on; SELECT pg_catalog.set_config('search_path', '', f...
DO $$ BEGIN IF NOT EXISTS (SELECT 1 FROM information_schema.tables WHERE table_schema=current_schema AND table_name = 'rtu_response_data') THEN CREATE TABLE rtu_response_data ( id bigint NOT NULL, creation_time timestamp without time zone NOT NULL, modification_time timestamp without time zone NOT NULL, ...
ALTER TABLE github_repositories ADD COLUMN integration_enabled BOOLEAN NOT NULL DEFAULT TRUE, ADD COLUMN github_source_of_truth BOOLEAN NOT NULL DEFAULT TRUE;
-- The next comment line has no text after the '--' prefix. -- -- The next comment line starts with a space. -- x, y, z... INSERT INTO users(first_name, last_name) VALUES('Juergen', 'Hoeller'); -- This is also a comment. INSERT INTO users(first_name, last_name) VALUES( 'Sam' -- first_name , 'Brannen' -- las...
CREATE OR REPLACE FUNCTION ${schema_prefix}audit_table(target_table regclass, ignored_cols text[]) RETURNS void AS $$ DECLARE query text; excluded_columns_text text = ''; BEGIN EXECUTE 'DROP TRIGGER IF EXISTS audit_trigger_insert ON ' || target_table; EXECUTE 'DROP TRIGGER IF EXISTS audit_trigger_update...
CREATE OR REPLACE PROCEDURE load_pathways IS pathflag NUMBER; pathwayid NUMBER; geneid NUMBER; geneflag VARCHAR (50); BEGIN EXECUTE IMMEDIATE ('TRUNCATE TABLE BIOGENES_TEMP REUSE STORAGE '); EXECUTE IMMEDIATE ('TRUNCATE TABLE GENE_PATHWAY REUSE STORAGE '); EXECUTE IMMEDIATE ('TRUNCATE ...
<reponame>opengauss-mirror/Yat -- @testpoint: 插入bool类型 drop table if exists binary_integer06; create table binary_integer06 (name binary_integer); insert into binary_integer06 values ('1'); insert into binary_integer06 values ('0'); insert into binary_integer06 values (true); insert into binary_integer06 values (false...
<gh_stars>0 CREATE TABLE REQUEST_LOG ( ID BIGINT NOT NULL AUTO_INCREMENT, REQUEST_UUID VARCHAR(64) NOT NULL, TYPE INT NOT NULL, CLIENT_ADDRESS VARCHAR(255) NULL, REQUEST_URL VARCHAR(255) NULL, REQUEST_METHOD VARCHAR (50) NULL, RESPONSE_STATUS VARCHAR(10) NULL, USER_ID BIGINT NULL, CREATE_DATE DATETIME NOT NU...
<filename>sql/fill_tables.sql<gh_stars>0 -- Set params SET SESSION my.number_of_sales = '200'; SET SESSION my.number_of_users = '500'; SET SESSION my.number_of_products = '300'; SET SESSION my.number_of_stores = '500'; SET SESSION my.number_of_countries = '100'; SET SESSION my.number_of_cities = '30'; SET SESSION my.st...
SELECT DepositGroup, MagicWandCreator, MIN(DepositCharge) FROM WizzardDeposits GROUP BY DepositGroup, MagicWandCreator
<gh_stars>0 -- # Problem: https://www.hackerrank.com/challenges/weather-observation-station-5/problem -- # Score: 30 -- MySQL START SELECT CITY, CHAR_LENGTH(CITY) FROM STATION ORDER BY CHAR_LENGTH(CITY), CITY LIMIT 1; SELECT CITY, CHAR_LENGTH(CITY) FROM STATION ORDER BY CHAR_LENGTH(CITY) DESC, CITY LIMIT 1; -- MySQL...
------------------------------------------------------------------------- -- PKG_INSIGHTS ------------------------------------------------------------------------- CREATE OR REPLACE PACKAGE pkg_insights IS ------------------------------------------------------------------------- PROCEDURE p_pending_disposed_cases ...
--user_friend table select concat('insert into user_friend(id, follower_id, friend_id, created_at, updated_at, version) values(', id, ', ', follower_id, ', ', friend_id, ', ''', created_at, ''', null, 0);') from user_friend order by id asc; --friend table select concat('insert into friend(id, twitter_user_id, usern...
INSERT INTO `Transcript` (`idItem`,`Account_idAccount`, `itemName`, `scores`, `describe`, `IDParent`,`scoresDefault`, `scoresMax`,`scoresStudent`, `scoresTeacher`) VALUES ('I','B1400704', 'Điều 4. Đánh giá về ý thức tham gia học tập', 20, '', '',20,20,20,20), ('I.a','B1400704', 'a. Ý thức và thái độ trong học tập.',0...
<reponame>skylarkjava/skylark-knowledge<gh_stars>0 SELECT * FROM USERS;
ALTER TABLE "public"."patient" ALTER COLUMN "occupation" SET NOT NULL;
-- Subset of TARS tables, used by Journal Extract CREATE TABLE EXAMINER ( "STAFF_NUMBER" VARCHAR2(10 BYTE) NOT NULL ENABLE, "GRADE_CODE" VARCHAR2(4 BYTE), "PROB_PER_START_DATE" DATE, "PROB_PER_END_DATE" DATE, "DSA_BIKE_IND" NUMBER(1,0), "DSA_RADIO_IND" NUMBER(1,0), "WELSH_SPKG_CODE" NUMBER(1,0) DEFAULT 1 NOT ...
-- phpMyAdmin SQL Dump -- version 4.9.5 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Waktu pembuatan: 20 Jul 2020 pada 23.56 -- Versi server: 10.3.16-MariaDB -- Versi PHP: 7.3.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET ...
<reponame>GeorgiPopovIT/CSharp-DB CREATE PROC usp_TransferMoney(@senderId INT, @receiverId INT, @amount DECIMAL(15,4)) AS BEGIN TRANSACTION DECLARE @currSender INT = (SELECT Id FROM Accounts WHERE Id = @senderId) DECLARE @senderBalance INT = (SELECT Balance FROM Accounts WHERE Id = @senderId) DECLARE @currReceiver I...
<reponame>GoEddie/SSDT-DevPack CREATE PROCEDURE [dbo].[aaaa] @param1 int = 0, @param2 int AS set transaction isolation level read uncommitted; SELECT @param1, @param2 jnjnjnjn RETURN 0
<filename>SRV/SRV/SRV/srv/Stored Procedures/AutoShortInfoRunJobs.sql  -- ============================================= -- Author: <Author,,Name> -- Create date: <Create Date,,> -- Description: <Description,,> -- ============================================= CREATE PROCEDURE [srv].[AutoShortInfoRunJobs] @second in...
<reponame>mailkiq/mailkiq UPDATE messages SET state = ( CASE WHEN data ? 'bouncedRecipients' THEN 1 WHEN data ? 'complainedRecipients' THEN 2 END ) FROM notifications WHERE (data ? 'bouncedRecipients' OR data ? 'complainedRecipients') AND messages.id = notifications.message_id;
-- pagerfault.test -- -- execsql { PRAGMA journal_mode = delete } PRAGMA journal_mode = delete
alter table :GRAPHILE_WORKER_SCHEMA.jobs alter column queue_name drop not null; create or replace function :GRAPHILE_WORKER_SCHEMA.add_job( identifier text, payload json = '{}', queue_name text = null, run_at timestamptz = now(), max_attempts int = 25, job_key text = null ) returns :GRAPHILE_WORKER_SCHEMA....
<gh_stars>0 -- The statement below sets the collation of the database to utf8 ALTER DATABASE fponce2 CHARACTER SET utf8 COLLATE utf8_unicode_ci; -- this is a comment in SQL (yes, the space is needed!) -- these statements will drop the tables and re-add them -- this is akin to reformatting and reinstalling Windows (OS ...
CREATE SCHEMA eniwarenet; CREATE SEQUENCE eniwarenet.eniwarenet_seq; CREATE SEQUENCE eniwarenet.Edge_seq; /* ========================================================================= ========================================================================= LOCATION ===========================================...
<reponame>ECELman/Course_Software_Engineering<filename>BBQ Renting System V2/bbqDB.sql -- phpMyAdmin SQL Dump -- version 4.4.10 -- http://www.phpmyadmin.net -- -- Host: localhost:8889 -- Generation Time: Jun 17, 2018 at 03:37 PM -- Server version: 5.5.42 -- PHP Version: 7.0.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SE...
INSERT INTO `db_patches` VALUES ('PHPOE-1741'); RENAME TABLE labels TO z_1741_labels; CREATE TABLE IF NOT EXISTS labels ( id char(36) NOT NULL, module varchar(100) NOT NULL, field varchar(100) NOT NULL, module_name varchar(100) NOT NULL, field_name varchar(100) NOT NULL, code varchar(50) UNIQUE, name v...
-->-->-- src/Frapid.Web/Areas/Frapid.Calendar/db/PostgreSQL/2.x/2.0/src/01.types-domains-tables-and-constraints/tables-and-constraints.sql --<--<-- DROP SCHEMA IF EXISTS calendar CASCADE; CREATE SCHEMA calendar; CREATE TABLE calendar.categories ( category_id SERIAL PRIMARY KEY, user_id integer NOT NU...
<filename>src/main/resources/database/postgresql/alter_12_0_x_to_12_1_0.sql -- auto access controll create table o_ac_auto_advance_order ( id bigserial, creationdate timestamp not null, lastmodified timestamp not null, a_identifier_key varchar(64) not null, a_identifier_value varchar(64) not null, a_status ...
<reponame>meowjesty/hello-actix select * from Todo where Todo.task like $1;
<reponame>Tylarb/gpdb -- tests MPP-2614 -- two segments no mirrors drop table if exists hashagg_test; create table hashagg_test (id1 int4, id2 int4, day date, grp text, v int4); create index hashagg_test_idx on hashagg_test (id1,id2,day,grp); insert into hashagg_test values (1,1,'1/1/2006','there',1); insert into hasha...
-- phpMyAdmin SQL Dump -- version 4.5.4.1deb2ubuntu2.1 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Feb 22, 2019 at 07:25 PM -- Server version: 5.7.25-0ubuntu0.16.04.2 -- PHP Version: 7.1.26-1+ubuntu16.04.1+deb.sury.org+1 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!...
-- @testpoint:opengauss关键字unique(保留),作为外部数据源名 --关键字不带引号-失败 drop data source if exists unique; create data source unique; --关键字带双引号-成功 drop data source if exists "unique"; create data source "unique"; drop data source "unique"; --关键字带单引号-合理报错 drop data source if exists 'unique'; create data source 'unique'; --关键字带反...
<reponame>marlonlom/oracle-util-millis CREATE OR REPLACE PACKAGE BODY utl_unixtime AS /** * Converts provided timestamp in milliseconds. * * @param p_timestamp timestamp to convert in milliseconds. * @return datetime in milliseconds. */ FUNCTION to_time_millis ( p_timestamp IN TIMESTAMP ) RETURN NU...
<gh_stars>0 SELECT E.codice, E.nome, S.nome AS area, E.prezzo AS prezzo, E.descrizione FROM esame_specialistico AS E JOIN specialita AS S ON E.area=S.id WHERE (E.for_sesso = ? OR E.for_sesso = ?) AND lower(E.nome) LIKE ? OR lower(S.nome) LIKE ? OR lower(descrizione) LIKE ?
/* Author: <NAME> Purpose: Import census tract to PUMA Date: November 13, 2019 */ -- Drop any existing tables DROP TABLE IF EXISTS ct_puma_xwalk; -- Create a table for the census tract to puma geographic crosswalk data CREATE TABLE ct_puma_xwalk ( STATEFP CHARACTER(2), COUNTYFP CHARAC...
<gh_stars>0 DROP TABLE IF EXISTS cell; SHOW WARNINGS; CREATE TABLE cell ( added_at INTEGER PRIMARY KEY NOT NULL, row_key VARCHAR(36) NOT NULL, column_name VARCHAR(64) NOT NULL, ref_key INTEGER NOT NULL, body JSON, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, UNIQUE `cell_idx`(`row_key`, `c...
<reponame>whitegreyblack/PyWin drop table if exists storecategory; drop table if exists stores; drop table if exists receipts; drop table if exists products; create table storecategory ( id_category integer PRIMARY KEY AUTOINCREMENT, category varchar(25) ); create table stores ( id_store ...
CREATE TABLE task_activity ( id serial PRIMARY KEY, task_id integer NOT NULL REFERENCES targets (id), text varchar(255) NOT NULL, created_by integer NOT NULL REFERENCES users (id), date timestamp with time zone NOT NULL DEFAULT now() );
<filename>SQL/laravel_test.sql<gh_stars>0 -- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Aug 28, 2020 at 05:52 AM -- Server version: 10.4.13-MariaDB -- PHP Version: 7.4.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00...
CREATE PROCEDURE dbo.RemoteLibrary_Del ( @Id int ) AS SET NOCOUNT ON IF(@Id > 0) DELETE FROM RemoteLibrary WHERE Id=@Id RETURN
CREATE OR REPLACE FUNCTION "add_item_to_base"() RETURNS trigger AS $BODY$ BEGIN INSERT INTO "item" ( "item_id", "class" ) VALUES (NEW.item_id, TG_TABLE_NAME::regclass::text); RETURN NEW; END; $BODY$ LANGUAGE plpgsql; /** * test plpgsql functions piece by piece using this which can be executed withou...
/* Navicat Premium Data Transfer Source Server : mycentos Source Server Type : MySQL Source Server Version : 50724 Source Host : 172.16.58.3:3306 Source Schema : Organization Target Server Type : MySQL Target Server Version : 50724 File Encoding : 65001 Date: 02/09/2...
-------------------------------------------------------------------------------- CREATE OR REPLACE PROCEDURE SCHEMA.PROC_GATHER_TABLE_STALE_STATS IS BEGIN -- Flush statistics to Disk to see the changes immediately (Insufficient Privillege): -- dbms_stats.flush_database_monitoring_info; ...
DROP TABLE images;
SELECT a.id, b.age, a.coins_needed, a.power FROM Wands a INNER JOIN Wands_Property b ON a.code=b.code WHERE b.is_evil!=1 AND a.coins_needed=( SELECT MIN(Wands.coins_needed) FROM Wands INNER JOIN Wands_Property ON Wands.code=Wands_Property.code WHERE Wands_Property.age=b.age AND Wands.power=a.power...
-- Adminer 4.7.1 MySQL dump SET NAMES utf8; SET time_zone = '+00:00'; SET foreign_key_checks = 0; SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO'; INSERT INTO `punkts` (`tdId`, `gpId`, `city`) VALUES (0, 'Sklad-SPB', 'SPB'), (1, 'Sklad-MSK', 'MSK'), (727, 'Avtovo-S75', 'SPB'), (728, 'Avtovo-MK1', 'SPB'), (729, 'Akademicheskay...
<gh_stars>1-10 --============================================================================== -- GPI - <NAME> -- Desc: analyse chained rows in the database -- -- Must be run with dba privileges -- -- --============================================================================== -- http://docs.oracle.com/cd/B2835...
-- phpMyAdmin SQL Dump -- version 3.5.8.1 -- http://www.phpmyadmin.net -- -- 主机: localhost -- 生成日期: 2015 年 04 月 13 日 14:30 -- 服务器版本: 5.6.23 -- PHP 版本: 5.5.14 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_S...
<reponame>adrianmahjour/db2-samples --# Copyright IBM Corp. All Rights Reserved. --# SPDX-License-Identifier: Apache-2.0 /* * Shows the size of each Synopsis table created for each Column Organized Table */ CREATE OR REPLACE VIEW DB_SYNOPSIS_SIZE AS SELECT T.TABSCHEMA , T.TABNAME , DATA_L_KB , SYN_L_K...
<gh_stars>0 CREATE or replace FUNCTION replace_symbol(syn_text text) RETURNS text AS $$ DECLARE -- 我自己的参数 s_text text:=syn_text; s_len numeric:=null; s_step varchar(100):=null; r_text text:='' ; s_every_char text:=''; -- 系统异常捕获 sys_RETURNED_SQLSTATE text:=null; sys_COLUMN_NAME tex...
CREATE TABLE "Wins_3"( "Calculation_-2642768498540482557" float8 NOT NULL, "Calculation_-2642768498540609534" decimal(5, 3) NOT NULL, "Calculation_-2642768498540806143" decimal(4, 2) NOT NULL, "Number of Records" smallint NOT NULL, "n1CBL0" decimal(4, 2) NOT NULL, "n1CBL1" decimal(4, 2) NOT NULL, "n1CBL2" decimal(4, 2)...
DELETE FROM OrderParts WHERE OrderId = 19 DELETE FROM Orders WHERE OrderId = 19
CREATE PROCEDURE [dbo].[uspLaterRatedIssueUpdate] @LaterRatedIssueID uniqueidentifier, @LaterRatedIssueValue nvarchar(100), @IssueID uniqueidentifier, @LaterRatedIssueWeight decimal(18, 2) , @Deleted bit, @DeletedBy uniqueidentifier, @DeletedOn datetime AS SET NOCOUNT ON SET XACT_ABORT O...
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 06, 2019 at 12:20 PM -- Server version: 10.1.40-MariaDB -- PHP Version: 7.3.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
update sal.fcu_formulacion_cursores set fcu_select_run = 'declare @codcia int, @codrsa int, @codpai varchar(2), @codppl int, @codtpl_ordinario int, @codtpl int set @codcia = $$CODCIA$$ set @codppl = $$CODPPL$$ set @codtpl = $$CODTPL$$ set @codrsa = gen.get_valor_parametro_int (''CodigoRubroSalario'',null,null,@c...
/** Colantro, <NAME>. **/ DROP DATABASE IF EXISTS Client; CREATE DATABASE Client; USE Client; CREATE TABLE clients ( `id` INTEGER UNSIGNED PRIMARY KEY AUTO_INCREMENT, `name` VARCHAR (191), `address` VARCHAR (191), `phone` VARCHAR (10), `capi...
<reponame>claudiopdcgdm/projects-delphiX10<filename>db/sqls/db_app_wms.sql -- -- PostgreSQL database dump -- -- Dumped from database version 10.16 -- Dumped by pg_dump version 10.16 SET statement_timeout = 0; SET lock_timeout = 0; SET idle_in_transaction_session_timeout = 0; SET client_encoding = 'UTF8'; S...
INSERT INTO archfolio.followers(follower_id, following_id) VALUES ( :id, ( SELECT id FROM archfolio.users WHERE username = :identification OR email = :identification ) ...
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Aug 04, 2020 at 02:55 PM -- Server version: 10.4.13-MariaDB -- PHP Version: 7.4.8 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIEN...
<filename>database/script.sql /* MySQL */ CREATE TABLE users ( user_id integer auto_increment, name text not null, email text not null, password text not null, role integer not null, primary key (user_id), unique (email) ); CREATE TABLE password_tokens ( token_id integer auto_increm...
CREATE TABLE [Data_Load].[DAS_EmploymentCheck] ( [Id] BIGINT NOT NULL PRIMARY KEY IDENTITY(1, 1), [NationalInsuranceNumber] NVARCHAR(9) NOT NULL, [Uln] BIGINT NOT NULL, [EmployerAccountId] BIGINT NOT NULL, [Ukprn] BIGINT NOT NULL, [CheckDate] DATETIME NOT NULL, [CheckPassed] BIT NOT NULL, [IsLatest] BIT NO...
<filename>block-tools/migrations/2021-01-16-233957_block_initial/down.sql<gh_stars>1-10 DROP TABLE properties; DROP TABLE blocks;
DROP DATABASE IF EXISTS urReview_db; CREATE DATABASE urReview_db;
<gh_stars>1-10 ALTER TABLE Area ADD COLUMN meeting_category varchar(256);
-- sort.test -- -- execsql { -- SELECT x FROM t6 ORDER BY y DESC; -- } SELECT x FROM t6 ORDER BY y DESC;
<reponame>Moesugi/MFG<filename>server/conf/db/migration/default/V82__add_record_fleet_group.sql insert into fleet_group values (3, "第七駆逐隊"), (4, "第十六駆逐隊"), (5, "第十七逐隊"), (6, "第三十駆逐隊"); insert into fleet_group_member values (3, 15), (3, 16), (3, 93), (3, 94), (4, 20), (4, 181), ...
<filename>Trader.Data.Sql.Database/Procedures/GetOrders.sql CREATE PROCEDURE [dbo].[GetOrders] @Symbol NVARCHAR(100) AS SET NOCOUNT ON; SELECT [S].[Name] AS [Symbol], [O].[OrderId], [O].[OrderListId], [O].[ClientOrderId], [O].[Price], [O].[OriginalQuantity], [O].[ExecutedQuantity], [O]....
<filename>dump.sql<gh_stars>0 -- MariaDB dump 10.17 Distrib 10.4.13-MariaDB, for Linux (x86_64) -- -- Host: localhost Database: unito_tweb -- ------------------------------------------------------ -- Server version 10.4.13-MariaDB /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_...
select quote(binary_9) from nulls1 where rowid = 1 and binary_9 is not X'00'
<filename>migrations/2019-08-10-162408_tip_cuecard_sort_order/down.sql ALTER TABLE tip_cuecards RENAME TO tip_cuecards_drop; CREATE TABLE tip_cuecards ( id INTEGER NOT NULL PRIMARY KEY, tip_id INTEGER NOT NULL, cuecard_id INTEGER NOT NULL, FOREIGN KEY (tip_id) REFERENCES tips(id) ON UPDATE CASCADE ON DELETE CAS...
use beegfs_scratch_statistics_reports; LOAD DATA INFILE "/packages/temp2.old/lustre_rootdir_report_2019-08-19_with_date.csv" INTO TABLE rootdir_reports COLUMNS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' ESCAPED BY '"' LINES TERMINATED BY '\n'; /*IGNORE 1 LINES;*/
alter table qb_fenlei_sort add `activityrule` varchar(255) DEFAULT NULL COMMENT '活动规则'; alter table qb_fenlei_sort add `isenable` varchar(255) DEFAULT '0' COMMENT '是否启用(0:是;1:否)'; alter table qb_fenlei_sort add `description` varchar(255) DEFAULT NULL COMMENT '活动描述'; alter table qb_fenlei_content1 add `gid` tinyint(3) ...
<filename>clipper-cli/src/test/scripts/v_AdministrativeStaff.sql DROP VIEW v_AdministrativeStaff CASCADE; CREATE OR REPLACE VIEW v_AdministrativeStaff AS SELECT innerRel.x1 AS att1 FROM ( SELECT ca_0.individual AS x1 FROM concept_assertion ca_0 WHERE ca_0.concept=59 UNION SELECT ca_0.individual AS x1 FROM concept_a...
SELECT employee_id, last_name, salary FROM employees WHERE salary > (SELECT AVG(salary) FROM employees) ORDER BY salary
<reponame>OlliL/lalaHBCI -- MySQL dump 10.13 Distrib 5.6.26, for FreeBSD10.1 (amd64) -- -- Host: localhost Database: moneyflow_hbci -- ------------------------------------------------------ -- Server version 5.6.26 -- -- Table structure for table `account_movements` -- DROP TABLE IF EXISTS account_movement...
<filename>sql/updates/0.0.2/sql_r290.sql /* r290 xhtml code removed from php for plug whosonline*/ DELETE FROM `sed_plugins` WHERE `pl_file` = 'indexpolls.main';
--+ holdcas on; --alter_table_change_type_strict --change the type of a char() column to float create class coo( col1 char(50), col2 char(50), col3 char(50), col4 char(50), col5 char(50), col6 char(50), col7 char(50), col8 char(100) ); insert into coo values('-8237.923123', '3.402...
<gh_stars>100-1000 -- mined_height and mined_in_block should always be set together, since mined_in_block is NULL we set mined_height to NULL -- so that the transactions can be revalidated. UPDATE completed_transactions SET mined_height = NULL WHERE mined_height IS NOT NULL AND mined_in_block IS NULL;
<filename>openGaussBase/testcase/SQL/INNERFUNC/type-trans/Opengauss_Function_Innerfunc_Type_Trans_Num_Case0001.sql -- @testpoint: 类型转换函数to_number将字符串类型的值转换为指定格式的数字,入参为有效值 select to_number('12,454.8-', '99g999d9s'); -- 模式串9长度超过数字个数 select to_number('12,454,234-', '9999999g999g999d9s'); -- 模式串9长度比数字个数短,四舍五入 select to...
<reponame>SQLAdrian/MadeiraToolbox<filename>Best Practices Checklists/Last Partition Not Empty.sql<gh_stars>0 SET NOCOUNT ON; SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED; DECLARE @Results AS TABLE (database_id int, object_id int, rows int, partition_number int, partition_scheme sysname, partition_function sysname...
SELECT SupplierID ,CompanyName FROM Suppliers WHERE SupplierID NOT IN (SELECT SupplierID FROM Products WHERE SupplierID IS NOT NULL);
<gh_stars>0 DROP SCHEMA IF EXISTS boilerplatedev; CREATE SCHEMA IF NOT EXISTS boilerplatedev; USE boilerplatedev; CREATE TABLE item ( id INT (11) NOT NULL AUTO_INCREMENT, name VARCHAR(12) NOT NULL, PRIMARY KEY ( id ) ); INSERT INTO item(name) VALUES ('fishing rod'); INSERT INTO item(name) VALUES ('keyboar...
DROP SCHEMA public CASCADE;
<gh_stars>0 -- custom_fields_for_items_and_item_kits -- ALTER TABLE `phppos_items` ADD `custom_field_1_value` VARCHAR(255) NULL DEFAULT NULL, ADD INDEX (`custom_field_1_value`), ADD `custom_field_2_value` VARCHAR(255) NULL DEFAULT NULL, ADD INDEX (`custom_field_2_value`), ADD `custom_field_3_value` VARCHAR(255) ...
<reponame>jpoliveira12345/Projects --DROP SCHEMA Palcos cascade; --REVOKE CONNECT ON DATABASE rock_in_rio FROM organizador,plateia;DROP ROLE jose,joao, organizador,plateia; --CREATE DATABASE rock_in_rio CREATE SCHEMA Palcos; SET search_path to Palcos; CREATE TABLE Patrocinador( cod integer, nome varchar(40)...
SET serveroutput ON DECLARE V_STUDENT TAKES_MODULE.studentno%TYPE; V_PROG_CODE TAKES_MODULE.prog_code%TYPE := '&Enter_Program_Code'; V_MODULE_CODE TAKES_MODULE.module_code%TYPE; V_STAGE_CODE TAKES_MODULE.stage_code%TYPE := &Enter_Stage_Code; --V_SCORE TAKES_MODULE.score%TYPE; -- DECLARE CURRENT D...