Skip to content

Tag: mariadb

How to use a SQL keyword NOT as a keyword

I am trying to transform a table of data–I want the rows to become the columns, and the columns to become the rows (like a total complete pivot). I am using the method from this answer to do so. If it makes any difference, I am running my own SQL server on a Raspberry Pi using PHPMyAdmin. The table (tru…

Multiple full joins in one query on multiple tables

I have a database with multiple tables, I wish to show all contents from every table with one query (that I will use later for a research in the database). view of the database I’ve tried with two tables but it returns an error. I’m using 10.4.14-MariaDB version. full join query error Answer One m…

Select records within 5 kilometers with group by

I have an application that uses coordinates. I want to select records within 5 km that were thrown in the last 5 minutes. How can I do this easiest? I want to write a procedure. The values I will send to the procedure are latitude (float 11,8) and longitude (float 11,8). Example table: I found a query like th…

SELECT statement across multiple tables

First off, I am not an SQL coder. I am trying to select information from 2 different tables in the same database. Table 1 is called trans and has 3 columns: Table 2 is called cust and has multiple columns: The SELECT statement that I’m trying to write will pull data from both tables. I THINK I need to u…