Skip to content Skip to sidebar Skip to footer
Showing posts from June, 2024

Auto Increment On Composite Primary Key - Sqlite3 + Python

I have a code like this c.execute('CREATE TABLE IF NOT EXISTS base (ID INTEGER NOT NULL, col2 T… Read more Auto Increment On Composite Primary Key - Sqlite3 + Python

Problem With Execute Procedure In Pl/sql Developer

I this is my first attempt to create procedure and execute it. First I create simple table. DB sche… Read more Problem With Execute Procedure In Pl/sql Developer

Convert Rows To Columns With Some Conditions

this is the table id value name 1 2 first 2 2 manger 3 2 islam 4 2 … Read more Convert Rows To Columns With Some Conditions

Entity Framework With Optional Parameters?

Using Entity Framework 5 is it possible to use a stored proc with optional parameters such that you… Read more Entity Framework With Optional Parameters?

How Do I Take Only Specified Required Columns From Csv File And Add Into A Table In Postgresql?

Consider I have *----*------*-----------*----------*----------*---------------*----------------* | … Read more How Do I Take Only Specified Required Columns From Csv File And Add Into A Table In Postgresql?

How Two-part-quantity Intervals Work In An Event?

Based on the documentation, there is multiple kinds of interval quantity: Ok I'm fine with sin… Read more How Two-part-quantity Intervals Work In An Event?

How To Display Sql Data In A Specific Format In Html

I have data in Mysql in this format : name sub ---------------- a maths a science … Read more How To Display Sql Data In A Specific Format In Html

Are There Any Way To Programmatically Execute A Query With Include Actual Execution Plan And See Whether Any Index Suggestion Or Not

I have a quite good number of queries and i want to test each of them with Include Actual Execution… Read more Are There Any Way To Programmatically Execute A Query With Include Actual Execution Plan And See Whether Any Index Suggestion Or Not

Can I Update/select From A Table In One Query?

I need to select data when a page is viewed and update the 'views' column is there a way to… Read more Can I Update/select From A Table In One Query?

How To Print The Results Of A Sqlite Query In Python?

I'm trying to print the results of this SQLite query to check whether it has stored the data wi… Read more How To Print The Results Of A Sqlite Query In Python?

Linq: Adding Where Clause Only When A Value Is Not Null

I know a typical way is like this: IQueryable query = from staff in dataContext.Staffs; if(name1 !=… Read more Linq: Adding Where Clause Only When A Value Is Not Null

In Sql Server Can You Find The First Number In A String?

I have a varchar(50) sql server column with data like this: RawData ---------------------------- Wa… Read more In Sql Server Can You Find The First Number In A String?

How To Make Foreign Key Relationship On Physically Distributed Data?

three servers server 1 is central point which links the other two servers. the other two servers ha… Read more How To Make Foreign Key Relationship On Physically Distributed Data?

Emulating Multiple Requests To Sqlite Database As Goroutine Causes Random Panic

I am trying to emulate multiple requests from http.HandleFunc to function which makes changes to sq… Read more Emulating Multiple Requests To Sqlite Database As Goroutine Causes Random Panic

How Should I Sanitize Database Input In Java?

Could someone please point me to a good beginner guide on safely running SQL queries formed partly … Read more How Should I Sanitize Database Input In Java?

1 Very Large Table Or 3 Large Table? Mysql Performance

Assume a very large database. A table with 900 million records. Method A: Table: Posts +----------+… Read more 1 Very Large Table Or 3 Large Table? Mysql Performance

Using Prepared Statements With Sqlite3 And Php

I'm trying to add data to a database using SQLite3 in PHP. I got it working without prepared st… Read more Using Prepared Statements With Sqlite3 And Php

Execute Sql Server Ssis Package From Stored Procedure

I have a SSIS package that is stored in a SQL Server 2005 DB. I am trying to execute this package… Read more Execute Sql Server Ssis Package From Stored Procedure

Ms Sql Server Select Rows With Max Values

Good day I have Table1: COLUMN1 COLUMN2 Column3 ---------------------------- Eva A… Read more Ms Sql Server Select Rows With Max Values

Loop Through Nested Array To Generate Tables Of Different Lengths

I'm trying to show demand for exams of different levels in different locations. I have some co… Read more Loop Through Nested Array To Generate Tables Of Different Lengths

Sqlalchemy.exc.nosuchmoduleerror: Can't Load Plugin: Sqlalchemy.dialects:bigquery

Trying to create a bigquery connector using sqlalchemy from sqlalchemy import create_engine engine … Read more Sqlalchemy.exc.nosuchmoduleerror: Can't Load Plugin: Sqlalchemy.dialects:bigquery

Deferrable Check Constraint In Postgresql

I have function checking mandatory participation as follows: CREATE FUNCTION member_in_has_address(… Read more Deferrable Check Constraint In Postgresql

Sqlite, Sliding To Get Results Based On Value And Date

This questions is posted on a suggestion in this thread. I'm using SQLite/Database browser and… Read more Sqlite, Sliding To Get Results Based On Value And Date

Speed Up Insert To Sql Server From Csv File Without Using Bulk Insert Or Pandas To_sql

I want to put a Pandas dataframe as a whole in a table in a MS SQL Server database. BULK INSERT is … Read more Speed Up Insert To Sql Server From Csv File Without Using Bulk Insert Or Pandas To_sql

Update Records That Satisfies A Condition With Incrementing Number

I have a table in postgres like this: Id Name local_site_id local_id 1 A 2 … Read more Update Records That Satisfies A Condition With Incrementing Number

Transpose Dataset In Hive

I'm trying to transpose a variable in Hive such as: Id1 Id2 Event 1 1 7 2 2 3 2 … Read more Transpose Dataset In Hive

Stored Procedure To Return A Table With Its Name

Can I return a table with its name in a stored procedure? Solution 1: No (assuming I understand YA… Read more Stored Procedure To Return A Table With Its Name

How To Select The Max Of Two Element Of Each Row In Mysql

I have got a table that is a result of a (My)SQL query. In this table I have the post creation time… Read more How To Select The Max Of Two Element Of Each Row In Mysql

Multiple Relations Parent/child With Multiple Levels

I have a MySQL table named companies like this: +---------+-----------+-----------+ | id_comp | com… Read more Multiple Relations Parent/child With Multiple Levels

How Do I Find What Is Populating A Table?

I constantly run into this problem. I am working in a data warehouse and I cannot find out what is … Read more How Do I Find What Is Populating A Table?

Selecting The Top 5 In A Column With Duplicates

I have written a query that gives me a list of data and I need to select the top 5 pieces of data. … Read more Selecting The Top 5 In A Column With Duplicates

An Insert Exec Statement Cannot Be Nested

Hello I have a proc called Test_ProcA and I want to call Test_ProcB. I created a temp table called … Read more An Insert Exec Statement Cannot Be Nested

Asp.net Mvc Delete Button

When I click the delete button, I get this error. SqlException: The DELETE statement conflicted wi… Read more Asp.net Mvc Delete Button

How To Save A Data With Comma In Character Varying That Passes Through A Trigger?

I have a field of type character varying but I get an error when trying to save a data that contain… Read more How To Save A Data With Comma In Character Varying That Passes Through A Trigger?

Insufficient Privileges When Creating Tables In Oracle Sql Developer

I have granted the user in my connection to create tables, triggers, procedures, and sequence using… Read more Insufficient Privileges When Creating Tables In Oracle Sql Developer

Relationship Tables In Sqlite On Android

Can you help me about relationship between two tables in sqlite. I do insert,delete and update step… Read more Relationship Tables In Sqlite On Android

Performance Issue In Dynamic Dropdown Search List In Excel

I have created dropdown list which gives suggestions from existing data (like google search). I hav… Read more Performance Issue In Dynamic Dropdown Search List In Excel

How To Access Sqlite Db On The Xoom?

I have a Nexus One (rooted) and a Xoom (stock, not rooted). I have developed on my Nexus for quite … Read more How To Access Sqlite Db On The Xoom?

Assemblies In Sql Server Keep Unloading And Loading Again Periodically

SQL Server keeps loading and unloading my Assemblies, marking them as unsafe. Any ideas why it woul… Read more Assemblies In Sql Server Keep Unloading And Loading Again Periodically

Sql Server Job Activity (job Failed But History Records In Job Activity Still Showing 'running' Status )

I am checking one SSIS job execution report, which shows me the below report: The most recent one … Read more Sql Server Job Activity (job Failed But History Records In Job Activity Still Showing 'running' Status )

Why Rollback Is Not Working For Variable Table In Sql Server 2012?

I have created one variable table. In my stored procedure, there are lots of transactions. Now wh… Read more Why Rollback Is Not Working For Variable Table In Sql Server 2012?

Caused By: Java.lang.illegalstateexception: Get Field Slot From Row 0 Col -1 Failed

i want to select value from my database but i got error Caused by: java.lang.IllegalStateException… Read more Caused By: Java.lang.illegalstateexception: Get Field Slot From Row 0 Col -1 Failed

Database Within A Database (table Design)

Possible Duplicate: Database design to create tables on the fly I have a need to create a databas… Read more Database Within A Database (table Design)

How Can I Turn A String Into A Decimal In Ssis Using A Derived Column?

I am working in SSIS to fill a staging area database. I want to transfer the following data: ------… Read more How Can I Turn A String Into A Decimal In Ssis Using A Derived Column?

Django Annotate() Multiple Times Causes Wrong Answers

Django has the great new annotate() function for querysets. However I can't get it to work prop… Read more Django Annotate() Multiple Times Causes Wrong Answers

Updating Values In One Table From Another Table Using Dynamic Sql In Mssql

I have a temp table A having 2 columns col1: ID col2: Value generated using XML. I need to update t… Read more Updating Values In One Table From Another Table Using Dynamic Sql In Mssql

Power Query Data Type Conversion Issue Running Sql Server Stored Procedure

Latest version of Excel M365 and SQL Server 2017. I have a stored procedure which takes a date as i… Read more Power Query Data Type Conversion Issue Running Sql Server Stored Procedure

How To Read Extended Events .xel File

I have a certain request to read/parse the .xel file which is extended events file , How can I do t… Read more How To Read Extended Events .xel File

Sql: Explode An Array

I have a table that contains JSON objects. Each JSON object contains an array in square brackets, s… Read more Sql: Explode An Array

Access Sql Filter Query By Date For Two Values

I have an expression that shows the total inventory before all orders in and out: (Query3 just com… Read more Access Sql Filter Query By Date For Two Values

Azure Sql Database Working When Ran Locally But Not When Published To Azure

This has been cracking me up for a few days now and I just can't solve it. I followed an online… Read more Azure Sql Database Working When Ran Locally But Not When Published To Azure

Cfoutput Group Prices

i want to group prices according to products id, like here: http://s44.radikal.ru/i106/1108/57/3338… Read more Cfoutput Group Prices

Perl Dbi Sqlite Commit Or Detach Fails When Autocommit Is Set To False

The following code fails on my Windows 10 machine running Strawberry Perl 5.24: use DBI; unlink gl… Read more Perl Dbi Sqlite Commit Or Detach Fails When Autocommit Is Set To False

Sql Query To Find Earliest Date Dependent On Column Value Changing

I have a problem where I need to get the earliest date value from a table grouped by a column, but … Read more Sql Query To Find Earliest Date Dependent On Column Value Changing

Issue Connecting To Gearhost Database

I'm trying to connect with C# code to a SQL Server database hosted on gear host using the Syste… Read more Issue Connecting To Gearhost Database

Contiguous Dates

Here is the table that I am working with: MemberID MembershipStartDate MembershipEnd… Read more Contiguous Dates

Tsql Calculating Sum Of Numerous Fields

I have this kind of data: Date Count1 Count2 Count3 ... Countxx 01-05-2012 1 0 … Read more Tsql Calculating Sum Of Numerous Fields

Error : #1242 - Subquery Returns More Than 1 Row

I got an error: #1242 - Subquery returns more than 1 row when i run this sql. CREATE VIEW test AS … Read more Error : #1242 - Subquery Returns More Than 1 Row

Storing Data In A Side Table That May Change In Its Main Table

This is an overall question of best practice when designing a database and I have been unable to co… Read more Storing Data In A Side Table That May Change In Its Main Table