sql
stringlengths
6
1.05M
create table ORDER_CUSTOMER ( CUSTOMER_ID BIGINT not null, STAFF_ID BIGINT not null, primary key (CUSTOMER_ID, STAFF_ID), constraint customer_id_constraint foreign key (CUSTOMER_ID) references STAFF, constraint staff_id_constraint foreign key (STAFF_ID) references CUSTOMER );
ALTER TABLE `m_prj_customize_view` CHANGE COLUMN `displayStandup` `displayFile` BIT(1) NOT NULL ;
<reponame>postgresqlacademy/pwaf<gh_stars>1-10 -- DO $body$ BEGIN IF NOT pwaf.build_utils_check_table_exists('pwaf', 'security_users') THEN CREATE TABLE pwaf.security_users ( id pwaf.g_serial NOT NULL, user_name text NOT NULL, auth_type_id integer NOT NULL, password text, salt text DEFAULT pwa...
<reponame>antonraharja/playvoip -- MySQL dump 10.9 -- -- Host: localhost Database: voiprakyat_asterisk -- ------------------------------------------------------ -- Server version 4.1.11-Debian_4sarge2-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHA...
-- Drops the madlibs_db if it exists currently -- DROP DATABASE IF EXISTS madlibs_db; -- Creates the "madlibs_db" database -- CREATE DATABASE madlibs_db;
/****** Object: StoredProcedure [AddB12Level111111] ******/ IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[AddB12Level111111]') AND type in (N'P', N'PC')) DROP PROCEDURE [AddB12Level111111] GO CREATE PROCEDURE [AddB12Level111111] @Level_1_1_1_1_1_1_ID int OUTPUT, @Level_1_1_1_1...
<filename>beta2/administrator/components/com_admin/sql/updates/mysql/1.7.1-2011-09-17.sql ALTER TABLE `#__modules` CHANGE `position` `position` VARCHAR( 50 ) NOT NULL DEFAULT '';
<reponame>kevchant/AzureDevOps-AzureSynapseSQLPool<filename>dbo/Tables/Tablea.sql CREATE TABLE [dbo].[Tablea] ( [col1] INT NOT NULL, [col2] VARCHAR (10) NULL ) WITH (CLUSTERED COLUMNSTORE INDEX); GO GO
<filename>src/test/resources/sql/insert/e6feff4d.sql<gh_stars>10-100 -- file:rules.sql ln:462 expect:true insert into rtest_view3 select * from rtest_vview1 where a < 7
<filename>DBADashDB/dbo/Views/JobStats_RAW.sql<gh_stars>10-100 CREATE VIEW dbo.JobStats_RAW AS SELECT jh.InstanceID, jh.job_id, jh.step_id, RunDateTime, SUM(CASE WHEN run_status IN(0,3) THEN 1 ELSE 0 END) as FailedCount, SUM(CASE WHEN run_status=1 THEN 1 ELSE 0 END) as SucceededCount, ISNULL(SUM(retries_attempte...
/**************** CREAR LA BASE DE DATOS ****************/ DROP DATABASE IF EXISTS practifp; CREATE DATABASE practifp; USE practifp; /* Creacion tabla centros_educativos */ DROP TABLE IF EXISTS centros_educativos; CREATE TABLE centros_educativos ( id_centro int(6) unsigned NOT NULL AUTO_INCREMENT, cod...
<gh_stars>0 CREATE TABLE [dbo].[EClearanceGaugeChanges] ( --From MergedXSDs XSD --From 'genericRailML' Namespace [EClearanceGaugeChangesId] BIGINT NOT NULL, [ClearanceGaugeChange] SMALLINT NOT NULL, CONSTRAINT [PK_EClearanceGaugeChangesId] PRIMARY KEY CLUSTERED ([EClearanceGaugeChangesId] ASC), CONSTRAINT [FK...
<filename>script/ControllerFileUpdateShell/UpdateSchema/MSF2017_to_MSF2018B.sql CREATE TABLE dummy_vlan_ifs_info ( node_id text NOT NULL, vlan_if_id text NOT NULL, vlan_id text NOT NULL, irb_insta...
/****** Object: View [dbo].[V_DatasetDetails] ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO /****** Object: View dbo.V_DatasetDetails ******/ /****** Object: View dbo.V_DatasetDetails Script Date: 1/17/2001 2:15:34 PM ******/ CREATE VIEW [dbo].[V_DatasetDetails] AS SELECT...
-------------------------------------- UP -------------------------------------- CREATE ROLE regional_administrator NOINHERIT; GRANT USAGE ON SCHEMA api, auth, public TO regional_administrator; GRANT SELECT ON api.agreements TO regional_administrator; GRANT SELECT ON api.locations TO regional_administrator; GRANT SE...
<gh_stars>1000+ create type graphql.cardinality as enum ('ONE', 'MANY');
-- This script lists all the tables of a database in your MySQL server. SHOW TABLES;
alter table domain_event_publishers add adapter varchar(100); alter table domain_event_publishers add adapter_config jsonb;
<gh_stars>0 /* Navicat MySQL Data Transfer Source Server : localhost Source Server Version : 50525 Source Host : localhost:3306 Source Database : swlhos Target Server Type : MYSQL Target Server Version : 50525 File Encoding : 65001 Date: 2017-03-23 16:30:37 */ SET F...
<filename>data/jambul.sql -- phpMyAdmin SQL Dump -- version 4.6.6 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Apr 02, 2017 at 02:51 PM -- Server version: 5.6.35 -- PHP Version: 5.6.29 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT...
{{ config( materialized = 'incremental', unique_key = "tx_hash", cluster_by = ['ingested_at::DATE'], post_hook = "ALTER TABLE {{ this }} ADD SEARCH OPTIMIZATION" ) }} WITH base_table AS ( SELECT block_timestamp, COALESCE( tx :block_number :: INTEGER, tx :blo...
create table asteroid ( id varchar not null, spkid varchar not null, full_name varchar not null, pdes varchar not null, name varchar, prefix varchar, neo varchar null, pha varchar null, H numeric(10,5), G numeric(10,5), M1 numeric(10,5), --no NEO observations M2 numeric(10,5), --no NEO observations K1 numeric(10,...
-- -------------------------------------------------------- -- Host: 127.0.0.1 -- Versión del servidor: 10.1.13-MariaDB - mariadb.org binary distribution -- SO del servidor: Win32 -- HeidiSQL Versión: 9.4.0.5125 -- ------------------------------------------------...
alter table connection add column currency varchar(12);
GRANT SELECT ON equipment, sensor, parameter_type TO ingres; GRANT INSERT ON equipment, sensor, parameter_type, measurement, parameter TO ingres; GRANT SELECT ON equipment, sensor, parameter_type, measurement, parameter TO spa;
DELETE FROM socks WHERE color = "red" OR color = "black";
<filename>saksbehandling/migreringer/src/main/resources/db/migration/defaultDS/1.0.0/V1.0.30__utvid_prosess_task_tabell_kolonne_navn.sql alter table prosess_task alter column siste_kjoering_server TYPE varchar(1000); alter table prosess_task alter column OPPRETTET_AV TYPE varchar(1000); alter table PROSESS_TASK_FEILHA...
/* 查询选课门数唯一的学生的学号 */ select sno from sc group by sno having count(*) = 2;
CREATE TABLE test ( id INT64 NOT NULL, ) PRIMARY KEY (id); CREATE TABLE test_2 ( id INT64 NOT NULL, name STRING(128), ) PRIMARY KEY (id);
GO USE [SoftUni] GO SELECT * FROM [Employees] ORDER BY [Salary] DESC , [FirstName] ASC , [LastName] DESC , [MiddleName] ASC
USE [master] GO /****** Object: Database [NancyAzureFileUpload] Script Date: 1/20/2017 12:06:46 AM ******/ CREATE DATABASE [NancyAzureFileUpload] CONTAINMENT = NONE ON PRIMARY ( NAME = N'NancyAzureFileUpload', FILENAME = N'C:\Users\Fernando\NancyAzureFileUpload.mdf' , SIZE = 8192KB , MAXSIZE = UNLIMITED, FILEG...
-- Adapted from MIT Licensed https://github.com/MIT-LCP/mimic-code DROP TABLE IF EXISTS ADMISSIONS; CREATE TABLE ADMISSIONS ( ROW_ID INT NOT NULL, SUBJECT_ID INT NOT NULL, HADM_ID INT NOT NULL, ADMITTIME TIMESTAMP(0) NOT NULL, DISCHTIME TIMESTAMP(0) NOT NULL, DEATHTIME TIMESTAMP(0), ADMISSION_TYPE VARCH...
.read 0.sql SELECT * FROM FruitsForSale ORDER BY Fruit;
<reponame>mrudulpolus/kc CREATE TABLE "RESEARCH_AREAS" ( "RESEARCH_AREA_CODE" VARCHAR2(8) constraint RESEARCH_AREASN1 NOT NULL ENABLE, "PARENT_RESEARCH_AREA_CODE" VARCHAR2(8) constraint RESEARCH_AREASN2 NOT NULL ENABLE, "HAS_CHILDREN_FLAG" VARCHAR2(1) constraint RESEARCH_AREASN3 NOT NULL ENABLE, "DESCRIPTION"...
<filename>coeus-db/coeus-db-sql/src/main/resources/org/kuali/coeus/coeus-sql/log/Release_2_0_logs/KRACOEUS-3671.sql INSERT INTO PROPOSAL_STATE ( STATE_TYPE_CODE, DESCRIPTION, UPDATE_TIMESTAMP, UPDATE_USER ) VALUES ( 12, 'Revisions Requested', to_date('2010-03-10 09:11:00', 'YYYY-MM-DD HH24:MI:SS'), 'ADMIN' );
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Dec 27, 2016 at 11:33 PM -- Server version: 10.1.19-MariaDB -- PHP Version: 5.6.28 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CL...
<filename>arquillian-jpa/src/test/resources/test-data.sql insert into PersonEntity (id, birth, company, name, role, surname) values (null, null, 'Red Hat', '<NAME>', 'Associate Middleware Consultant', 'Ercoli')
CREATE TABLE Conversations( ID varchar(100) PRIMARY KEY, mark decimal(3,1), feedback varchar(2000), user_id integer, bot_id integer, created timestamp, modified timestamp, ended timestamp --to see if the message was seen );
<gh_stars>1-10 # --- Created by Ebean DDL # To stop Ebean DDL generation, remove this comment and start using Evolutions # --- !Ups create table noticia ( id bigint not null, titulo varchar(255), usuario_id bigint, enlace varchar...
/* $PostgreSQL: pgsql/contrib/adminpack/adminpack.sql.in,v 1.6 2007/11/13 04:24:27 momjian Exp $ */ /* *********************************************** * Administrative functions for PostgreSQL * *********************************************** */ /* generic file access functions */ CREATE OR REPLACE FUNCTION pg_cat...
<reponame>EsupPortail/esup-mdw -- phpMyAdmin SQL Dump -- version 4.0.10.10 -- http://www.phpmyadmin.net -- -- Version du serveur: 5.5.34-log -- Version de PHP: 5.3.3 -- ESUP-Portail MONDOSSIERWEB - Copyright (c) 2016 ESUP-Portail consortium -- Base de donnees: `mdw` -- -- --------------------------------------------...
ALTER TABLE "process_deployment_info" ADD COLUMN "comment_id" INTEGER; ALTER TABLE "process_deployment_info" ADD CONSTRAINT "comment_id_in_deployed_proc_fk" FOREIGN KEY ("comment_id") REFERENCES "process_comments" ("id") ON DELETE CASCADE;
Sidoarjo Balongbendo Buduran Candi Gedangan Jabon Krembung Krian Prambon Porong Sedati Sukodono Taman Tanggulangin Tarik Tulangan Waru Wonoayu
UPDATE `Tags` SET `name` = CASE `name` WHEN 'karel' THEN 'problemRestrictedTagKarel' WHEN 'lenguaje' THEN 'problemRestrictedTagLanguage' WHEN 'solo-salida' THEN 'problemRestrictedTagOnlyOutput' WHEN 'interactive' THEN 'problemRestri...
drop proc if exists [dbo].[GetMostSoldProductInCities] go alter proc [dbo].[GetMostSoldProductInCities] as begin select c.[Name], (select top 1 concat(p.Model, ' ', p.Brand) from dbo.Product p inner join dbo.Order_Product op on op.ProductId = p.Id inner join dbo.[Order] o on op.OrderId = o.Id inner join d...
<filename>FileStorage/FileStorageDatabase/CreateFileStorageDatabase.sql<gh_stars>0 CREATE DATABASE FileStorage ON PRIMARY (NAME = FileStorage_data, FILENAME = 'C:\TestStorage\Database\FileStorage_data.mdf'), FILEGROUP FileStreamGroup_FileStorage CONTAINS FILESTREAM (NAME = FileStorage_blobs, FILENA...
<reponame>WS-Jedp/juno-web-exp<filename>prisma/migrations/20210628002330_sixth/migration.sql -- CreateTable CREATE TABLE `CurrentStudy` ( `id` INTEGER NOT NULL AUTO_INCREMENT, `studyId` INTEGER NOT NULL, `progress` INTEGER NOT NULL DEFAULT 50, UNIQUE INDEX `CurrentStudy_studyId_unique`(`studyId`), ...
select * from ( select id, username, first_name, last_name, slackName from profil_kioskuser where is_active and aktivBis > current_timestamp and visible union all select id, username, first_name, last_name, slackName from profil_kioskuser where usernam...
<filename>DB/init.sql /*--------- BEGIN MODULE INSERT / UPDATE COMPILE JOB ON SUBMISSION STATUS COMPILING ---------------- --------------------------------------------------------------------------------------------------*/ CREATE OR REPLACE FUNCTION insert_compile_job() RETURNS trigger AS $lang_insert_compile_job$ BEG...
-- phpMyAdmin SQL Dump -- version 4.9.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Oct 23, 2019 at 03:01 PM -- Server version: 10.3.16-MariaDB -- PHP Version: 7.1.30 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @...
CREATE PROCEDURE dbo.StoreCountersData ( @CountersToStore dbo.CountersData READONLY ) WITH EXECUTE AS OWNER AS SET NOCOUNT ON INSERT INTO dbo.ServerFriendlyName SELECT DISTINCT ServerFriendlyName FROM @CountersToStore C WHERE NOT EXISTS (SELECT 1 FROM dbo.ServerFriendlyName WHERE dbo.ServerFriendlyName.ServerFriendl...
<reponame>kwj280/TPS<gh_stars>1-10 DELIMITER | DROP FUNCTION IF EXISTS `levenshtein` | DROP FUNCTION IF EXISTS `levenshtein_ratio` | CREATE DEFINER=`root`@`localhost` FUNCTION `levenshtein`( s1 VARCHAR(255), s2 VARCHAR(255) ) RETURNS int(11) DETERMINISTIC BEGIN DECLARE s1_len, s2_len, i, j, c, c_temp, cost INT...
<filename>src/test/resources/wherelimit.test_47.sql -- wherelimit.test -- -- execsql {DELETE FROM t1 WHERE x=5 ORDER BY x LIMIT 2, 5} DELETE FROM t1 WHERE x=5 ORDER BY x LIMIT 2, 5
<reponame>Shuttl-Tech/antlr_psql -- file:triggers.sql ln:1751 expect:true select * from table1
create or replace function londiste.subscriber_get_table_pending_fkeys(i_table_name text) returns setof londiste.subscriber_pending_fkeys as $$ declare fkeys record; begin for fkeys in select * from londiste.subscriber_pending_fkeys where from_table=i_table_name or to_table=i_table_...
UPDATE AD_Note SET AD_Message_ID=544581 WHERE AD_Message_ID=543816; -- 2017-11-23T18:45:57.818 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator DELETE FROM AD_Message_Trl WHERE AD_Message_ID=543816 ; -- 2017-11-23T18:45:57.829 -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator DELETE...
<reponame>k-dou/dtcms CREATE TABLE IF NOT EXISTS `article`( `id` bigint(10) unsigned NOT NULL AUTO_INCREMENT, `title` varchar(100) NOT NULL, `desc` varchar(250) NOT NULL DEFAULT '', `type` tinyint(3) unsigned NOT NULL, `img` varchar(150) NOT NULL DEFAULT '', `content` text NOT NULL, `is_md` tinyint(2) NOT...
<filename>sql/fl/2012_07_29_world_creature_text.sql REPLACE INTO `script_texts` (`npc_entry`, `entry`, `content_default`, `sound`, `type`, `language`, `emote`, `comment`) VALUES (40586, -1643001, 'You have interfered with our plans for the last time, mortals!', 0, 1, 0, 0, 'Lady Naz\'jar SAY_AGGRO'), (40586, -1643002,...
DELETE FROM command WHERE name IN ('lookupitem','lookupitemset','lookupcreature','lookupobject','lookupquest','lookupskill','lookupspell','lookuptele'); INSERT INTO `command` VALUES ('lookup creature',3,'Syntax: .lookup creature $namepart\r\n\r\nLooks up a creature by $namepart, and returns all matches with their ...
-- Run the following command to open PostgreSQL: psql -U <username> -- Then enter the password for the user -- To run this script inside psql, enter following at command line: \i <file-location> -- ex. \i C:/Users/User/Desktop/dbscript.sql -- NOTE: If user is not 'postgres', then change the OWNER below to the c...
USE `counter_0_1`; # first truncating everything DELETE FROM `items`; ALTER TABLE `items` AUTO_INCREMENT=1; DELETE FROM `permissions`; ALTER TABLE `permissions`; DELETE FROM `lists`; ALTER TABLE `lists` AUTO_INCREMENT=1; DELETE FROM `users`; ALTER TABLE `users` AUTO_INCREMENT=1; # then reinserting INSERT INTO `users`...
<gh_stars>10-100 # # SQL Export # Created by Querious (300002) # Created: 17 July 2019 at 14:20:49 CEST # Encoding: Unicode (UTF-8) # SET @ORIG_FOREIGN_KEY_CHECKS = @@FOREIGN_KEY_CHECKS; SET FOREIGN_KEY_CHECKS = 0; SET @ORIG_TIME_ZONE = @@TIME_ZONE; SET TIME_ZONE = '+00:00'; SET @ORIG_SQL_MODE = @@SQL_MODE; SET SQL...
-- Create the titles table & check table data import CREATE TABLE titles ( title_id VARCHAR(10) PRIMARY KEY, title_name VARCHAR(30) NOT NULL ); SELECT * FROM titles; -- Create an employees table & check table data import CREATE TABLE employees ( emp_no INTEGER PRIMARY KEY, emp_title_id VARCHAR(10) NOT...
CREATE SCHEMA [Expense] AUTHORIZATION [dbo] GO
<filename>app/addons/l4w_mollie/database/data.sql INSERT INTO `?:payment_processors` (processor, processor_script, processor_template, admin_template, callback, type) VALUES ('[l4w] Mollie iDeal', 'l4w_mollie_ideal.php', 'addons/l4w_mollie/views/orders/components/payments/l4w_mollie.tpl', 'l4w_mollie.tpl', 'Y', 'P'); ...
<filename>db2te/tutorials/workshops/Security/LBAC/ColumnLevel/SQL/cleanup1.sql REVOKE SECURITY LABEL DataAccess.SECRET FROM ROLE custService; REVOKE SECURITY LABEL DataAccess.TOP_SECRET FROM ROLE Mgr; REVOKE ALL PRIVILEGES on table ?SCHEMA?.credit_card FROM ROLE Mgr; REVOKE ALL PRIVILEGES on table ?SCHEMA?.credit_...
<reponame>elcreator/phalcon-demo use project; set sql_mode = ''; set character set 'utf8'; set names 'utf8'; create table user ( id int primary key not null auto_increment, email varchar(255) default '' not null, is_banned tinyint default 0 ...
<reponame>SKalt/pg_sql_parser_tests archive_command = 'test ! -f /mnt/server/archivedir/%f && cp %p /mnt/server/archivedir/%f' # Unix archive_command = 'copy "%p" "C:\\server\\archivedir\\%f"' # Windows
<gh_stars>1-10 -- This SQL code was generated by sklearn2sql (development version). -- Copyright 2018 -- Model : CaretClassifier_earth_pca -- Dataset : iris_date_tgt -- Database : mssql -- This SQL code can contain one or more statements, to be executed in the order they appear in this file. -- Model deployment c...
<gh_stars>0 ------------------------------------------------------------------------------- CREATE FUNCTION test_before_action() RETURNS trigger LANGUAGE plpgsql AS $function$ BEGIN NEW.mo = now(); RETURN NEW; END; $function$; CREATE TRIGGER test_trigger BEFORE INSERT OR UPDATE ON test.test FOR EACH RO...
-- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 11 Agu 2020 pada 23.55 -- Versi server: 10.1.36-MariaDB -- Versi PHP: 5.6.38 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHAR...
<reponame>74Labs/node-sparx-ea<filename>sql/diagrams/connectors.sql select c.Connector_ID as id, c.Stereotype as type, c.Start_Object_ID as source, c.End_Object_ID as target from t_diagramlinks d join t_connector c on c.Connector_ID = d.ConnectorID where d.DiagramID = @ID;
<reponame>DIH-OST/meinschaufenster SELECT * FROM TblNotificationRegistrations DROP TABLE TblNotificationRegistrations DROP TABLE TblPhoneLists DROP TABLE TblCompanies DROP TABLE TblSRSessions DROP TABLE tblUsers
<reponame>fflah/SIMPLE-PROJECT-CRUD-PHP-FRAMEWORK-C3-<gh_stars>0 -- phpMyAdmin SQL Dump -- version 4.8.0.1 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Waktu pembuatan: 16 Des 2019 pada 03.39 -- Versi server: 10.1.32-MariaDB -- Versi PHP: 7.2.5 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; STA...
<reponame>v-ficaet/RS-Avengers<filename>T-SQL for ReportServer/SQLAgent_Jobs-Subscriptions.sql USE ReportServer -- CHANGE THIS LINE FOR REPORT SERVER DATABASE NAME SELECT j.[Name] AS JobName ,cat.[Name] AS ReportName ,cat.[Path] AS ReportPath ,sub.[Description] AS SubscriptioName ,CASE j.[enabled] WHEN 1 THEN 'Enabled...
-- phpMyAdmin SQL Dump -- version 4.9.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Sep 05, 2019 at 09:52 AM -- Server version: 10.3.16-MariaDB -- PHP Version: 7.3.7 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @O...
<reponame>tanysaur/bamazon CREATE DATABASE bamazon; USE bamazon; CREATE TABLE products ( item_id INT NOT NULL AUTO_INCREMENT, product_name VARCHAR(45) NULL, dept_name VARCHAR(45) NULL, price FLOAT(10,2) NULL, stock_qty INT NULL, PRIMARY KEY (item_id) ); INSERT INTO products (item_id, product_name, dept_n...
<gh_stars>0 TRUNCATE fillfactor50, fillfactor75, fillfactor90, fillfactor100;
-- Table: public.municipality_contacts -- DROP TABLE public.municipality_staff_contacts; CREATE TABLE public.municipality_staff_contacts ( demarcation_code text, role text, title text, name text, office_number text, fax_number text, email_address text, id serial, CONSTRAINT municipality_staff_contac...
SELECT [Name] ,[Path] ,[CreationDate] ,[ModifiedDate] ,CAST(CAST(Content AS VARBINARY(MAX)) AS XML) AS ReportXML --query will be in <DataSets> tag FROM [ReportServer].dbo.[Catalog] WHERE Type = 2 ORDER BY [Name]
-- Copyright (c) 2021 <NAME>, MIT License -- https://github.com/nalgeon/sqlean .load dist/fileio -- lsdir select '01', (name, mode, size) = ('LICENSE', 33188, 1105) from lsdir('LICENSE'); select '02', count(*) >= 10 from lsdir('test'); select '03', count(*) = 0 from lsdir('whatever.txt'); .shell mkdir parentdir .shel...
<reponame>alexanderbauer89/HackerRank SELECT Name FROM STUDENTS WHERE MARKS>75 ORDER BY RIGHT(Name, 3), ID ASC;
<reponame>alda519/chytractvrt<filename>data/dbinit-ng.sql insert into categories (name) values ('Volný čas'), ('Stravování a ubytování'), ('Domácí zvířata'), ('Doprava'), ('Odpady, úklid a údržba'), ('Prodejny'), ('Školství'), ('Služby'), ('Krása a zdraví') ; insert into subcategories (name, category_...
ALTER TABLE QUESTIONNAIRE_QUESTIONS MODIFY CONDITION_TYPE VARCHAR(3);
SELECT T1.CENTERID, T1.CUSTACCOUNT, T1.CUSTNAME, T1.PROJECTID, T1.COURSEPRICE, T1.COURSEFEE, T1.PAYABLEAMOUNTPATWAY, T1.ILAACCOUNTAMOUNTPATHWAY AS [Paid By ILA ACCOUNT], dbo.GetProduct(T1.PROJECTID) AS [Product], T2.SellerOriginalName AS [EP Incharge], T2.SellerOriginalCode AS Code FROM VIEWREGISTRATION_LT T1 INNER JO...
-- MySQL dump 10.13 Distrib 8.0.25, for Linux (x86_64) -- -- Host: localhost Database: uniTesDB -- ------------------------------------------------------ -- Server version 8.0.25-0ubuntu0.20.04.1 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_S...
-- Cleanup existing database, dropping all tables and indices -- Note Drop in reverse order of creation to ensure constraints are dropped -- before the tables that those constraints depend on, are removed. drop table if exists files_metadata; drop table if exists documents_metadata; drop table if exists versions_meta...
<reponame>elnyry-sam-k/operator-settlement /***** * License * -------------- * Copyright © 2017 Bill & Melinda Gates Foundation * The Mojaloop files are made available by the Bill & Melinda Gates Foundation under the Apache License, Version 2.0 (the "License") and you may not use these files except in compliance with t...
/* We cannot use timestamp in MySQL because of the implicit TimeZone conversions it does behind the scenes */ DROP DOMAIN IF EXISTS datetime CASCADE; CREATE DOMAIN datetime AS timestamp without time zone; /* TEXT in MySQL is smaller then MEDIUMTEXT */ DROP DOMAIN IF EXISTS mediumtext CASCADE; CREATE DOMAIN mediumtext A...
<filename>databaseScripts/PostgresSQL/POSTGRES_mark59_v4.0.0-rc-1_to_v4.0.0_conversion.sql -- ************************************************************************************* -- ** -- ** from 4.0.0-rc1 to 4.0.0 -- ** Only change is that the 'pre-defined' variables in in Metrics Graph Mapping -- ** cha...
CREATE OR REPLACE VIEW mi_rr AS SELECT col1 as "RecordType", col2 as "ConversationID", col3 as "RequestorODS", col4 as "SenderODS", col5 as "RegistrationTime", col6 as "RegistrationType", col7 as "RegistrationSmartcardUID", col8 as "RequestFailurePoint", col9 as "RequestFailureTime", col10 as "Requ...
<gh_stars>100-1000 SELECT * FROM READ_MARKS ORDER BY INSERT_DATETIME %s LIMIT ? OFFSET ?;
<filename>db/wechat_staff_saedb.sql /* Navicat Premium Data Transfer Source Server : sae db Source Server Type : MySQL Source Server Version : 50623 Source Host : pwpqcmewfhlq.rds.sae.sina.com.cn Source Database : wechat_staff Target Server Type : MySQL Target Server Version : 50...
<reponame>Vidalets/blog -- phpMyAdmin SQL Dump -- version 4.4.15.5 -- http://www.phpmyadmin.net -- -- Хост: 127.0.0.1:3306 -- Время создания: Фев 12 2018 г., 11:40 -- Версия сервера: 5.5.48 -- Версия PHP: 5.6.19 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=...
<reponame>pirocorp/Databases-Basics-MS-SQL-Server<gh_stars>0 SELECT CONCAT(m.FirstName, ' ', m.LastName) AS Mechanic, AVG(DATEDIFF(DAY, j.IssueDate, j.FinishDate)) AS [Average Days] FROM Mechanics AS M JOIN Jobs AS J ON j.MechanicId = m.MechanicId WHERE j.[Status] = 'Finished' GROUP BY m.Mec...
-- -- Learning SQL -- Exercise 5-2 -- SELECT f.title FROM film f INNER JOIN film_actor fa ON fa.film_id = f.film_id INNER JOIN actor a ON a.actor_id = fa.actor_id -- use LIKE as we want to include any actor with 'JOHN' appearing in their last_name -- not just actors with last_name exactly matching 'JOHN' WHERE a.f...
<reponame>cnyangyifeng/xmzye_nodejs /* Navicat Premium Data Transfer Source Server : xmzy_core_db Source Server Type : MySQL Source Server Version : 50628 Source Host : gz-cdb-hy2472r9.sql.tencentcdb.com:63055 Source Schema : cAuth Target Server Type : MySQL Target Server Versi...
CREATE DATABASE IF NOT EXISTS `pms` /*!40100 DEFAULT CHARACTER SET utf8 */; USE `pms`; -- MySQL dump 10.13 Distrib 5.6.23, for Win64 (x86_64) -- -- Host: localhost Database: pms -- ------------------------------------------------------ -- Server version 5.6.24-log /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTE...
<reponame>nagahshi/LeetCodeProblems_Repository<filename>problems/second_highest_salary/solution.sql # Write your MySQL query statement below select MAX(Salary) as "SecondHighestSalary" from Employee WHERE Salary < (select MAX(Salary) from Employee);
<reponame>sakthisiga/kedb<filename>sql/kedb_db.sql -- -------------------------------------------------------- -- Host: 127.0.0.1 -- Server version: 5.6.26 - MySQL Community Server (GPL) -- Server OS: Win32 -- HeidiSQL Version: 9.3.0.4984 -- ----...