I m Trying to Fetch Data by using Two Date column in PostgreSQL. It is giving me the correct the output according to the query. But it is not giving me my expected result. In this Output i fetched …
How do i continue this database? (linking characteristics with predefined values to categories)
I’m struggling to understand how i need to do this. So my problem: I’m supposed to allow someone to sell a product on a website. Before selling, he has to chose a certain category. Each category has …
Using a DBMS_PIPE.PACK_MESSAGE and DBMS_PIPE.SEND_MESSAGE in a trigger
Env: Oracle 12c I’m looking at using Oracle DBMS_PIPE within a table trigger that will be used by many users. The trigger will fire only on a STATUS update as per below: The following call will be initiated from an Oracle APEX page process where this can be submitted again by multiple users. My question…
Multithreading for queries in SQL Database
Suppose I have a database, for example, for messenger. My app is collecting messages and stores them in my database. It doesn’t matter what type of database it is (i want to know how it is usually embodied and does my database support it, and are there other databases that do if it doesn’t), but i…
SQL like but not like
Currently having some issues with my script. The question goes like this ‘Show all cars which participated in event 201504 but did not participate in event 201504. So if they were not involved in …
Improve pivot view performance
I have a key-value structure for storing dynamic entities (standard EAV). I made a view for this Entity with the Pivot command. I tried to set the index for this view, but it is not possible due to the use of pivot. Is there a way to drag my data into SQL at the time of insert, Update? Because performance
SQL count show group by show in column instead of rows
I have a table like this Now my output would like to be How can I achieve that. Answer You could use condition aggregation
Aggregate SQLite query across multiple tables using JSON1
I can’t get my head around the following problem. The other day I learned how to use the JSON1 family of functions, but this time it seems to be more of an SQL issue. This is my database setup: …
mysql: natural join
everyone! I’m currently trying to make a simple table with MySQL that satisfies the below condition. make a table of ship names, displacement, and numGuns with ones participated ‘Guadalcanal’ battle 3 tables are needed to make this. I’ve tried several codes but they all failed. I also …
If you do a simple SELECT-WHERE on a CTE that is already sorted, are your results guaranteed to still be in that same order, just filtered?
Wondering about expected/deterministic ordering output from Oracle 11g for queries based on sorted CTEs. Consider this (extremely-oversimplified for the sake of the) example SQL query. Again, note …