Questions tagged [errors]

For questions about specific error codes or messages, including troubleshooting.

Filter by
Sorted by
Tagged with
3 votes
2 answers
123 views

psql can't connect to existing db

i have problem with connecting to database via psql. I get this error: postgres@server:/var/lib/pgsql # psql -d aisgdmp2 psql: error: FATAL: database "aisgdmp2" does not exist DETAIL: The ...
  • 33
0 votes
1 answer
28 views

This query gives error. right syntax to use near 'on vehicles.school_id = schools.id left join drivers on drivers.school_id = ...' at line 8

select drc_users.name, vehicles.total_vehicles, COUNT(distinct drivers.id) as total_drivers from drc_users LEFT join brc_users on drc_users.id = brc_users.district_id left join crc_users on crc_users....
  • 113
-2 votes
1 answer
18 views

Msg 2732, Level 16, State 1, Line 376039 Error number 515 is invalid. The number must be from 13000 through 2147483647 and it cannot be 50000 [closed]

Please help me how to solve it. why is it throwing this error as my script is inserting data into various tables extracted from an environment. #376039 is the catch block where rollback and other ...
1 vote
1 answer
71 views

Error 1109: unknown table ‘account’ in filed list

When I inserted the values in new table, I had met a problem in there. The trigger will be shown below: delimiter $$ create trigger validation_check before insert on exercise.account for each row ...
0 votes
0 answers
30 views

How to get session information for Azure SQL Database errors via Kusto?

I have a kusto query that finds errors in some of my Azure SQL Databases: AzureDiagnostics | where TimeGenerated > ago(1d) | where Category == "Errors" and DatabaseName_s has "<...
  • 2,130
0 votes
1 answer
17 views

unable to add data to a table in mysql, Error Code: 1054

##Created table using the following line: create table sales ( product_id int, sell_price float, quantity int, state varchar(20) ); ##Tried to input values using the following line insert ...
0 votes
0 answers
10 views

Ignore wrongly typed fields and update all possible fields in postgresql?

Is it possible to do a single query/insert statement that inserts a number of values - however the type of values might be wrong. If a type would be wrong it should just be "ignored". IE say ...
  • 435
1 vote
0 answers
70 views

Azure SQL Error "Invalid object name '##{myTempTableName}'

I am getting an error in my stored procedure: "Invalid object name '##{myTempTableName}' for 3 global temporary tables. There are several temp tables used in the procedure, but I am getting this ...
0 votes
1 answer
40 views

Migration MySQL to Oracle 19C error ORA-00942

I'm trying to migrate a simple MySQL test database to Oracle 19c using the migration wizard available in Oracle SQL Developer, the result is that the procedure create the user and the tables but the ...
  • 1
1 vote
1 answer
132 views

How to use multiple arguments in ANY query when is bind message supplies parameters trhowing error?

