sql
stringlengths
6
1.05M
-- file:rolenames.sql ln:218 expect:true set client_min_messages to error
<filename>pgsmo/objects/table_objects/rule/+default/properties.sql {# =================== Fetch Rules ==================== #} {% if tid or rid %} SELECT rw.oid AS oid, rw.rulename AS name, relname AS view, CASE WHEN relkind = 'r' THEN TRUE ELSE FALSE END AS parentistable, nspname AS schema, desc...
create view "postgres"._airbyte_test_normalization."renamed_dedup_cdc_excluded_ab2__dbt_tmp" as ( -- SQL model to cast each column to its adequate SQL type converted from the JSON schema type select cast("id" as bigint ) as "id", _airbyte_ab_id, _airbyte_emitted_at, now() as _airbyte_normal...
INSERT INTO item_template (entry, class, subclass, unk0, name, displayid, Quality, Flags, BuyCount, BuyPrice, SellPrice, InventoryType, AllowableClass, AllowableRace, ItemLevel, RequiredLevel, RequiredSkill, RequiredSkillRank, requiredspell, requiredhonorrank, RequiredCityRank, RequiredReputationFaction, RequiredReputa...
<reponame>dssg/predicting_student_enrollment_public SELECT * FROM K12INTEL_DW.DSSG_SCHOOL_AGGREGATE_FEATURES_VW
<reponame>sky3936/muushop<filename>Application/Devtool/Info/cleanData.sql SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00";
<reponame>sinosdx/SINO-APIX -- -- Copyright © 2022 SinoSDX (<EMAIL>) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless requ...
<reponame>Priyesh1994/My-twitter -- phpMyAdmin SQL Dump -- version 4.1.14 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Jan 23, 2017 at 12:15 PM -- Server version: 5.6.17 -- PHP Version: 5.5.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_...
/*L Copyright SAIC Distributed under the OSI-approved BSD 3-Clause License. See http://ncip.github.com/cabio/LICENSE.txt for details. L*/ alter table ZSTG_MICROSATELLITE enable constraint SYS_C005018; alter table ZSTG_MICROSATELLITE enable constraint SYS_C005019; alter table ZSTG_MICROSATELLITE enab...
<filename>sak.sql -- phpMyAdmin SQL Dump -- version 4.9.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: May 22, 2020 at 07:26 AM -- Server version: 10.4.6-MariaDB -- PHP Version: 7.3.9 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; ...
/* Navicat MySQL Data Transfer Source Server : localhost Source Server Version : 50505 Source Host : localhost:3306 Source Database : blue_flower Target Server Type : MYSQL Target Server Version : 50505 File Encoding : 65001 Date: 2019-12-04 15:07:53 */ SET FOREIGN_KEY_CHECKS=0; ...
CREATE OR REPLACE FUNCTION check_uniques_of_appointment_func() RETURNS TRIGGER LANGUAGE plpgsql AS $check_uniques_appointment$ DECLARE error_message VARCHAR(255); BEGIN SELECT concat( 'Patient: ', New.patient_id::VARCHAR, ' cant have an appointment with docto...
-- MySQL dump 10.13 Distrib 5.7.17, for Win64 (x86_64) -- -- Host: 127.0.0.1 Database: saeingressos -- ------------------------------------------------------ -- Server version 5.5.5-10.1.19-MariaDB /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER...
<filename>app/models/users.sql CREATE TABLE IF NOT EXISTS users( uname varchar(20) NOT NULL, name varchar(30), password varchar(30) NOT NULL, PRIMARY KEY (uname) ); SELECT * from users;
<filename>migrations/2021-12-15-162002_create_binance_open_interest_summaries_view_1d/up.sql CREATE VIEW binance_open_interest_summaries_view_1d AS SELECT symbol, timestamp::DATE AS date, sum_open_interest, sum_open_interest_value FROM binance_open_interest_summaries_view WHERE inter...
DROP TABLE IF EXISTS relations; CREATE TABLE relations (id INTEGER,version INTEGER,changeset INTEGER,user VARCHAR(150),uid INTEGER,visible TINYINT(2),date_time VARCHAR(150),CONSTRAINT relations_pk PRIMARY KEY(id)); INSERT INTO relations (id, version, changeset, user, uid, visible, date_time) VALUES ("56688","28","69476...
<gh_stars>1-10 -- TRUNCATE person CASCADE; -- TRUNCATE company CASCADE; INSERT INTO company VALUES (1, 'Company_1'), (2, 'Company_2'), (3, 'Company_3'), (4, 'Company_4'), (5, 'Company_5'), (6, 'Company_6'), (7, 'Company_7'); INSERT INTO person VALUES (1, 'Person_1', 1), ...
create table [dbo].Categories ( Id tinyint not null primary key, [Name] nvarchar(200) not null );
SET client_min_messages TO warning; CREATE EXTENSION IF NOT EXISTS pgtap; RESET client_min_messages; BEGIN; SELECT no_plan(); --SELECT plan(1); SET search_path TO app_public,public; SELECT pass('Test confirm_account_deletion!'); INSERT INTO app_public.users (username,name) VALUES ('jmarca', '<NAME>'); INSERT INTO...
CREATE TABLE groups ( id SERIAL PRIMARY KEY NOT NULL, name TEXT NOT NULL, description TEXT NOT NULL, admin SERIAL, FOREIGN KEY (admin) REFERENCES users (id) ON DELETE SET NULL ); INSERT INTO groups (name, description, admin) values ('Футбол', 'Все о ...
ALTER TABLE "users" ADD "firstname" VARCHAR NOT NULL DEFAULT ''; ALTER TABLE "users" ADD "lastname" VARCHAR NOT NULL DEFAULT '';
-- MySQL dump 10.14 Distrib 5.5.47-MariaDB, for Linux (x86_64) -- -- Host: localhost Database: ops -- ------------------------------------------------------ -- Server version 5.5.47-MariaDB /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RES...
<reponame>calvinwilliams/sqlaction CREATE TABLE "user_base" ( id integer NOT NULL, name character varying(45) NOT NULL, gender character varying(3) NOT NULL, age smallint NOT NULL, address character varying(100) NOT NULL, lvl integer NOT NULL, CONSTRAINT user_base_pkey PRIMARY KEY (id) ); CR...
<reponame>faizol/babelfish_extensions -- note: the default typmod for varchar should be 1 CREATE FUNCTION babel_1000_test1 (@arg1 varchar) RETURNS TABLE AS RETURN (SELECT @arg1 as a) GO SELECT * FROM babel_1000_test1('babel_1000_varchar') GO CREATE FUNCTION babel_1000_test2 (@arg1 varchar(10), @arg2 varchar(20)) RETUR...
<filename>yayasan (1).sql -- phpMyAdmin SQL Dump -- version 5.1.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jun 17, 2021 at 05:03 AM -- Server version: 10.4.19-MariaDB -- PHP Version: 8.0.7 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SE...
<filename>openGaussBase/testcase/KEYWORDS/Constructor/Opengauss_Function_Keyword_Constructor_Case0031.sql -- @testpoint:opengauss关键字constructor(非保留),作为字段数据类型(合理报错) --前置条件 drop table if exists constructor_test cascade; --关键字不带引号-合理报错 create table constructor_test(id int,name constructor); --关键字带双引号-合理报错 create table...
USE [Analytics_WS] GO IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'dbo.fn_getVintageDate') AND type IN ( N'FN', N'IF', N'TF', N'FS', N'FT' )) DROP FUNCTION dbo.fn_getVintageDate GO CREATE FUNCTION [dbo].fn_getVintageDate ( @date DATE, @endD...
/* Copyright ©2020-2021 WellEngineered.us, all rights reserved. Distributed under the MIT license: http://www.opensource.org/licenses/mit-license.php */ -- server SELECT SERVERPROPERTY('ServerName') AS [ServerName], SERVERPROPERTY('MachineName') AS [MachineName], SERVERPROPERTY('InstanceName') AS [Insta...
<reponame>karkipsn/user-management_system<filename>sql.sql CREATE TABLE IF NOT EXISTS `users` ( `user_id` int(11) NOT NULL AUTO_INCREMENT, `first_name` varchar(15) NOT NULL, `last_name` varchar(15) NOT NULL, `user_email` varchar(40) NOT NULL, `user_pass` varchar(255) NOT NULL, `joining_date` timestamp NOT...
SET DEFINE OFF; ALTER TABLE AFW_21_PLUGN_MENU ADD ( CONSTRAINT AFW_21_PLUGN_MENU_FK3 FOREIGN KEY (REF_DV_COULR_PRINC) REFERENCES AFW_14_DETL_DOMN_VALR (SEQNC) ENABLE VALIDATE) /
SELECT CNCT_I AS tanks FROM MNFLD.dbo.wmgma01_cnct_pt WHERE CNCT_I LIKE ('____')
-- phpMyAdmin SQL Dump -- version 3.5.8.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Jan 08, 2014 at 11:22 PM -- Server version: 5.6.11-log -- PHP Version: 5.4.14 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT ...
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0; SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0; SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES'; CREATE TABLE `sat_unit_of_measurement` ( `sat_unit_of_measurement_id` varchar(3) NOT NULL, `name` varchar(128) N...
<filename>src/main/resources/db/migration/V1_45__drop_holding_details_not_null.sql ALTER TABLE holding_details ALTER COLUMN symbol DROP NOT NULL; ALTER TABLE holding_details ALTER COLUMN country DROP NOT NULL; ALTER TABLE holding_details ALTER COLUMN currency DROP NOT NULL; ALTER TABLE holding_details ALTER COLUMN sect...
-- Womens's specific services are not stored as a separate service category delete from service_category where id ='c519b07a-f3b1-42aa-ad80-78828b72c14e';
USE ColonialJourney ---02.Insert--- INSERT INTO Planets (Name) VALUES ('Mars'), ('Earth'), ('Jupiter'), ('Saturn') INSERT INTO Spaceships (Name, Manufacturer, LightSpeedRate) VALUES ('Golf', 'VW', 3), ('WakaWaka', 'Wakanda', 4), ('Falcon9', 'SpaceX', 1), ('Bed', 'Vidolov', 6) ---03.Update--- UPDATE Spa...
# --- !Ups CREATE TABLE organization ( org_id SERIAL NOT NULL, org_name TEXT NOT NULL, org_description TEXT NOT NULL, PRIMARY KEY (org_id) ); CREATE TABLE user_org ( user_org_id SERIAL NOT NULL, user_id TEXT NOT NULL, org_id INTEGER NOT NULL, PRIMARY KEY (user_org_id), FOREIGN KEY (...
<gh_stars>10-100 -- file:jsonb.sql ln:414 expect:true select jsonb_object('{a,b,c,"d e f",g}','{1,2,3,"a b c"}')
ALTER TABLE `webshops` ADD COLUMN `domainUri` varchar(100) NULL COMMENT '';
<filename>cheatsheets/sql/sqlserver.dw.sql SELECT <column(s)> FROM <fact_table> JOIN <dim_table> ON <condition(s)> WHERE <source_filter_condition> GROUP BY <dim_table_column(s)> HAVING <result_filter_condition> ORDER BY <source_or_result_column(s)> SELECT S.[SalesAmount] AS [Sales] FROM [FactReselle...
<reponame>The-Academic-Observatory/query-auditing<filename>superQuery/bianca.kramer@gmail.com/oa_query_audit/preprints.sql SELECT year, COUNT(doi) AS doi, COUNTIF(is_oa is TRUE) AS is_oa, COUNTIF(best_oa_location.host_type = "publisher") AS publisher, COUNTIF(best_oa_location.host_type = "repository") AS repo...
<reponame>onap/vfc-nfvo-resmanagement<filename>ResmanagementService/deployment/src/main/release/db/mysql/db-schema.sql #******************************************************************************* # Copyright 2016-2017 Huawei Technologies Co., Ltd. # # Licensed under the Apache License, Version 2.0 (the "License"); ...
<reponame>ShunichirouKamino/doma select * from EMPLOYEE where HIREDATE = /*hiredate*/'2000-01-01'
create table "schemahero.users" (id int, login varchar, name varchar, primary key (id));
<reponame>localhost-developer/amplication -- AlterEnum ALTER TYPE "EnumDataType" ADD VALUE 'Json';
<reponame>muntaza/catatan_openpersediaan_banjarbaru 1053,145,6000 13765,5,49000 13762,10,50000 3267,24,189950 2246,286,24500 2973,25,99000 2973,21,90000 13761,200,33000 8348,19,25000 2000,10,125000 1858,8,90000 2041,2,175000 14961,4,175000 3217,4,175000 14037,1,2095000 13196,44,240000 13195,103,156000 13236,5,242250 13...
DROP TABLE if exists gpi_pwj_table1; DROP TABLE if exists gpi_pwj_table2; CREATE TABLE gpi_pwj_table1 ( c1 int, c2 int, c3 int ) partition by range (c1) ( partition p0_gpi_pwj_table1 VALUES less than (10000), partition p1_gpi_pwj_table1 VALUES less than (20000), partition p2_gpi_pwj_table1 VALU...
<filename>user.sql -- MySQL dump 10.13 Distrib 8.0.19, for Win64 (x86_64) -- -- Host: localhost Database: user_system -- ------------------------------------------------------ -- Server version 8.0.19 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@...
<filename>giaoduc24h.sql<gh_stars>0 -- MySQL dump 10.13 Distrib 5.7.19, for Linux (x86_64) -- -- Host: localhost Database: giaoduc24h -- ------------------------------------------------------ -- Server version 5.7.19-0ubuntu0.17.04.1 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @O...
<filename>sql/yjbb/600807.sql<gh_stars>0 EXEC [EST].[Proc_yjbb_Ins] @Code = N'600807',@CutoffDate = N'2017-09-30',@EPS = N'0.11',@EPSDeduct = N'0',@Revenue = N'13.97亿',@RevenueYoy = N'15.07',@RevenueQoq = N'22.43',@Profit = N'9415.03万',@ProfitYoy = N'8.10',@ProfiltQoq = N'-54.16',@NAVPerUnit = N'2.3379',@ROE = N'4.85',...
ALTER TABLE `users` CHANGE `image` `logo` varchar(255) COLLATE 'utf8mb4_unicode_ci' NULL AFTER `about_business`; ALTER TABLE `users` ADD `image1` varchar(255) COLLATE 'utf8mb4_unicode_ci' NULL AFTER `logo`, ADD `image2` varchar(255) COLLATE 'utf8mb4_unicode_ci' NULL AFTER `image1`, ADD `image3` varchar(255) COLLATE 'u...
<reponame>noppGithub/line_test create database testdb; \c testdb ; CREATE TABLE IF NOT EXISTS public.order_detail ( order_created_timestamp timestamp, status varchar, price integer, discount float, id varchar, driver_id varchar, user_id varchar, restaurant_id varchar ); CREATE TABLE IF...
CREATE TABLE monitor ( id SERIAL PRIMARY KEY, name VARCHAR(255) NOT NULL, url TEXT NOT NULL, uptime_check_interval INTEGER NOT NULL, enabled BOOLEAN NOT NULL DEFAULT ...
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 5.5.44-MariaDB-log - FreeBSD Ports -- Server OS: FreeBSD10.1 -- HeidiSQL Version: 9.3.0.4984 -- -------------------------------------------------------- ...
-- phpMyAdmin SQL Dump -- version 5.1.0 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 19 Agu 2021 pada 15.12 -- Versi server: 10.4.19-MariaDB -- Versi PHP: 8.0.6 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CH...
<filename>sql/set_avg_stats.sql @@stats_config @@logsetup set_avg_stats set timing on prompt prompt =========================================== prompt == Set Average stats for tables/indexes prompt == when rows == 0 prompt =========================================== prompt set echo on set serveroutput on size 1000...
alter table "public"."department_assignments" drop constraint "department_assignments_department_id_key";
-- H17B. TENURE BY AGE OF HOUSEHOLDER (BLACK OR AFRICAN AMERICAN ALONE HOUSEHOLDER) -- designed to work with the IRE Census bulk data exports -- see http://census.ire.org/data/bulkdata.html CREATE TABLE ire_h17b ( geoid VARCHAR(11) NOT NULL, sumlev VARCHAR(3) NOT NULL, state VARCHAR(2) NOT NULL, county VARCHAR(3...
CREATE TABLE IF NOT EXISTS `jobs_queue` ( `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT, `type` varchar(191) CHARACTER SET utf8 NOT NULL DEFAULT '', `channel` varchar(191) CHARACTER SET utf8 NOT NULL DEFAULT 'main', `batch_id` int(10) unsigned, `data` JSON NOT NULL, `available_at` datetime DE...
insert into growth_table (temp_project_finance_id, financial_year_end, annual_turnover, annual_profits, annual_export, research_and_development, employees) select pf.id as temp_project_finance_id, g.financial_year_end as financial_year_end, g.annual_t...
create database quickstart_values_controller; create role quickstart_values_controller with login nosuperuser nocreatedb nocreaterole noinherit noreplication connection limit -1 password '<PASSWORD>';
<filename>database/data/ref.mst_wilayah19.sql INSERT INTO ref.mst_wilayah VALUES ('241603AS', '<NAME>', 4, '241603 ', 'ID', NULL, NULL, NULL, NULL, '2015-07-30 22:00:00', '2016-07-22 06:00:00', NULL, '1901-01-01 00:00:00'); INSERT INTO ref.mst_wilayah VALUES ('241603AT', '<NAME>', 4, '241603 ', 'ID', NULL, NULL, NULL...
-- file:numeric.sql ln:816 expect:true INSERT INTO num_input_test(n1) VALUES ('-555.50')
-- Deploy file_checksum_insert_ignore -- requires: file_checksums -- requires: goiardi_schema BEGIN; CREATE RULE insert_ignore AS ON INSERT TO goiardi.file_checksums WHERE EXISTS(SELECT 1 FROM goiardi.file_checksums WHERE (organization_id, checksum)=(NEW.organization_id, NEW.checksum)) DO INSTEAD NOTHING; COMMI...
CREATE SEQUENCE IF NOT EXISTS pipeline.s_node_schedule START WITH 1 INCREMENT BY 1; CREATE TABLE IF NOT EXISTS pipeline.node_schedule ( id BIGINT PRIMARY KEY DEFAULT nextval('pipeline.s_node_schedule'), created_date TIMESTAMP WITH TIME ZONE NOT NULL, name TEXT ); CREATE TABLE IF NOT EXISTS pipeline.node_schedul...
<gh_stars>0 SELECT DISTINCT SNO FROM P, SPJ WHERE P.PNO = SPJ.PNO AND JNO = 'J1' AND COLOR = '红'; # => [('S1', 'S3')]
<gh_stars>0 -- @testpoint:openGauss关键字year(非保留),同时作为表名和列名带引号,与union结合查询合并两个SELECT 语句查询 drop table if exists "year" CASCADE; create table "year"( c_id int, c_int int, c_integer integer, c_bool int, c_boolean int, c_bigint integer, c_real real, c_double real, c_decimal decimal(38), c_number number(38), c_numeric num...
<reponame>nabeelkhan/Oracle-DBA-Life<filename>SCRIPTS/Free_spc.sql REM FILE NAME: free_spc.sql REM LOCATION: Object Management\Tablespaces and DataFiles\Reports REM FUNCTION: Provide data on tablespace extent status REM TESTED ON: 8.0.4.1, 8.1.5, 8.1.7, 9.0.1 REM PLATFORM: non-specific REM REQUIRES: free_spac...
<filename>app/esquema.sql CREATE TABLE IF NOT EXISTS sesiones( id VARCHAR(255) NOT NULL PRIMARY KEY, datos TEXT NOT NULL, ultimo_acceso BIGINT UNSIGNED NOT NULL ); create table usuarios( id bigint unsigned not null auto_increment, correo varchar(255) not null, palabra_secreta varchar(255) not null, prim...
<filename>psql/Web_Notes_postgres_create.sql<gh_stars>0 CREATE TABLE "Users" ( "user_id" serial NOT NULL, "email" TEXT NOT NULL UNIQUE, "password" TEXT NOT NULL, "role_id" integer NOT NULL DEFAULT '1', "is_active" BOOLEAN NOT NULL DEFAULT 'True', CONSTRAINT "Users_pk" PRIMARY KEY ("user_id") ) WITH ( OIDS=FALSE...
<reponame>matt-cross23/Employee-Tracker USE employee_db; -- Read Tables SELECT * FROM role -- Create rows INSERT INTO employee (first_name, last_name, role_id, manager_id) AT VALUES (?) -- Update Employee UPDATE employee -- Joins SELECT * FROM employee INNER JOIN role ON employee.department_id = role.id
create or replace function parse_pdf_table_gunma( P_MUNICIPALITY_CODE IN NUMBER DEFAULT 100005, P_URL IN VARCHAR2, P_CACHE IN NUMBER DEFAULT 1 ) return t_table pipelined as l_columns apex_t_varchar2; l_prev varchar2(1000); l_next varchar2(1000); l_line varchar2(1000); l_parsed varch...
create table if not exists b_sale_hdale( CODE varchar(100) NOT NULL, ID INT NOT NULL, NAME varchar(100) NOT NULL, PCITY varchar(100) NULL, PSUBREGION varchar(100) NULL, PREGION varchar(100) NULL, PCOUNTRY varchar(100) NULL, LOCATION_ID INT NULL, LOCATION_EXT_ID INT NULL, PRIMARY KEY (CODE), INDEX IX_BSHDALE_...
ALTER TABLE [dbo].[FIELD_EXCLUSION_COLLECTION] ADD CONSTRAINT [PK_FieldExclCollection] PRIMARY KEY (FieldName, Direction, WITypeMapId)
<filename>src/main/resources/db/migration/mysql/V00012__copiandoIcmsParaOsNcmsComVariasExcecoes.sql<gh_stars>1-10 -- Esse é para cadastrar as tributações dos outros ncms que tem mais de uma excecao -- Para as OPERAÇÕES (1,4, 46, 63, 73, 81, 83), que não foi cadastrados para todos o NCMS (mas o ICMS é igual para qualqu...
<filename>Chapter15/ABQ_Data_Entry/sql/populate_db.sql<gh_stars>100-1000 INSERT INTO lab_techs VALUES (4291, '<NAME>'), (4319, '<NAME>'), (4478, '<NAME>'), (5607, '<NAME>') ; INSERT INTO labs VALUES ('A'), ('B'), ('C'), ('D'), ('E'); INSERT INTO plots (SELECT labs.id, plotnums.plot FROM labs, ...
<reponame>obi-two/GameServer -- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 5.1.63-community - MySQL Community Server (GPL) -- Server OS: Win64 -- HeidiSQL version: 7.0.0.4053 -- Date/time: ...
CREATE TYPE new_room AS ( owner_id uuid, image_id uuid, title character varying(32), about character varying(1024) ); CREATE TABLE public.rooms ( id uuid DEFAULT public.gen_random_uuid() PRIMARY KEY, owner_id uuid references users not null, image_id uuid references images NULL, title character varying(2048) CO...
<reponame>Hadis-Hashemi/sql-challenge -- Exported from QuickDBD: https://www.quickdatabasediagrams.com/ CREATE TABLE "DEPARTMENTS" ( "dept_no" VARCHAR(30) NOT NULL, "dept_name" VARCHAR(30) NOT NULL, CONSTRAINT "pk_DEPARTMENTS" PRIMARY KEY ( "dept_no" ) ); CREATE TABLE "dept_emp" ( "em...
<gh_stars>1-10 alter table inventory add constraint unique_name_to_item unique (owner, item);
<gh_stars>1-10 GO PRINT N'Dropping FK_MemberUpload_Organisation...'; GO ALTER TABLE [PCS].[MemberUpload] DROP CONSTRAINT [FK_MemberUpload_Organisation]; GO PRINT N'Dropping FK_Producer_MemberUpload...'; GO ALTER TABLE [Producer].[Producer] DROP CONSTRAINT [FK_Producer_MemberUpload]; GO PRINT N'Dropping FK_Mem...
CREATE TABLE [dbo].[Table1] ( [C1] INT NOT NULL ); go CREATE TABLE [dbo].[Table2] ( [C1] INT NOT NULL ); go CREATE TABLE [dbo].[Table3] ( [C1] INT NOT NULL ); go CREATE TABLE [dbo].[Table4] ( [C1] INT NOT NULL ); go
<filename>tests/queries/0_stateless/01881_aggregate_functions_versioning.sql<gh_stars>1000+ DROP TABLE IF EXISTS test_table; CREATE TABLE test_table ( `col1` DateTime, `col2` Int64, `col3` AggregateFunction(sumMap, Tuple(Array(UInt8), Array(UInt8))) ) ENGINE = AggregatingMergeTree() ORDER BY (col1, col2); ...
<gh_stars>1-10 SELECT customer_num, customer_name, balance, credit_limit, rep_num, first_name || ' ' || last_name AS rep_name FROM customer JOIN rep USING (rep_num) -- no nat. join b/c of many dup attrs WHERE balance > credit_limit;
<reponame>bcgov/clus select foo.herd_name, foo.bc_habitat, min(cutseq.harvestyr) from (select herd_name, bc_habitat, wkb_geometry from bc_caribou_linework_v20200507_shp_core_matrix where herd_name in('Barkerville', 'Central_Selkirks','Columbia_North', 'Columbia_South', 'Groundhog', 'Narrow_Lake', 'North_Cariboo...
<gh_stars>0 -- start_ignore SET gp_create_table_random_default_distribution=off; -- end_ignore --start_ignore Drop table if exists sto_co_en_sp; --end_ignore Create table sto_co_en_sp (id SERIAL,a1 int ,a2 char(5) ,a3 text ) WITH (appendonly=true, orientation=column, compresstype=zlib) partition by list(a2) subpartit...
<gh_stars>1-10 CREATE TABLE IF NOT EXISTS subscriber ( id TEXT PRIMARY KEY, email TEXT UNIQUE NOT NULL, created INTEGER DEFAULT (strftime('%s', 'now')) );
-- -- summary of committee contributions to committees, by source -- select cmm.other_id as src_cmte_id, cm.cmte_nm as src_cmte_nm, cm.cmte_pty_affiliation as src_cmte_pty_affiliation, sum(cmm.transaction_amt) as total_amt, count(cmm.transaction_amt) as total_count from cmte_misc cmm joi...
SELECT SUM(city.population) FROM city INNER JOIN country ON city.countrycode=country.code WHERE country.continent='Asia';
SELECT COUNT(*) - ( SELECT COUNT(DISTINCT country_code) FROM `mountains_countries` AS mc ) AS country_count FROM `countries` AS c
<gh_stars>0 ------------------------------------------------------------------------------- -- -- Script: library_stats.sql -- Purpose: to report basic library cache statistics -- -- Copyright: (c) Ixora Pty Ltd -- Author: <NAME> -- -------------------------------------------------------------------------------...
CREATE TABLE irCMS_modules_irBlog_blog ( blogId serial, userId integer NOT NULL, active boolean NOT NULL DEFAULT false, releaseDate timestamp with time zone DEFAULT now(), title text NOT NULL, subtitle text, content text, views integer NOT NULL DEFAU...
<gh_stars>1-10 -- ============================================= -- Author: (<EMAIL>is AG; <NAME>) -- Create date: 2014-06-25 -- Description: Returns Packackes in Queue for Job with executionID @JobExecutionID -- that have Constraining Package that are not successfully finished. -- -- Constrains where the Constraini...
CREATE TABLE [dbo].[ChangeLog] ( [ID] INT NOT NULL, [RequestID] INT NULL, [When] DATETIME NULL, [StatusCode] VARCHAR (50) NULL, [Message] VARCHAR (MAX) NULL, [TagData] VARCHAR (MAX) NULL, [ConfigFrom] VARCHAR (MAX) NULL, [ConfigTo] ...
<reponame>ryanmaclean/treasure-boxes -- client: molehill/0.0.1 select train.age_mean as age_mean_train , train.age_std as age_std_train , train.age_min as age_min_train , train.age_25 as age_25_train , train.age_median as age_median_train , train.age_75 as age_75_train , train.age_max as age_max_train ,...
<filename>src/test/resources/sql/create_publication/1767a50d.sql -- file:publication.sql ln:9 expect:true CREATE PUBLICATION testpub_default
<gh_stars>0 SELECT customer.id FROM offer_customer INNER JOIN customer ON offer_customer.customer_id = customer.id INNER JOIN address ON customer.invoice_address_id = address.id INNER JOIN sale ON offer_customer.id = sale.offer_customer_id INNER JOIN offer ON offer_customer.offer_id = offer.id INNER JOIN product ON of...
create table dependents( name varchar(20) not null not default, depname varchar(15) not null not default, birth ingresdate not null not default ) with noduplicates, nojournaling, page_size = 8192, location = (ii_database), security_audit=(table,norow) ; \p\g modify dependents to btree on name, depname with nonlea...
INSERT INTO chanx_manage.emp_number (`number`) VALUES (11) ;
<gh_stars>10-100 UPDATE feeds SET tier = 360 WHERE tier > 360;