ms access crashes when loading an mdb containing a linked sql server table

I have an mdb which used to contain a bunch of linked tables. These links point to tables in another Access mdb. As part of a controlled migration, I'm changing these link table to point to an...

How to drop all tables in a SQL Server database?

I'm trying to write a script that will completely empty a SQL Server database. This is what I have so far: USE [dbname] GO EXEC sp_msforeachtable 'ALTER TABLE ? NOCHECK CONSTRAINT all' EXEC...

How can I alter a primary key constraint using SQL syntax?

I have a table that is missing a column in its primary key constraint. Instead of editing it through SQL Server, I want to put this in a script to add it as part of our update scripts. What...

Entity Framework Migrations renaming tables and columns

I renamed a a couple entities and their navigation properties and generated a new Migration in EF 5. As is usual with renames in EF migrations, by default it was going to drop objects and recreate...

create stored procedure if doesn't exist in sql server

Oracle does "create or replace" statements. Sql server does not seem to - if you are scripting out from Enterprise Manager, it instead suggests "drop and create" instead. Drop and create is...

Make a ODBC connection from a delphi-7 application throu ADOConnectionstring

Background : Application written in Delphi-7 or -6 (have search through the .exe file). Called Sigmanest. I have moved to new server and that's left is SigmaNest database running under SQL server....

SQL Case statement error Msg 8114

Trying to build a simple case statement using SQL Server 2008 and running across an issue giving me the following error message: Msg 8114, Level 16, State 5, Line 6 Error converting data type...

How to remove unused space from SQL Server table?

I've got a SQL Server table that had lots of data in a nvarchar(max) column. I set that columns value to all nulls so now the table should not take up much space. How can I reclaim that...

Dropping column with foreign key Laravel error: General error: 1025 Error on rename

I've created a table using migration like this: public function up() { Schema::create('despatch_discrepancies', function($table) { $table->increments('id')->unsigned(); ...

Why does Hibernate generate a CROSS JOIN for an implicit join of a @ManyToOne association?

Baur & King said in their book: Implicit joins are always directed along many-to-one or one-to-one association, never through a collection-valued association. [P 646, Ch 14] But when I am doing...

how to deploy localdb database with app

I am ready to finalize a winforms add in I have created for Excel which uses Add-In Express to publish. This add in uses a sql server localdb database with mdf file. My primary question is how to...

handling errors inside code first migrations

I have the following inside my Up() public override void Up() { try { Sql("drop index [IX_SalesInvoiceLine] on dbo.SalesInvoiceLines"); } catch (Exception) { ...

Oracle Sql: add column which counts the rows, starting at 1 each time anothers column value changes

I guess this one is discussed already, but I didn`t find it. I am new to sql using the oracle sql developer. Here is an example of my problem: example At the moment the Depot_ID is the unique...

How to exclude multiple columns in Spark dataframe in Python

I found PySpark has a method called drop but it seems it can only drop one column at a time. Any ideas about how to drop multiple columns at the same time? df.drop(['col1','col2']) TypeError ...

Invalid Column Name using Dynamic SQL

I am attempting to use Dynamic SQL for the 1st time - Now i understand the gist of it to an extent however attempting to enter a parameter into a temp table using Dynamic SQL i am getting the...

Django can't drop database: psycopg2.OperationalError: cannot drop the currently open database

Whenever I try to run my Django tests via manage.py, the tests run fine however at the end when Django is destroying the database the following error occurs: Destroying test database for alias...

Return results from SQL Server stored procedure using variables in ADODB

I'm working on a rec process which will pull data out of a SQL Server database into Excel and out of another application to compare the two sources. I've written some code that will pull the data...

H2 not creating/updating table in my Spring Boot app. Something's wrong with my Entity?

I want to keep some data in H2 database by making a CRUD repository, using Hibernate. I can't get the database to store my entries whatsoever. Currently, I'm trying to achieve that during updating...

Entity Framework Core Database Table Valued Functions Mapping

I use EFCore 2.1 Database First approach. I'm pretty familiar with SQL syntax and prefer build queries myself rather then leave this work on EF. I use Table Valued and Scalar Functions for...

Backup MySQL database with OHO Codeigniter

i have a problem to determine the destination where the zip backup file should be downloaded, and the name of the zip file are always generated randomly like this one i got...

how to fix sqliteException in android java

I have trying to insert values into database as well as in content provider but getting null sqlite exception.Before using content provider class my data are added to database without any...

Convert hypertable to regular postgres table

quite new to timescaledb and I'm struggling with a migration script. I'm trying to create migrations for a flask application with SQLAlchemy. Let's say I created a table (as in timescaledb docs)...

How to Drop N days old temp / temporary tables in SQL Server

We have 100s of proc which are creating temp tables and Not dropping them. Many of the builds are in production. We would like to have SQL query to drop these after N (=2) days and schedule it. Is...

SQL Server Agent Job stops SSIS Step with "unexpected error" and without any error informations

I am dealing with my problem on some Windows Server 2019 (Core) with one running SQL Server 2019 CU4 instance each. What we try to do We are currently building a data warehouse with distributed...

EF Core failed to execute database update command : " fail: Microsoft.EntityFrameworkCore.Database.Command[20102] "

Guys I'm trying to run dotnet ef database update command but during the executing of it, it trows me an exception: Failed executing DbCommand (12ms) [Parameters=[], CommandType='Text',...

How to access Postgresql database from multiple threads in a Django test?

I have a Django website with a PostgreSQL database that runs some background tasks with multithreading. However, I am having troubles testing this multithreading part. I followed...

VBA code equivalent to "SELECT * FROM [query] where [column] = combobox

I have a data connection in my xlsm file, which is called "DATA". I created my combo box and input the value from a range. Now I need to return a result set based on the value from the combo box...

PG::UndefinedFunction: ERROR: function array_append(anyarray, anyelement) does not exist

In my application we have few test cases which are configured with GitHub workflow,Even I do have only space related changes on file but still getting below error. Not sure why my specs are still...

keycloak server 15.0.2 timeout error for mysql 5.7 and Java 17 and jconnect 8

I am getting error while connecting kycloak server 15.0.2 to my SQL 5.7 database using connect 8.0.27. After starting keycloak server, I can see tables created by keycloak server in keycloak...

Debugging a Google Dataflow Streaming Job that does not work expected

I am following this tutorial on migrating data from an oracle database to a Cloud SQL PostreSQL instance. I am using the Google Provided Streaming Template Datastream to PostgreSQL At a high level...

Relevant tags