Best Practice for full backup and transaction log truncation
DBA Stack Exchange
by ab san
1d ago
I am new to SQL Server DB. Could someone please let me know what would be the best practice to do a full backup and truncate the transaction log. If you could please let me know the strategy you are using in your company, that would give me some idea and help me learn from the documentation. I would also like to know if there is any white paper or article that explains with examples ..read more
Visit website
Log_reuse_time_desc is ACTIVE_BACKUP_OR_RESTORE
DBA Stack Exchange
by Abdelrahman Mamdouh
1d ago
After dropping database replication and subscriber, the database's option log_resue_wait_desc turned from replication to ACTIVE_BACKUP_OR_RESTORE. I should I do to return it into NOTHING value ..read more
Visit website
How to store historical correlation matrices?
DBA Stack Exchange
by futium
1d ago
Every day we calculate the correlation between ~40 different financial instruments and want to be able to store them in our PostgreSQL database. What would be the best way of storing these values? We would prefer to have one table that includes all of this information instead of one table for each instrment's correlation with the rest. We were thinking of having each column be the correlation between an instrument and another say [corr(a,b), corr(a,c), corr(b,c)] but this looks would cause issues when we need to access the values if new instruments are added. Are there any typical ways this is ..read more
Visit website
Is this a good definition of schema migration?
DBA Stack Exchange
by Joel
1d ago
I'm trying to preserve the meaning of the English word 'migration' in the definition, and I think I might be able to do that without making up a fake definition. Here goes: A schema migration is the change of a database's schema from one state to another through time, as is distinct from the more general definition of data migration, in which data is moved from one location to another. Anyway, this is basically original research, because it's hard to find these kinds of definitions sometimes. So I'd really appreciate some expert feedback ..read more
Visit website
Finalize GroupAggregate parent using Partial HashAggregate child nodes in Postgres query plan
DBA Stack Exchange
by ahron
1d ago
I have seen in some query plans that the parent is a Finalize GroupAggregate but its child nodes are Partial HashAggregates. When does this make sense? As an example, I have a query that resembles something like: =# SELECT x, count(*) AS n FROM t GROUP BY x ; There is no sorting involved, so why does it choose a GroupAggregate at the top? And why are the parallel workers using HashAggregate? "Finalize GroupAggregate (cost=44630.76..47219.48 rows=10218 width=24) (actual time=270.025..309.145 rows=27909 loops=1)" " Group Key: x" " -> Gather Merge (cost=44630.76..47015.12 rows=20436 wi ..read more
Visit website
Unresponsive restore process for log shipped db having memory optimised tables
DBA Stack Exchange
by variable
1d ago
Log shipping documentation has a caution: https://learn.microsoft.com/en-us/sql/database-engine/log-shipping/about-log-shipping-sql-server?view=sql-server-ver16 Known issue: For databases with memory-optimized tables, performing a transactional log backup with no recovery, and later executing a transaction log restore with recovery, may result in an unresponsive database restore process. This issue can also affect log shipping functionality. To work around this problem, the SQL Server instance can be restarted before initiating the restore process. I have a log shipped db with memory optimiz ..read more
Visit website
Point in time Postgres restore
DBA Stack Exchange
by Руслан Пилипюк
1d ago
I was trying to do Point in Time Restore, I had my placed by previously backed up WAL file in my directory to where my restore command (/var/lib/postgresql/16/main/pg_wal/wal_archive) in postgres.conf points to, however my WAL files changes have not been applied: listen_addresses = '*' wal_level = replica max_connections = 100 archive_mode = on archive_command = 'test ! -f /var/lib/postgresql/16/main/pg_wal/wal_archive/%f && cp %p /var/lib/postgresql/16/main/pg_wal/wal_archive/%f' restore_command = 'cp /var/lib/postgresql/16/main/pg_wal/wal_archive/%f %p' #max_wal_senders = 10 #wal_lo ..read more
Visit website
List of characters managed by a collation
DBA Stack Exchange
by yaki_nuka
1d ago
I'm migrating to MySQL 8.0.33. We are changing character set to utf8mb4. For collation, I'm wondering among different options. I'm looking for documentation to review the list of characters that are "covered", "managed" or "included" in a collation. For example, I don't know if I can have some troubles with À in a WHERE clause comparison in some collation. So, I'd like to look for if À is covered or managed by a collation. Other way to make the question. I found this link, but it's old for me: https://collation-charts.org/mysql60/mysql604.utf8_spanish_ci.html I'd like to find something like th ..read more
Visit website
Why does restoring a database on a different server bring in the backup info into the msdb db of new server?
DBA Stack Exchange
by variable
1d ago
I restored a db to a different SQL server but interestingly the msdb backupset tables on this server are showing the db backup history from the source server. Is this expected? Note: I have not restored msdb. Steps to reproduce: On source server perform full backup, followed by couple of log backups. On destination server, using the database restore UI, perform restore of the full backup and log backups. Fire below query on destination server and you will see the full and log backup history (from source server) of this db appear here. Query: SELECT CONVERT(CHAR(100), SERVERPROPERTY('Ser ..read more
Visit website
What context does the agent service account use (logon account or the NT SERVICESQLSERVERAGENT)?
DBA Stack Exchange
by variable
1d ago
My SQL server agent service account is running under the following domain user account: mydomain\svc_svr1_sql_agent I have a ssis package that must be able to read/write files in a folder. The ssis package is invoked by a SQL agent job. The execution context (the execute as drop-down) is the SQL server agent service account (I am not using the proxy/credentials approach). Should I configure the folder permissions for agent service account mydomain\svc_svr1_sql_agent or the agent virtual account NT SERVICE\SQLSERVERAGENT or both? The reason for asking this question is that, based on What are th ..read more
Visit website

Follow DBA Stack Exchange on FeedSpot

Continue with Google
Continue with Apple
OR