Questions tagged [row]
The row tag has no summary.
71 questions
-1
votes
1
answer
149
views
MySQL 8.0.41 - 83 % Waiting for row lock on AO_319474_QUEUE
Environment
We run three Jira Service Management DC clusters that all share the same topology:
MySQL 8.0.36 on Ubuntu 22.04 – 32 vCPU, 100 GB RAM, buffer-pool now 80 GB (only ~33 GB in use), NVMe ...
2
votes
1
answer
273
views
How can I paginate when ordering by `date_bin`?
I have the following query
SELECT u.update_time, about_me
FROM users u
ORDER BY date_bin('14 days', u.update_time, '2023-04-07 23:11:56.471560Z') DESC, LENGTH(u.about_me) DESC, u.user_id;
I get the ...
1
vote
3
answers
3k
views
Postgresql: Trigger is not working at times
I have a PostgreSQL trigger that is not firing sometimes, even though the status is always shown as "enabled".
My trigger code is as follows:
CREATE OR REPLACE FUNCTION audit_src_exhibit() ...
0
votes
1
answer
687
views
Postgresql: Trigger is not working at times
I have a PostgreSQL trigger that is not firing sometimes, even though the status is always shown as "enabled".
My trigger code is as follows:
CREATE OR REPLACE FUNCTION audit_src_exhibit() ...
1
vote
1
answer
707
views
Best way to cast a VIEW row type to the underlying TABLE row type
I have a table with an index and a row-level security policy. Due to this problem (more details: 1, 2, 3, 4, 5), the index is not used when the policy applies, which makes my queries unbearably slow.
...
1
vote
2
answers
1k
views
Rownum equivalent in Informix SQL?
I want to explore (=looking at the first 100 rows) databases using the Informix SQL dialect.
In Oracle SQL I would use SELCT* FROM table_name WHERE ROWNUM < 100
In Postgress SQL I would use SELCT* ...
2
votes
1
answer
99
views
Insert rows into a table from another table row?
I've got a table Schedule
Id
unserId
Sunday
Monday
Tuesday
Wednesday
Thursday
Friday
Saturday
0
10
0
1
1
1
1
0
0
1
20
1
0
0
0
0
0
0
I need to insert lines from one row in table Schedule into seven ...
4
votes
5
answers
6k
views
How to update table records in reverse order?
I've a table Student
Id Name Mark
1 Medi 10
2 Ibra 15
3 Simo 20
and I want to update it, where I want to reverse it in descending order only Name and Mark and keep Id in its order:
...
0
votes
2
answers
4k
views
How to limit the number of rows in a mysql table
How can I set a limit of rows to a mysql table? (I am using php)
POSSIBLE METHOD-1:
When the user tries to SIGN-UP I can select everything from the TABLE and get the number of ROWS in the TABLE and ...
-2
votes
1
answer
1k
views
split a row value according to a specific column
I have total value in table A and need to get row value in table B until reached value in table A.
Table A
ID
Available
1
99
2
0
Table B
ID
Rack
RequiredQty
1
A
60
1
B
102
1
C
8
2
A
10
Expected ...
-2
votes
1
answer
1k
views
Count rows from multiple tables with similar names
I want to have 2 columns: Table Name and Row Count
When I run this, I get 12 table names in my database. How do I then count the rows in each one without having to union 12 count queries together:
...
0
votes
1
answer
84
views
Can analytic functions add or remove rows from a resultset?
I'm a novice who is starting to learn about Oracle analytic functions (window functions).
I know from experience that it's important to fully understand how SQL mechanisms work when using them in ...
0
votes
1
answer
240
views
MySQL 8.0.20 - Master Replica scheme, errors during replication process
This threads follows a previous one, given at this URL: MySQL 8.0.20 - Master Replica scheme, increasing delay between Source and Replica
Replica Server has been configured this way, which ensures a ...
3
votes
1
answer
6k
views
How to check for row lock level when FOR UPDATE is used in PostgreSQL?
Related to previous question here
From the pg_locks documentation, row level lock information is not available when FOR UPDATE is used in a SELECT statement.
Is there any way to check for row level ...
1
vote
2
answers
385
views
Mysql: Query which orders by default and rank (pin/hold up entries?)
I have a products table which contains all my products. Those products table gets filled permanently with new products. However, I want to have the possibility to "hold up"/"pin" ...