I have the following query that is using one parameter that contains a lot of valid values to validate with ANY, right now I need to cast the id from bigint to int and validate with integers (This is ...
  • 121
1 vote
1 answer
80 views

MySQL procedure exists, but doesn't

I am attempting to add a stored procedure to a database that does not show that any exist in tree (Workbench): As this screenshot of tree shows. Also, executing: SHOW PROCEDURE STATUS where Db = '...
-2 votes
2 answers
92 views

Making SQL give age brackets on command

I'm trying to make SQL return how many users are inside each age bracket grabbing the date of birth from the user from the table GUEST and converting it into years, at the moment I'm trying to make it ...
3 votes
2 answers
183 views

How do I find the line that causes SSMS "Msg 8115, Level 16, State 2, Line 1"

I've got a 400 line query in MS SSMS. When I run it I get: Msg 8115, Level 16, State 2, Line 1 Arithmetic overflow error converting expression to data type int. Line 1 is just the "Select&...
0 votes
0 answers
72 views

CDC Primary Key error

We are using CDC to feed our application. However sometimes, out of the blue, the following error occurs: Violation of PRIMARY KEY constraint 'lsn_time_mapping_clustered_idx'. Cannot insert duplicate ...
  • 1,533
0 votes
1 answer
180 views

Infinite running loop while executing procedure

I have this table with 3 records. 3 records are create scripts. I need to execute the create scripts and if there is a 208 error occurred then I need to keep the record and set status as 1. Then ...
2 votes
2 answers
472 views

Invalid object name error while creating function

I have this function get_department. Inside the function there is a function call for get_po_amount. The get_po_amount function doesn't exist anymore, so when I try to create the Main function ...
2 votes
2 answers
74 views

DROP ALIAS unable to drop existing alias?

We're unable to drop aliases. So, I found an alias by running: SELECT TABLE_NAME FROM QSYS2.SYSTABLES WHERE BASE_TABLE_NAME IN ('OE0711P','OE0712P') AND TABLE_TYPE = 'A' AND ...
  • 275
3 votes
1 answer
159 views

in trouble -SQL database corruption

Recently we have been unable to do much of anything, as it seems our SQL database has some corruption. They advised us that corruption has been present for over a year, so there are no clean backups ...
1 vote
1 answer
24 views

Syntax issues when uploading backup from mysql5.7 to percona xtradb 5.7

Greetings to those readying the thread and thank you for devoting your time to answering the question. I have encountered a problem when uploading a MySQL 5.7 backup database to a Percona xtradb 5.7 ...
4 votes
2 answers
378 views

How can I get a Postgresql error number in psql?

How can I access the numeric code of an error in psql? For example, in this case I would like to get the value 23503 ("foreign_key_violation") as documented here: https://www.postgresql.org/...
0 votes
0 answers
14 views

Oracle 12c desinstall ERROR:Error occurred during initialization of VM

I want to desinsall ORACLE 12C from sever but i get the below error: Error occurred during initialization of VM java/lang/NoClassDefFoundError: java/lang/Object
  • 1
0 votes
0 answers
447 views

ER_PARSER_ERROR on node mysql query to getData

I am building backend for the first time for a project, i have use this get method in my node js to getData but its giving me this error. Can someone please help me.. code: 'ER_PARSE_ERROR', errno: ...
0 votes
0 answers
104 views

Transactional Replication Errors - Missing and Duplicate Data at Subscriber

We recently experienced errors with SQL Server Transactional Replication on a client's system. Replication is running from a SQL 2017 server to an Azure DB. Initially some replicated update commands ...
1 vote
1 answer
240 views

MySQL from backup won't start due to possibly corrupted data folder or permissions

A few days ago I was forced to format my PC due to an issue with a Windows update, I managed to make a backup first and now I'm trying to restore the files. I have a mysql instance that I'm having ...
  • 111
7 votes
3 answers
733 views

How does this piece of TSQL work?

Why the following batch doesn't work as expected? DROP TABLE IF EXISTS #test1; IF 1 = 1 SELECT * INTO #test1 FROM sys.databases WHERE database_id <= 5; ELSE SELECT * INTO #...
3 votes
1 answer
310 views

Microsoft SQL Server 2019 Developer Edition suddenly throwing Internal Connection Fatal Errors

I have Microsoft SQL Server 2019 Developer edition installed on my computer for local development work with .NET. Everything was working well as of two months ago, when I was last working on a ...
  • 33
5 votes
2 answers
285 views

Random Error 824 - All Environments

We have been experiencing seemingly random error 824 on our DEV/QA/PROD SQL 2017 Enterprise servers. The servers run nearly identical code ingesting identical daily files via an ETL process into our ...
  • 153
0 votes
0 answers
206 views

Executing SSIS in Powershell

I am trying to execute an SSIS package from Powershell where th,e package has several configured environment references. $null = [Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer....
  • 101
0 votes
0 answers
65 views

How to find statement causing "The user does not have permission to perform this action." in Azure SQL Database?

I ran a Kusto query: AzureDiagnostics | where TimeGenerated > ago(1d) | where Category == "Errors" and error_number_d == 297 | summarize count(), min(TimeGenerated), max(TimeGenerated) ...
  • 2,130
0 votes
0 answers
110 views

MySQL syntax error

CREATE DEFINER=`rpt`@`%` PROCEDURE `update_week_s`() BEGIN DECLARE col_name varchar(100); DECLARE finished INTEGER DEFAULT 0; DECLARE col_names CURSOR FOR SELECT column_name FROM ...
1 vote
0 answers
122 views

MySQL not throwing some errors in prepared statement

If I run the following query: DELETE FROM `table` where `id` = '123%7D'; Notice the gibberish at the end of the where clause I get the following error ERROR 1292 (22007): Truncated incorrect DOUBLE ...
1 vote
1 answer
2k views

SQL Server is terminating this session. c0000005 EXCEPTION_ACCESS_VIOLATION

I Got Error: A user request from the session with SPID 183 generated a fatal exception. SQL Server is terminating this session. Contact Product Support Services with the dump produced in the log ...
0 votes
1 answer
167 views

Distinguish errors I raise from other SQL Server errors

In my stored procedures, when a business rule is broken I raise an error that bubbles up to the C# client app and gets displayed to the user. e.g. RAISERROR('Hey, you cannot do that because blah blah ...
  • 501
0 votes
0 answers
123 views

Oracle 19c-ee CTX_REPORT.INDEX_SIZE and CTX_REPORT.INDEX_STATS cannot be executed

We created a simple search index, based on a 19c-ee instance of the official Oracle Docker images, with the following script: CREATE TABLE EVT ( ID VARCHAR2(36) NOT NULL, EVENT BLOB NOT ...
  • 11
-4 votes
1 answer
62 views

Finding the errors in SQL and interpreting what the SQL codes mean

Find all 5 errors in the SQL script below and explain what the script is trying to do select A.BIZ_DT, A.ACTL_PARENT_SVC_NUM, A.DIRCTN_IND, A.BUS_STOP_CD, A.BUS_STOP_ARRVL_TM, A.OPR_ID_NUM, A.REG_NUM, ...
4 votes
2 answers
823 views

Why does this query fail when I run it from a SQL Server job?

I know how to solve the issue, but I don't understand the technicality of why the below query would work when I run it from SSMS, but the same query fails when I add it as a job in the SQL Server ...
  • 90
0 votes
1 answer
39 views

How to run merge statement based on logic of joined table?

When I try to run a query like the following: MERGE INTO MYTABLE_A AS MERGE_TARGET USING ( SELECT MYTABLE_A.A, MYTABLE_B.B, MYTABLE_A.C, MYTABLE_D, MYTABLE_E FROM MYTABLE_A ...
  • 275
0 votes
1 answer
384 views

What could be the reason for this invalid objects after trying to upgrade?

We recently wanted to upgrade our Database but didnt get to do it as we got a lot of Audit specific invalid objects, after looking online for ressources we couldnt find anything specific reason for ...
0 votes
0 answers
576 views

Linked Server Error Msg 7321, Level 16, State 2, Line 1

I am getting the following error when I execute a simple linked server query. OLE DB provider "MSDASQL" for linked server "name" returned message "HTTP request returned status ...
0 votes
1 answer
161 views

How to debug "General error: 1030 Got error 0 "Internal error/check (Not system error)" from storage engine Aria

(In other similar questions, the error number has been 168, in my case it's zero.) This occurs on attempting to load a massive view (which itself is a select query on another view). Many JOINS are ...
0 votes
0 answers
135 views

Which option should I use to avoid error #2006 on MySQL (Docker Compose)

I am getting error #2006 - MySQL server has gone away while trying to restore a 11.9 mb database using PhpMyAdmin. It worked with a 4.70 mb database, but not with this one I thought that if I put --...
1 vote
1 answer
883 views

Error Severity 16 Alert being raised for events where is_event_logged = 0

I have an error level 16 alert set up as follows: USE [msdb] GO EXEC msdb.dbo.sp_add_alert @name=N'Error - Severity 16', @message_id=0, @severity=16, @enabled=1, @...
  • 1,809
0 votes
1 answer
58 views

How do I record an application session duration in SQLite?

Objective: Log the session duration of the user on the application. I have a session_log table: CREATE TABLE IF NOT EXISTS "session_log" ( "id" INTEGER PRIMARY KEY, ...
0 votes
1 answer
869 views

problem installing mariadb using mysql_secure_installation

I started secure install of MySQL with sudo mysql_secure_installation command, and I got that message: Securing the MySQL server deployment. Enter password for user root: Error: Can't connect to ...
0 votes
1 answer
720 views

Trigger created with compilation errors

SQL> create table master(pno number(5) primary key,pname varchar2(20),price number(10,2),stock number(5)); Table created. SQL> create table trans(p_no number(5),no_pro_sold number(5)); Table ...
0 votes
1 answer
775 views

Division By 0 error when running an update query MySQL

I am trying to run an update in a table and I get an "Error Code: 1365. Division by 0". The sql commands I use are these: SET @@autocommit = 0; start transaction; update XE_General join ...
0 votes
1 answer
2k views

Strange Error ... Conversion failed when converting the varchar value 'www.com' to data type int

The issue that I am running into is happening on Microsoft SQL Server. I have a view that is unioning together 2 tables. It is returning a little over 7 million records. When I attempt to JOIN ...
  • 33
0 votes
1 answer
973 views

oracle stored procedure errors: ORA-00904 invalid identifier, dynamic SQL

I am trying to find all tables that contain column called arg_column_name, look up value arg_column_value in that column of those tables, and return names of the tables and counts of found rows to the ...
-3 votes
1 answer
1k views

ORA-00907 error missing right parenthesis in CREATE TABLE

I am getting an error as ORA-00907 (missing right parenthesis) but I think it's a generic error and not related to parentheses. CREATE TABLE reservation ( PNRno int(9) primary key, journey_date ...
2 votes
1 answer
474 views

Why does adding a WHERE clause break my working query, with error "Query processor could not produce a query plan because of the hints defined..."?

I have the following (stupidly-simplified) query that leverages two CTEs that refer to the same table and joins them to each other: WITH CTE1 AS ( SELECT dbo.RemoveNonNumericCharacters(PhoneNumber)...
  • 30.5k

1
2 3 4 5
9