dns hosting – Pointing a custom domain to Azure Web App – Without the need of adding verification records

I have a website running on Azure Web App. This website provides a profile page to its users. The users are looking to point their custom domains to their respective profile page. I want to minimize the manual steps to achieve this. For every custom domain, I need to add that manually to Azure Web app and also need to verify the ownership via TXT record. This could be fine for a small number of custom domains but when you have 100s of such users, it just becomes a blocker.

Is there any way I could somehow let any custom domain pointed to my website work without needing to add the domain record on Azure portal and having to verify ownership?

I wonder if Azure DNS can help me achieve my goal in anyway.

design patterns – Interfacing with records on remote DB from localhost Application Logic

There are times when I have to fix/update records on a Production and/or Staging environment for a Web App. These are remote DBs.

Rather than push application code to fix the data, I’ve been “interfacing” my localhost’s version of the running app with the remote DBs. I can do this by simply changing an ENV var for the DB URI.

I’m doing this as opposed to shelling into DB and updating records because I need some actual code to massage data too.

Any insights on this pattern? Thanks!

backup – SQL Server: Should the same log records be backed up multiple times?

I came to SQL Server database administration from an Oracle DBA background. So maybe naturally, I always try to understand the differences between the two DBMSs as well as the similarities. One question that have struck me recently is that, should the log records be backed up multiple times, and how? In Oracle database, assuming the database is in the “Archive-Log” database mode, the “redo” log files are archived as separate “archived redo log” files, whose role will be critical in case of a point-in-time recovery scenario, and so because of that, it’s very important for these files to be backed up regularly. Often times, DBAs take multiple backups of each “archived redo log” file so that if, for example, a particular tape is lost or damaged, there would still be another copy of the same backup available somewhere else on some other backup device. This will obviously provide a high level of protection against a data loss.

In SQL Server, as we know, there are transaction logs containing log records, which play avital role for performing database recovery. Now my question is this: for a database that is on the “FULL” recover model, would it be possible to backup the log records multiple times? And if possible, would it be a good idea? And how that can be done?

nameserver – Are NS records for a .com domain stored by the registrar or the .com registry?

Let’s say I own example.com, that I bought by ExampleRegistrar.
Let’s say that, by default, this registrar uses their own nameservers ns1.exampleregistrar.com, ns2.exampleregistrar.com.

Thus, when a client wants to browse to www.example.com, it probably goes like this:

  • root DNS servers looks for .com nameserver
  • .com nameserver looks for example.com, it sees ns1.exampleregistrar.com and passes the request to this nameserver
  • ns1.exampleregistrar.com looks for www.example.com and finally finds IP which it gives to the client.

Question: how does it work if I configure a custom nameserver ns1.othernameserver.com in the registrar domain’s settings?

Does this mean the registry for .com will directly have ns1.othernameserver.com in its database?

Is it correct that, then, any request from a client to www.example.com will never go through any of the registrar’s servers?

The query is giving 100000 records instead of only 13 records. Need the suggestion regarding this query [closed]

select  nvl(a.acct_no, 'NIL') as acct_no,
nvl(a.cont_no, 'NIL') as cont_no,
nvl(a.cust_name,f.cust_name) as cust_name,
nvl(a.cust_id,f.cust_id) as cust_id,
c.sub_no as phon_no, 
from   temp_hl_on_order b inner join temp_hl_on_od c
on b.order_status = c.on_status and b.order_status <> 'CN' 
and b.order_no = c.order_no and b.order_status = c.on_status
inner join temp_csm016 a
on a.acct_no = b.acct_no and a.cont_no = b.cont_no 
inner join temp_line_job_queue d
on c.order_no = d.order_no and c.sub_no = d.sub_no
left outer join temp_hl_on_apply f
on b.appl_no = f.appl_no
and b.order_status <> 'CN'
and c.sub_no in (
select b.ref_phone_no from img.dm_doc_imag a join img.dm_np_doc_assoc b on a.doc_id = b.doc_id
where b.doc_id like '20091106%');

query – MariaDB: Insert records (list of tuples) into table if not exists

Currently I have several sql queries that look like this:

INSERT INTO `test` (col1, col2)
SELECT * FROM (SELECT '1','2') AS tmp
    SELECT * FROM `test`
    WHERE col1='1' AND col2='2'
) LIMIT 1;

INSERT INTO `test` (col1, col2)
SELECT * FROM (SELECT '3','4') AS tmp
    SELECT * FROM `test`
    WHERE col1='3' AND col2='4'
) LIMIT 1;

Generally speaking, as rule of thumb the less queries the better which is why I want to rewrite the sql queries into one query. This should make it even faster when having millions of datasets as the WHERE clause would only iterate through the table once, hence this should be possible:

WHERE col1 in ('1','3') AND col2 in ('2','4')

But when I try multiple select statements in a single query like:

(SELECT '1','2') AS tmp1,
(SELECT '3','4') AS tmp2

SQL throws this error:

#1136 - Column count doesn't match value count at row 1

The problem is with SELECT * FROM (SELECT '1','2') AS tmp.

How can I use several tuples (1, 2) (3, 4) in the subquery for it meet the WHERE condition?

Is there a shorter and faster way to achieve this?

Any feedback is highly appreciated!

Please ignore the data types; the numbers should be formatted as int not as varchar.

database – Data structures – prioritizing records based on pending actions

I need to add a priority column to an orders database to sort them, which will vary depending on what has already been done (actions taken). The other catch is: there are two different roles that will have both shared and exclusive actions so the priority changes depending on who is viewing the order list.

Profile 1
Approve order   - Highest priority
Review options  - Second highest
Processing      - Third highest (shared)
Other actions   - Low priority, no sorting impact

Profile 2
Confirm order   - Highest priority
Processing      - Second highest (shared)
Other actions   - Low priority, no sorting impact

I thought about assigning numeric values to them and adding a total but that will not work since I have separate actions. I’ve also thought about a numeric string (something along the lines of 554421) which will be changed each time an action is taken. The problem is, it might get messy if in the future more actions are available with different priorities. What would be a better apporach?