sql
stringlengths
6
1.05M
CREATE TABLE indtoasttest ( descr text, cnt int DEFAULT 0, f1 text, f2 text ); INSERT INTO indtoasttest (descr, f1, f2) VALUES ('two-compressed', repeat('1234567890', 1000), repeat('1234567890', 1000)); INSERT INTO indtoasttest (descr, f1, f2) VALUES ('two-toasted', repeat('1234567890', 30000)...
<filename>data/backup/1443064629/tables/sline_qq_kefu.sql CREATE TABLE `sline_qq_kefu` ( `id` int(11) NOT NULL AUTO_INCREMENT, `pid` int(11) unsigned DEFAULT '0', `qqname` varchar(50) DEFAULT NULL, `qqnum` varchar(20) DEFAULT NULL, `isopen` tinyint(3) DEFAULT '1', `displayorder` int(4) DEFAULT '9999', PRI...
<reponame>opengauss-mirror/Yat -- @testpoint: 指定正常网络地址输入值 drop table if exists test_cidr_01; create table test_cidr_01(type cidr); insert into test_cidr_01 values('192.168.100.128/25'); insert into test_cidr_01 values('192.168.31/24'); insert into test_cidr_01 values('10.1'); insert into test_cidr_01 values('192.168')...
-- @testpoint:opengauss关键字routine_catalog(非保留),作为视图名 --关键字explain作为视图名,不带引号,创建成功 CREATE or replace VIEW routine_catalog AS SELECT * FROM pg_tablespace WHERE spcname = 'pg_default'; drop view routine_catalog; --关键字explain作为视图名,加双引号,创建成功 CREATE or replace VIEW "routine_catalog" AS SELECT * FROM pg_tablespace WHERE s...
<filename>fridgee_database_script.sql -- phpMyAdmin SQL Dump -- version 4.7.9 -- https://www.phpmyadmin.net/ -- -- Hôte : 127.0.0.1 -- Généré le : Dim 29 avr. 2018 à 20:38 -- Version du serveur : 10.1.31-MariaDB -- Version de PHP : 7.2.3 CREATE DATABASE fridgee_db; USE fridgee_db; SET SQL_MODE = "NO_AUTO_VALUE_ON...
/* Oda.Authentication : LogoffSession.sql. */ declare @EmptyGuid uniqueidentifier = '00000000-0000-0000-0000-000000000000'; update Sessions set AccountId = @EmptyGuid where SessionId = @SessionId;
<reponame>c-w/r-sql-server-demo<gh_stars>0 INSERT INTO dbo.nyc_taxi_models(model, name) SELECT BulkColumn, '$(ModelId)' FROM OPENROWSET( BULK '$(Container)/$(ModelId)', DATA_SOURCE = 'AzureModels', SINGLE_BLOB ) AS DATA;
<filename>giraf10/sql/kcombu.sql CREATE TABLE kcombu_pairs ( comp_id1 TEXT NOT NULL , comp_id2 TEXT NOT NULL , tanimoto FLOAT NOT NULL , PRIMARY KEY (comp_id1,comp_id2) ); SELECT x.*, k.* FROM all_vs_all_nonpolymer x JOIN interfaces_nonpolymer i1 ON i1.if_id = x.if_id1 JOIN interfa...
<filename>login/contact/db-sql.sql CREATE DATABASE IF NOT EXISTS `test` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci; USE `test`; -- DROP TABLE IF EXISTS `tbl_contact`; CREATE TABLE `tbl_contact` ( `id` int(11) NOT NULL, `Start_Location` varchar(50) NOT NULL, `End_location` varchar(15...
<reponame>nabeelkhan/Oracle-DBA-Life -- *************************************************************************** -- File: 4_27.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 -- f...
-- shared_pool_advice.sql -- see MetaLink Note 255409.1 col shared_pool_size_for_estimate format 999999 heading "Size of Shared Pool in MB" col shared_pool_size_factor format 99.90 head "Size Factor" col estd_lc_time_saved format 999,999,999 head "Time Saved in sec" col estd_lc_size format 99,999,999,999 head "Est li...
<filename>sql-scripts/database.sql select 1; # Meta create table at_active_status_v1 ( active_status_id smallint primary key, active_status text, active_status_group text, active_status_description text, create_time timestamp default now() ); create table at_task_pri...
<gh_stars>0 INSERT INTO burgers (burger_name, devoured) VALUES ('Double Cheeseburger', false); INSERT INTO burgers (burger_name, devoured) VALUES ('McChicken', false); INSERT INTO burgers (burger_name, devoured) VALUES ('Whopper', false);
<gh_stars>1-10 CREATE INDEX INDX_propertyusage_usagetype ON egwtr_property_usage (usagetype); CREATE INDEX INDX_propertyusage_propertytype ON egwtr_property_usage (propertytype); CREATE INDEX INDX_propertycategory_categorytype ON egwtr_property_category (categorytype); CREATE INDEX INDX_propertycategory_propertytype O...
<gh_stars>1-10 -- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Mar 16, 2019 at 05:19 AM -- Server version: 10.1.37-MariaDB -- PHP Version: 7.2.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /...
<gh_stars>1-10 ----------------- -- Persistence -- ----------------- -- create extension if not exists "uuid-ossp"; create schema migrations; -- Registry of every DDL statement create table migrations.statement ( id uuid primary key default uuid_generate_v4(), stmt text not null, is_current bool not nul...
<reponame>jdkoren/sqlite-parser -- coalesce.test -- -- db eval { -- SELECT ifnull(d+c+b,ifnull(d+c,d)) FROM t1 ORDER BY a; -- } SELECT ifnull(d+c+b,ifnull(d+c,d)) FROM t1 ORDER BY a;
<filename>backend/de.metas.procurement.base/src/main/sql/postgresql/system/50-de.metas.procurement/5440920_sys_09628_AD_Messages.sql<gh_stars>1000+ -- 26.02.2016 17:42 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator INSERT INTO AD_Message (AD_Client_ID,AD_Message_ID,AD_Org_ID,Created,CreatedBy,EntityT...
<reponame>dangerdrennan/CAMS create or replace function get_cs_sub_descriptions(cat_id int) returns table( suboutcome_name text, score_id text, suboutcome_description text ) AS $$ begin return query select suboutcome_details_cse.suboutcome_name, suboutcome_details_cse.score_id, suboutcome_details_cse.subout...
<filename>server/db-manager/queries/create/CREATE_TBL_BOOKS_STATUS.sql CREATE TABLE conduit_db."BOOKS_STATUS" ( "BOOK_ID" integer NOT NULL DEFAULT nextval('conduit_db.books_id_seq'::regclass), "ARTICLE_ID" character varying(64) COLLATE pg_catalog."default" NOT NULL, "TEAM_ID" integer NOT NULL, "USER_ID"...
<filename>out/production/final/facultative1.sql<gh_stars>0 CREATE TABLE `Commands` ( `id` int(11) NOT NULL, `menuitem` tinyint(1) NOT NULL DEFAULT '0', `role_id` int(11) NOT NULL, `command` varchar(32) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -- -- Дамп данных таблицы `Commands` -- INSERT INTO `Commands...
<gh_stars>0 ALTER TABLE sys_user modify birthdate DATE DEFAULT NULL;
# --- Created by Ebean DDL # To stop Ebean DDL generation, remove this comment and start using Evolutions # --- !Ups create table comment ( id bigint not null, post_id bigint, comment_msg varchar(2000), commented_on times...
<gh_stars>10-100 ALTER TABLE /*$wgDBprefix*/interwiki ADD COLUMN iw_trans TINYINT NOT NULL DEFAULT 0;
<filename>data/sql/job-plus.sql /* Navicat Premium Data Transfer Source Server : localhost_3306 Source Server Type : MySQL Source Server Version : 50726 Source Host : localhost:3306 Source Schema : task_manage Target Server Type : MySQL Target Server Version : 50726 File Encod...
TRUNCATE TABLE morphl.ga_chp_features_raw_t; TRUNCATE TABLE morphl.ga_chp_features_training;
ALTER TEXT SEARCH CONFIGURATION russian ALTER MAPPING FOR asciiword, asciihword, hword_asciipart WITH thesaurus_simple;
INSERT INTO waffle_switch_mkt (name, active, note, created, modified) VALUES ('marketplace-feed', 0, 'Enables the Feed features of Marketplace', NOW(), NOW());
<reponame>carlos-ramos-mv/laboratoriouno /* Navicat Premium Data Transfer Source Server : LaboratorioUno Source Server Type : PostgreSQL Source Server Version : 130002 Source Host : localhost:5432 Source Catalog : laboratoriouno Source Schema : public Target Serve...
# ************************************************************ # Sequel Pro SQL dump # Version 4541 # # http://www.sequelpro.com/ # https://github.com/sequelpro/sequelpro # # Host: localhost (MySQL 5.7.18) # Database: musiciansjobs # Generation Time: 2017-07-04 21:15:13 +0000 # *****************************************...
CREATE EXTENSION "uuid-ossp" SCHEMA public; COMMENT ON EXTENSION "uuid-ossp" IS 'generate universally unique identifiers (UUIDs)';
CREATE DATABASE `enigma` /*!40100 DEFAULT CHARACTER SET utf8 */ /*!80016 DEFAULT ENCRYPTION='N' */;
/* saves the given table in the bucketFS specified by connection_name. You have to either adjust the input parameters to match your columns(and then also adjust the write to file), so it can be ordered by one of them. If the input was dynamic, it could not be ordered and the rows would ordered differently in the ou...
<gh_stars>1-10 IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_MChapter_Name]') AND type = 'D') BEGIN ALTER TABLE [dbo].[MChapter] DROP CONSTRAINT [DF_MChapter_Name] END GO IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_MChapter_ParentId]') AND type = 'D') BEGIN ALTER TABLE [db...
UPDATE TESTCHILD SET DESCRIPTION = 'Updated description 1.1' WHERE ID=1 AND CHILDID=1; UPDATE TESTCHILD SET DESCRIPTION = 'Updated description 1.2' WHERE ID = 1 AND CHILDID = 2;
<gh_stars>1-10 CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; DROP TABLE IF EXISTS kbCAH; DROP TABLE IF EXISTS kbAPOD; DROP TABLE IF EXISTS kbRules; DROP TABLE IF EXISTS kbBranco; DROP TABLE IF EXISTS kbGarrison; DROP TABLE IF EXISTS kbStonewall; ALTER TABLE kbGuild DROP COLUMN IF EXISTS complete_log_channel; ALTER TABL...
INSERT INTO `s_order` (`id`, `ordernumber`, `userID`, `invoice_amount`, `invoice_amount_net`, `invoice_shipping`, `invoice_shipping_net`, `ordertime`, `status`, `cleared`, `paymentID`, `transactionID`, `comment`, `customercomment`, `internalcomment`, `net`, `taxfree`, `partnerID`, `temporaryID`, `referer`, `cleareddate...
<filename>src/main/resources/db/migration/nomis/ddl-oracle/V1_500__ADDRESSES.sql CREATE INDEX "ADDRESSES_NI6" ON "ADDRESSES" (UPPER("STREET")); CREATE INDEX "ADDRESSES_NI7" ON "ADDRESSES" (UPPER("LOCALITY"));
<reponame>SkillsFundingAgency/das-assessor-service CREATE TABLE [dbo].[ApprovalsExtract_Staging] ( [ApprenticeshipId] BIGINT, [FirstName] NVARCHAR(100) NULL, [LastName] NVARCHAR(100) NULL, [ULN] BIGINT NULL, [TrainingCode] INT NULL, [TrainingCourseVersion] NVARCHAR(10) NULL, [TrainingCo...
-- randexpr1.test -- -- db eval {SELECT case when coalesce((select max(case b & d*(abs(t1.e)/abs(a))-f & t1.b when t1.e then coalesce((select max(t1.e) from t1 where t1.e between (select ~count(*)*cast(avg(19) AS integer) from t1) and case c when a then 13 else a end),t1.f)+e*c else t1.d end) from t1 where t1.a in (se...
-- file:privileges.sql ln:526 expect:true ALTER TABLE test9a ADD COLUMN c testdomain1
<reponame>zzahti/skytools<gh_stars>100-1000 create or replace function londiste.create_trigger( in i_queue_name text, in i_table_name text, in i_trg_args text[], in i_dest_table text, in i_node_type text, out ret_code int4, out ret_note text, out trig...
CREATE TABLE IF NOT EXISTS PUBLIC.PUBLIC.PESSOA ( ID BIGINT NOT NULL IDENTITY, NOME VARCHAR(20) NOT NULL, EMAIL VARCHAR(30), CPF VARCHAR(20) NOT NULL, SEXO VARCHAR(20), DATA_NASC DATE NOT NULL, NATURALIDADE VARCHAR(20), NACIONALIDADE VARCHAR(20), CONSTRAINT SYS_PK_10092 PRIMARY KEY (ID) ); CREATE UNIQUE INDEX ...
SELECT DISTINCT s.StudentUniqueId AS StudentNumber ,a.AssessmentIdentifier AS AssessmentId ,sa.StudentAssessmentIdentifier AS StudentAssessmentId ,sa.AdministrationDate AS TestDate ,sai.IdentificationCode AS QuestionNumber ,sai.AssessmentResponse AS StudentResponse ,sai.RawScoreResult AS Poi...
<filename>ppr-api/test_data/postgres_data_files/test0010.sql -- TEST0010 Change Statement collateral subsitution on TEST0001. INSERT INTO drafts(id, document_number, account_id, create_ts, registration_type_cl, registration_type, registration_number, update_ts, draft) VALUES(200000014, 'D-T-0010...
<reponame>llsand/orcas<gh_stars>10-100 define column domain pk_column generate-primary-key (constraint-name(alias-name || "_PK") sequence-name(alias-name || "_seq")) ( number(15) not null );
<reponame>inaand/compass BEGIN; ------------------ New Types -------------------------------- CREATE TYPE vendor_type AS ENUM ('sap', 'sap-partner','client_registration'); CREATE TABLE vendors ( ord_id VARCHAR(256) PRIMARY KEY, tenant_id UUID NOT NULL, app_id UUID NOT NULL, FORE...
-- Ergänze die Verbreitung bei Rüstungen, Waffen, Schilden UPDATE Ausrüstung_Setting SET [Verbreitung] = '(6) FIR, THO, GAR (nur Trollzacken)' WHERE [AusrüstungGUID] = '00000000-0000-0000-0001-000000000008' AND [SettingGUID] = '00000000-0000-0000-5e77-000000000004'; GO UPDATE Ausrüstung_Setting SET [Verbreitung] ...
DROP VIEW IF EXISTS view_beban_barang3_min_tariwin CASCADE; CREATE VIEW view_beban_barang3_min_tariwin AS SELECT *, CASE WHEN id_jenis_transaksi = 1 AND pra_saldo < 0 THEN jumlah WHEN id_jenis_transaksi = 1 AND pra_saldo < jumlah THEN (jumlah - pra_saldo) ELSE 0 END AS beban FROM view_persediaan_barang2...
<gh_stars>0 CREATE TABLE "xauth_protocolBufferCached"( "id" INTEGER PRIMARY KEY NOT NULL, "clientApiName" VARCHAR(255) NOT NULL, "clientApiHashedKey" VARCHAR(255) NOT NULL, "userToken" VARCHAR(5000) , "userInfoCached" VARCHAR(255), "expiresOn" TIMESTAMP, "createdAt" TIMESTAMP NOT NULL DEFAULT CURRENT_TIME...
-- @testpoint: 创建行存表以及行存表B-tree索支持唯一索引 drop table if exists table_t3; CREATE TABLE table_t3 (SM_SK INTEGER NOT NULL, SM_id CHAR(16) NOT NULL, SM_TYPE CHAR(30) ); DROP INDEX if exists table_t3_index1; CREATE UNIQUE INDEX table_t3_index1 ON table_t3 using btree(SM_S...
DROP VIEW IF EXISTS oosumgly; CREATE VIEW oosumgly AS SELECT * FROM oosumvar WHERE assay = 'glyDRC'
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Erstellungszeit: 21. Feb 2016 um 19:20 -- Server-Version: 10.1.9-MariaDB -- PHP-Version: 5.6.15 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT...
<gh_stars>0 IF (UPPER('$(INSERT_TEST_DATA)') = 'TRUE') BEGIN /*********************************************************************************************************************************************/ /* AdditionalService */ /*****************************************************************************...
<reponame>mfranzil/unitn-db INSERT INTO countries VALUES (1, 'A', 10); INSERT INTO spies VALUES (1, '007', 1), (2, '008', 1), (3, '009', 1) ; INSERT INTO secret_agencies VALUES (1, 'Q', 1); INSERT INTO missions VALUES (1, 'aaa', 'A_1', 'A_2', 0, 1, true), (2, 'bbb', 'B_1', 'B_2', 0, 1, true), ...
-- Adminer 4.2.5 MySQL dump SET NAMES utf8; SET time_zone = '+00:00'; SET foreign_key_checks = 0; SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO'; DROP TABLE IF EXISTS `buku`; CREATE TABLE `buku` ( `no_buku` varchar(191) NOT NULL, `judul_buku` varchar(191) NOT NULL, `pengarang` varchar(191) NOT NULL, `kategori` varcha...
-- MySQL dump 10.13 Distrib 8.0.17, for Linux (x86_64) -- -- Host: localhost Database: library -- ------------------------------------------------------ -- Server version 8.0.17 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!...
-- overwrite intersection table DROP TABLE IF EXISTS eez_mpas CASCADE; CREATE TABLE eez_mpas AS SELECT m.mpa_id, e.fid AS eez_fid, CASE WHEN ST_CoveredBy(m.geog, e.geom) THEN m.geog ELSE ST_Multi(ST_Intersection(m.geog, e.geom)) END AS geom FROM mpa_mpa AS m INNER JOIN eez AS e ON ( ...
-- phpMyAdmin SQL Dump -- version 4.9.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 17 Des 2020 pada 10.53 -- Versi server: 10.4.8-MariaDB -- Versi PHP: 7.3.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARA...
USE [master] GO IF EXISTS (SELECT name FROM master.dbo.sysdatabases WHERE name = N'1-Marketing') DROP DATABASE [1-Marketing] GO IF EXISTS (SELECT name FROM master.dbo.sysdatabases WHERE name = N'1-Sales') DROP DATABASE [1-Sales] GO IF EXISTS (SELECT name FROM master.dbo.sysdatabases WHERE name = N'1-Warehouse') DROP...
<gh_stars>10-100 -- file:tstypes.sql ln:182 expect:true SELECT ts_rank_cd(' a:1 sa:2A sb:2D g'::tsvector, 'a <-> s:* <-> sa:B')
set serveroutput on size unlimited verify off timing off feedback off linesize 32000 pagesize 0 heading off long 2000000 autotrace off newpage none termout on trimspool on PROMPT Saving DDL for role &1 into &2 set termout off define file_name='&2' column file_name new_value file_name column rolename new_value rolen...
<filename>sql/update/20190213.sql -- 适配vnet,修正限速字段,默认限速为10M ALTER TABLE `user` CHANGE COLUMN `speed_limit_per_con` `speed_limit_per_con` BIGINT NOT NULL DEFAULT '10737418240' COMMENT '单连接限速,默认10G,为0表示不限速,单位Byte' AFTER `obfs_param`, CHANGE COLUMN `speed_limit_per_user` `speed_limit_per_user` BIGINT NOT NULL DEFAULT '1...
<filename>hasura/migrations/default/1633264955403_alter_table_public_default_royalty_recipients_drop_column_artwork_id/down.sql<gh_stars>10-100 alter table "public"."default_royalty_recipients" alter column "artwork_id" drop not null; alter table "public"."default_royalty_recipients" add column "artwork_id" uuid;
-- Phase 1 create animals table INSERT INTO animals ( name, date_of_birth, escape_attempts, neutered, weight_kg ) VALUES ('Agumon', '02/03/2020', 0, TRUE, 10.23); INSERT INTO animals ( name, date_of_birth, escape_attempts, neutered, weight_kg ) VALUES ('Gabumon', '11/15/201...
-- 2017-10-25T15:53:35.307 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator UPDATE AD_UI_Element SET AD_UI_ElementGroup_ID=540301, SeqNo=40,Updated=TO_TIMESTAMP('2017-10-25 15:53:35','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_UI_Element_ID=543326 ; -- 2017-10-25T15:53:45.043 -- I forgot to set th...
<reponame>truthiswill/usaspending-api CREATE EXTENSION postgres_fdw; CREATE EXTENSION dblink; CREATE SERVER <server name> FOREIGN DATA WRAPPER postgres_fdw OPTIONS (host '<host>', port '<port>', dbname '<database name>'); -- Use `select inet_server_addr();` on broker database to get private IP CREATE...
<reponame>maransowthri/sql -- For both CREATE DATABASE talently; CREATE DATABASE flipkart; CREATE DATABASE sales; CREATE DATABASE relations;
<reponame>pando160/Deividcoptero-SQLSERVER --Video 58 Procedimientos Almacenados [Parametros Salida] --create procedure NombreProcedimiento --@parametro tipo output --as --sentencia create procedure seleccion--Nombre Procedimiento @edad int, --Parametros Entrada @sexo varchar(20), --Parametros Entrada @...
<gh_stars>1-10 ALTER TABLE mst.adjustment_data ADD payment_operation_failure_class mst.failure_class; ALTER TABLE mst.adjustment_data ADD payment_external_failure character varying; ALTER TABLE mst.adjustment_data ADD payment_external_failure_reason character varying;
/* add_websites_2011_12.sql is a MySQL script intended to add OpenLibrary, Google Books, LibraryThing, Shelfari, GoodReads, Deutsche Nationalbibliothek, European Library and COPAC to the "Other Sites" section of the Publication display page. Version: $Revision$ Date: $Date$ (C) COPYRI...
CREATE TABLE exec_results ( id INT AUTO_INCREMENT NOT NULL COMMENT 'ID', command_id INT NOT NULL COMMENT 'コマンド ID', trigger_id INT NOT NULL COMMENT 'トリガー ID', exec_time DATETIME NOT NULL COMMENT '実行時間', response_code INT NOT NULL COMMENT 'レスポンス code', response_header TEXT NOT NULL COMMENT 'レスポンス...
<filename>database/u891156230_iDocument.20200819171610.sql -- MariaDB dump 10.17 Distrib 10.4.13-MariaDB, for Linux (x86_64) -- -- Host: localhost Database: u891156230_iDocument -- ------------------------------------------------------ -- Server version 10.4.13-MariaDB /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHAR...
create database dbmercadosp; use dbmercadosp; create table carrinho ( id int primary key auto_increment, produto varchar(100) not null, quantidade int not null, valor decimal(10,2) not null ); insert into carrinho(produto,quantidade,valor) values ('Cenoura','3','60'); insert into carrinho(produto,quantidade,valo...
CREATE TABLE [dbo].[PrePaid] ( [B_ID] INT NOT NULL PRIMARY KEY, [Balance] MONEY NULL, CONSTRAINT FK_PrePaidISABilling Foreign Key (B_ID) REFERENCES Billing(B_ID) )
<filename>Scripts/QuestIcon.sql ALTER TABLE quests ADD COLUMN icon_name; UPDATE quests SET icon_name = 'Quest-Icon-White.png'; UPDATE quests SET icon_name = (SELECT items.icon_name FROM items WHERE quests.goal LIKE '%'||items.name||'%') WHERE quests.icon_name IS NULL OR EXISTS (SELECT items.icon_name FROM items WHERE ...
<reponame>PatrickCmd/Microservice_architecture_flask_docker CREATE DATABASE users_prod; CREATE DATABASE users_stage; CREATE DATABASE users_dev; CREATE DATABASE users_test;
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Dec 08, 2020 at 08:34 AM -- 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...
<filename>src/main/resources/db/migration/V002__earthdistance.sql CREATE EXTENSION IF NOT EXISTS cube WITH SCHEMA public; CREATE EXTENSION IF NOT EXISTS earthdistance WITH SCHEMA public;
<reponame>righthan/policy_diffusion<filename>_not_in_use/input/legislators.sql<gh_stars>10-100 DROP TABLE IF EXISTS legislators; CREATE TABLE legislators ( id VARCHAR, votesmart_id VARCHAR, transparencydata_id VARCHAR, first_name VARCHAR, middle_name VARCHAR, last_name VARCHAR, suffixes VARCHAR, full_name VAR...
<reponame>Shuttl-Tech/antlr_psql -- file:date.sql ln:348 expect:true select make_time(24, 0, 2.1)
<gh_stars>1000+ -- 23.11.2016 13:17:03 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,AllowZoomTo,ColumnName,Created,CreatedBy,EntityType,FieldLength,IsActive,IsAdvancedText,IsAllowLogging,IsAlwaysUp...
-- 2191 Number of total persons that have at least x measurements --HINT DISTRIBUTE_ON_KEY(stratum_1) SELECT 2191 AS analysis_id, CAST(d.device_concept_id AS VARCHAR(255)) AS stratum_1, CAST(d.device_count AS VARCHAR(255)) AS stratum_2, CAST(NULL AS VARCHAR(255)) AS stratum_3, CAST(NULL AS VARCHAR(255)) AS strat...
<reponame>jt120/spring-demo<filename>jdbc/target/test-classes/schema.sql CREATE TABLE t_user(ID INT PRIMARY KEY, NAME VARCHAR(255));
<reponame>juanrh/bicing-bcn UPSERT INTO BICING_DIM_STATION VALUES (1, 2.18004200, 41.3979520, 21, 'Eixample', 'El Fort Pienc', '08013', 'Gran Via Corts Catalanes 760', 35678.34, 266874, 7.48); UPSERT INTO BICING_DIM_STATION VALUES (2, 2.17516900, 41.3942720, 21, 'Eixample', 'Dreta de l"Eixample', '08010', 'Plaza Tetu&a...
/* Navicat Premium Data Transfer Source Server : MySQL Source Server Type : MySQL Source Server Version : 50716 Source Host : 127.0.0.1:3306 Source Schema : snack Target Server Type : MySQL Target Server Version : 50716 File Encoding : 65001 Date: 18/10/...
<gh_stars>100-1000 ALTER TABLE plan ADD record_enabled boolean NOT NULL DEFAULT FALSE;
<reponame>lulzzz/tellma CREATE TYPE [dbo].[ValidationErrorList] AS TABLE ( [Key] NVARCHAR (255), [ErrorName] NVARCHAR (255), [Argument0] NVARCHAR (255), [Argument1] NVARCHAR (255), [Argument2] NVARCHAR (255), [Argument3] NVARCHAR (255), [Argument4] NVARCHAR (255) PRIMARY KEY ([Key], [ErrorName]) )
CREATE DATABASE IF NOT EXISTS `pcndb` /*!40100 DEFAULT CHARACTER SET utf8 */; USE `pcndb`; -- MySQL dump 10.13 Distrib 5.6.17, for Win64 (x86_64) -- -- Host: localhost Database: pcndb -- ------------------------------------------------------ -- Server version 5.6.17 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARAC...
CREATE TABLE ramstk_revision ( fld_revision_id INTEGER NOT NULL, fld_availability_logistics FLOAT DEFAULT 1.0, fld_availability_mission FLOAT DEFAULT 1.0, fld_cost FLOAT DEFAULT 0.0, fld_cost_failure FLOAT DEFAULT 0.0, fld_cost_hour FLOAT DEFAULT 0.0, fld_hazard_rate_active FLOAT DEFAULT 0.0...
<reponame>matthew-n/fluca1978-pg-utils CREATE OR REPLACE VIEW vw_magtitles AS SELECT title, download_path FROM magazine ORDER BY issuedon;
--alter table rbm_user add column userobjects int8[]; --select x.* from rbm_user x --alter table rbm_user add column usrrole int2 not null default 0 --drop table rbm_usr_items --create table rbm_usr_items ( -- usrid int4, -- asib varchar(32), -- itemid varchar(32) --) --alter table rbm_usr_items alter column ite...
CREATE VIEW V_EmployeesHiredAfter2000 AS SELECT e.FirstName, e.LastName FROM Employees AS e WHERE YEAR(e.HireDate) > 2000
DROP TABLE IF EXISTS fact; CREATE TABLE fact ( id SERIAL PRIMARY KEY, type VARCHAR(255), text VARCHAR(1000000) );
-- Multi-Table Query Practice -- Display the ProductName and CategoryName for all products in the database. Shows 77 records. SELECT p.ProductName , c.CategoryName FROM Product as p JOIN Category as c ON p.CategoryId = c.Id; -- Display the order Id and shipper CompanyName for all orders placed before A...
select (1 - (sum(decode(name, 'physical reads', value,0)) / (sum(decode(name, 'db block gets',value,0)) + sum(decode(name, 'consistent gets',value,0))))) * 100 "Hit Ratio" from v$sysstat /
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Oct 08, 2018 at 11:55 AM -- Server version: 10.1.16-MariaDB -- PHP Version: 5.6.24 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CL...
<reponame>ucdavis/CRP<gh_stars>0  CREATE VIEW [dbo].[vUsers2] AS SELECT Users.UserID AS id, Users.LoginID, Users.Email, Users.Phone, Users.FirstName, Users.LastName, Users.EmployeeID, Users.SID, Users.UserKey, dbo.vActiveUsersForCrp.UserID AS ActiveUserId FROM ...
<gh_stars>0 create or replace function update_parse_report(job_id integer, last_update json) returns json as $$ declare job record; begin update data.jobs as j set last_error = $2 where j.id = $1 returning * into job; return json_build_object( 'id', job.id ); end $$ security de...
<reponame>michaelwehrley/notes -- test.sql -- for PostgreSQL -- prepared by <NAME> -- for lynda.com course PostgreSQL 9 Essential Training -- version 1.4 2011-09-28 SET ROLE web; -- create views for listing tables and databases DROP VIEW IF EXISTS view_tables; DROP VIEW IF EXISTS view_databases; DROP VIEW IF EXISTS v...