I am running MySQL 14.14 Distrib 5.7.40 for Linux (x86_64) on my BlueHost VPS. A few months ago I could run this command successfully: I have to go rerun this every few months to avoid this error: Today when I ran that it appeared successful, but the SQL errors remain in my web app: Invalid query: Expression …
Tag: sql
How to block a user from executing select queries on a table in Db2?
I have a database ‘SAMPLE’ in which I need to block a user ‘DB2ADMIN’ from executing I already tried I get error SQL0556N and message “DB2ADMIN does not hold this privilege”, which means it shouldn’t have worked in first place. Still I am able to get select query resu…
How to pass parameter of oracle sql script file to sqlplus from shell prompt?
Objective: To invoke sqlplus with sql script file path as parameter from shell prompt Scenario: logged in as root and would like to execute the sql script file as oracle Command: Expected: sql commands in createschema.sql are to be executed Actual: getting only sql prompt Also, tried: a) b) whenever sqlerror …
Where can I download the Northwind sample database for SQLite?
After looking at: Where can I download Northwind database for Postgresql? it looks like the best place for Northwind data, outside of the Microsoft itself, is: https://code.google.com/archive/p/northwindextended/downloads to what extent does this raw data match the Microsoft data? Is there any advantage in do…
How to fix syntax error at or near “psql” in psql ubuntu
I am entirely new to psql and not particularly familiar with some terms. I am following instructions on an ETL process for mimic-in the link here: https://github.com/chichukw/mimic-omop/blob/master/README-run-etl.md. When I run this code, it shows no output but this error: syntax error at or near “psql&…
Arguments mismatch using where IN clause in query
I have column in hive table like below Now I want to get the distinct values as a variable so I can use in another query. I have done like below when I do I get below error what the the mistake I am doing? What is the correct way of achieving my result? Note: I know I can use
Why does MSSQL in Docker return “The last operation was terminated because the user pressed CTRL+C” on sql queries?
I’m on Archlinux 64x (4.17.4-1-ARCH) with Docker (version 18.06.0-ce, build 0ffa8257ec). I’m using Microsoft’s MSSQL docker container CU7. Each time I’m trying to enter a query or to run a SQL file I get this warning message: Then when I check in the database with Datagrip, the query h…
Authenticate from Linux to Windows SQL Server with pyodbc
I am trying to connect from a linux machine to a windows SQL Server with pyodbc. I do have a couple of constraints: Need to log on with a windows domain account Need to use python3 Need to do it from Linux to Windows Need to connect to a specific instance I set up the environment as described by microsoft
PostgreSQL COPY FROM STDIN not working, but FROM PATH works
In PostgreSQL I previously created a table like so: The idea is to import multiple csv files into this table. My approach is to use COPY … FROM STDIN instead of COPY … FROM ‘/path/to/file’, as I want to be able to cat from the shell multiple csv files and pipe them to the sql script. T…
How to use a sql DB for ssh?
I have a webapplication and I would like to provide the users with a feature to be able to ssh to the linux server without having to add all the users’ credentials from the Psql DB to the linux server. Instead I would like to use the credentials directly for ssh. I think that this is possible using linu…