I need to show the results from this column where Product_name column contains ‘Documentation’ or ‘documentation’ in a result. The query must return a result regardless of whether the word is in lowercase or uppercase https://i.stack.imgur.com/bjLuY.png I found this solution, any suggestions Answer
Tag: sql
Wp return result from sql using AJAX
I need some help i am making a wordpress plug in. when i try to get some rows from sql thro a AJAX post i will get nothing back. Even if i try just to return a string it will stays empty. I Dont get any error . Thank you so much for helping. Script: my function: Answer You should
plsql parameterised cursor in which the parameter is user input
here’s my cursor statement and call like this The variable countryName is declared along with the cursors, and this query runs fine but no data is fetched. no idea what I’m missing here.. Answer With some sample data like below: A_TBL ID COL_A COL_B IE 01-NOV-22 1 UK 02-NOV-22 2 FR 03-NOV-22 3 IT 04-NOV-22 4 this code works… Did
SQL – select column value of previous matching row
I have a dataset like the above. Basically it’s like a website session which I have a start + end activity, and in between there could be other unrelated records. I need to pull the records based on: I need to report all the “end” activity from the table In each “end” record, I need to find its nearest previous
Are there any naming conventions for self-referential, many-to-many relationship tables?
Let’s say we have a table called Users for a fictional social media platform. In addition to regular users, some more experienced users are asked to be “greeters” where they are assigned other, newer users to greet and encourage. Because greeters aren’t always available, multiple greeters are assigned to each new user and each greeter is assigned multiple new users.
Counts of re-purchase same product by the same customer in certain days or within certain duration days
I need to have the counts of re-purchase same product by the same customer in tow scenarios: in certain days and within certain duration. Here is the sample data: Duration is the difference between the last EndDay and the next StartDay for same customer purchasing same product. For example: For customer A, the EndDay at the first time he purchased
How to use group by in sql? (I need sequelize)
I have But it fails with this error: Works fine without GROUP BY Answer The GROUP BY statement groups rows that have the same values into summary rows, in your case, it is the country_code. It is often used with aggregate functions (COUNT(), MAX(), MIN(), SUM(), AVG()) to group the result-set by one or more columns. That means, for expl
How to extract only rows matching condition ‘WHERE column1 ILIKE column2’ (where column1 is integer and column2 is jsonb)?
I am using postgresql. Let’s suppose I have this table name my_table: I want to select only the rows having the value of id equal to one of the elements of the array in stores (of that line). However, the type of stores is not array, it is jsonb. So I want to get something like this: I have tryed
Using Subqueries to remove duplicate IDs [closed]
Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed last month. Improve this question I have 2 Tables. Table 1 holds ID1 and ID2. Table 2 holds ID2 and ID3. Table 1 has unique cases for ID1 and multiple cases
How to extract only rows matching condition ‘WHERE column1 IN column2’ (where column2 is an array)?
I am using postgresql. Let’s suppose I have this table name my_table: I want to select only the rows having the value of idm equal to one of the elements of the array in stores (of that line). So I want to get something like this: I have tryed with but I get a syntax error. Answer You need to