<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
  <channel>
    <title>CodeProject Latest postings for Database</title>
    <link>https://www.codeproject.com</link>
    <description>Latest postings for Database from CodeProject</description>
    <language>en-us</language>
    <image>
      <title>CodeProject Latest postings for Database</title>
      <url>https://www.codeproject.com/App_Themes/Std/Img/logo100x30.gif</url>
      <link>https://www.codeproject.com</link>
      <width>100</width>
      <height>30</height>
      <description>CodeProject</description>
    </image>
    <copyright>Copyright  CodeProject, 1999-2024</copyright>
    <webMaster>Webmaster@codeproject.com (Webmaster)</webMaster>
    <lastBuildDate>Wed, 08 May 2024 03:31:00 GMT</lastBuildDate>
    <ttl>20</ttl>
    <generator>C# Hand-coded goodness</generator>
    <item>
      <title>HOW TO ANSWER A QUESTION</title>
      <description>Apologies for the shouting but this is important.&lt;br /&gt;
&lt;br /&gt;
When answering a question please:&lt;br /&gt;
&lt;ol&gt;&lt;li&gt;Read the question carefully&lt;/li&gt;&lt;li&gt;Understand that English isn't everyone's first language so be lenient of bad spelling and grammar&lt;/li&gt;&lt;li&gt;If a question is poorly phrased then either ask for clarification, ignore it, or mark it down. &lt;b&gt;Insults are not welcome&lt;/b&gt;&lt;/li&gt;&lt;li&gt;If the question is inappropriate then click the 'vote to remove message' button&lt;/li&gt;&lt;/ol&gt;Insults, slap-downs and sarcasm aren't welcome. Let's work to help developers, not make them feel stupid. &lt;br /&gt;
&lt;br /&gt;
&lt;div class="ForumSig"&gt;cheers,&lt;br /&gt;
Chris Maunder&lt;br /&gt;
&lt;br /&gt;
The Code Project Co-founder&lt;br /&gt;
Microsoft C++ MVP&lt;/div&gt;</description>
      <author>Chris Maunder</author>
      <link>https://www.codeproject.com/Messages/3122383/HOW-TO-ANSWER-A-QUESTION</link>
      <pubDate>Thu, 16 Jul 2009 13:10:00 GMT</pubDate>
      <guid>3_3122383</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>How to get an answer to your question</title>
      <description>For those new to message boards please try to follow a few simple rules when posting your question.&lt;ol&gt;&lt;li&gt;&lt;b&gt;Choose the correct forum for your message&lt;/b&gt;. Posting a VB.NET question in the C++ forum will end in tears.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;&lt;b&gt;Be specific!&lt;/b&gt; Don't ask "can someone send me the code to create an application that does 'X'. Pinpoint exactly what it is you need help with.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;Keep the subject line brief, but descriptive. eg "File Serialization problem"&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;Keep the question as brief as possible. If you have to include code, include the smallest snippet of code you can.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;Be careful when including code that you haven't made a typo. Typing mistakes can become the focal point instead of the actual question you asked.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;&lt;b&gt;Do not remove or empty a message&lt;/b&gt; if others have replied. Keep the thread intact and available for others to search and read. If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;If you are posting source code with your question, place it inside &amp;lt;pre&amp;gt;&amp;lt;/pre&amp;gt; tags. We advise you also check the "Encode "&amp;lt;" (and other HTML) characters when pasting" checkbox before pasting anything inside the PRE block, and make sure "Use HTML in this post" check box is checked.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;Be courteous and DON'T SHOUT. Everyone here helps because they enjoy helping others, not because it's their job.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;Please do not post links to your question into an unrelated forum such as the lounge. It will be deleted. Likewise, do not post the same question in more than one forum.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;Do not be abusive, offensive, inappropriate or harass anyone on the boards. Doing so will get you kicked off and banned. Play nice.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;If you have a school or university assignment, assume that your teacher or lecturer is also reading these forums. &lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;No advertising or soliciting.&lt;br /&gt;
&lt;br /&gt;
&lt;/li&gt;&lt;li&gt;We reserve the right to move your posts to a more appropriate forum or to delete anything deemed inappropriate or illegal.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;
&lt;div class="signature"&gt;cheers,&lt;br /&gt;
Chris Maunder&lt;br /&gt;
&lt;br /&gt;
The Code Project Co-founder&lt;br /&gt;
&lt;div class="SmallText"&gt;Microsoft C++ MVP&lt;/div&gt;&lt;/div&gt;</description>
      <author>Chris Maunder</author>
      <link>https://www.codeproject.com/Messages/1278600/How-to-get-an-answer-to-your-question</link>
      <pubDate>Fri, 11 Nov 2005 03:30:00 GMT</pubDate>
      <guid>3_1278600</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Vb6 and sqlserver 2000</title>
      <description>Insufficient key column information  for  updating  or refreshing  problems is displayed</description>
      <author>ahmed ali Apr2021</author>
      <link>https://www.codeproject.com/Messages/6000134/Vb6-and-sqlserver-2000</link>
      <pubDate>Wed, 08 May 2024 03:31:00 GMT</pubDate>
      <guid>3_6000134</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>SQLite and Firefox Browser 68.0.2 (note: current FFB is now 72.0.2) and what I stand to lose if I update.</title>
      <description>I'm doing some development in SQLite and I have data, specifically databases a la Mozilla (the Firefox front office complex) but in order to clear my browser history, something that I think will happen automatically if I dare upgrade/update, my cache of "data" will be destroyed and all my bookmarks will be lost as well as my extensive history.&lt;br /&gt;
&lt;br /&gt;
Whether I'm right about the loss happening when I do anything to the current browser or not, does anyone know if an update will fix the SQLite functionality used by the mozilla implementation, specifically whether the "unixepoch" date/time function which was introduced around 2022 will be at my disposal?&lt;br /&gt;
&lt;br /&gt;
[EDIT]&lt;br /&gt;
"DB Browser for SQLite" tells my it's using SQLite v.3.27.2 and "unixepoch" is not there yet.&lt;br /&gt;
[END EDIT]</description>
      <author>RedDk</author>
      <link>https://www.codeproject.com/Messages/5999963/SQLite-and-Firefox-Browser-68-0-2-note-current-FFB</link>
      <pubDate>Mon, 06 May 2024 18:56:00 GMT</pubDate>
      <guid>3_5999963</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Looking for a Better Database Solution for Trading Systems</title>
      <description>I develop trading systems for stocks and other securities. To manage price data from various sources, I use a custom program written in VB.Net. This program maintains a LiteDB database for each underlying, resulting in several dozen database files.&lt;br /&gt;
&lt;br /&gt;
I've found that LiteDB is very slow when inserting large amounts of data, and since I import a significant amount of data, I'm looking for a more efficient solution. Currently, I'm considering switching to a relational DB system like SQLite or MS SQL Server.&lt;br /&gt;
&lt;br /&gt;
My data model includes a class for price data from CSV files, which contains the following fields:&lt;br /&gt;
&lt;br /&gt;
    "Identifier" (text)&lt;br /&gt;
    "TimeStamp" (date/time)&lt;br /&gt;
    "Open", "High", "Low", "Close" (single precision floating point numbers)&lt;br /&gt;
    "Size" (integer)&lt;br /&gt;
&lt;br /&gt;
The issue is that the identifier is identical for several hundred thousand data points, and the timestamps and price values often repeat. Since this data is distributed across various instruments, duplicate entries occur.&lt;br /&gt;
&lt;br /&gt;
One possible solution would be to distribute this data class across multiple tables to avoid duplicate entries. However, I'm concerned that this may cause performance issues when inserting several hundred thousand data points.&lt;br /&gt;
&lt;br /&gt;
Has anyone had similar experiences or advice to share?&lt;br /&gt;
&lt;br /&gt;
Thanks in advance!</description>
      <author>Rene Rose 2021</author>
      <link>https://www.codeproject.com/Messages/5997779/Looking-for-a-Better-Database-Solution-for-Trading</link>
      <pubDate>Sat, 20 Apr 2024 15:53:00 GMT</pubDate>
      <guid>3_5997779</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Run an external program C# from within the Oracle Developer</title>
      <description>&lt;div class='pre-lang' id='premain961850'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode961850' class='copy-code' data-index='961850' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre961850' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
Run an external program C# &lt;span class="code-sdkkeyword"&gt;from&lt;/span&gt; within the Oracle Developer and receive the &lt;span class="code-keyword"&gt;return&lt;/span&gt; values &lt;span class="code-sdkkeyword"&gt;from&lt;/span&gt; the external program&lt;/pre&gt;</description>
      <author>Member 16235420</author>
      <link>https://www.codeproject.com/Messages/5995223/Run-an-external-program-Csharp-from-within-the-Ora</link>
      <pubDate>Tue, 02 Apr 2024 20:37:00 GMT</pubDate>
      <guid>3_5995223</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Display records based on selected date range in months within same year?</title>
      <description>Greetings,&lt;br /&gt;
&lt;br /&gt;
How do I ensure that the following code only queries records that are submitted between March and May 2024?&lt;br /&gt;
&lt;br /&gt;
If a record has been submitted between the above date range, display 1. Otherwise, display 0.&lt;br /&gt;
&lt;br /&gt;
Currently, we have a code that does this but for entire year.&lt;br /&gt;
&lt;br /&gt;
In the code below, I left the code that performs this check with alias of thisYear.&lt;br /&gt;
&lt;br /&gt;
I left this line of code but commented it out just to show what we have that works except this time, we just want this check to be between March and May 2024.&lt;br /&gt;
&lt;br /&gt;
The code:&lt;br /&gt;
&lt;br /&gt;
 CASE WHEN d.dateCreated BETWEEN DATEFROMPARTS(2024, 3, 1) AND DATEFROMPARTS(2024, 5 + 1, 1) THEN 1 ELSE 0 END as thisYear&lt;br /&gt;
&lt;br /&gt;
appears to work sometimes but does not work other times. No errors but wrong results.&lt;br /&gt;
&lt;br /&gt;
That code above, temporarily replaces this line of code below as described above.&lt;br /&gt;
&lt;div class='pre-lang' id='premain491522'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode491522' class='copy-code' data-index='491522' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre491522' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
--CASE WHEN YEAR(d.dateCreated) = YEAR(getdate()) THEN &lt;span class="code-digit"&gt;1&lt;/span&gt; ELSE &lt;span class="code-digit"&gt;0&lt;/span&gt; END &lt;span class="code-keyword"&gt;as&lt;/span&gt; thisYear
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Here is the entire code:&lt;br /&gt;
&lt;br /&gt;
&lt;div class='pre-lang' id='premain811600'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode811600' class='copy-code' data-index='811600' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre811600' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
 SELECT e.Name, e.email, e.emptitle, d.dateCreated,
     CASE WHEN YEAR(d.dateSubmitted) &amp;lt; YEAR(getdate()) THEN &lt;span class="code-digit"&gt;1&lt;/span&gt; ELSE &lt;span class="code-digit"&gt;0&lt;/span&gt; END &lt;span class="code-keyword"&gt;as&lt;/span&gt; previousYear,
     --CASE WHEN YEAR(d.dateSubmitted) = YEAR(getdate()) THEN &lt;span class="code-digit"&gt;1&lt;/span&gt; ELSE &lt;span class="code-digit"&gt;0&lt;/span&gt; END &lt;span class="code-keyword"&gt;as&lt;/span&gt; thisYear
 CASE WHEN d.dateSubmitted BETWEEN DATEFROMPARTS(&lt;span class="code-digit"&gt;2024&lt;/span&gt;, &lt;span class="code-digit"&gt;3&lt;/span&gt;, &lt;span class="code-digit"&gt;1&lt;/span&gt;) AND DATEFROMPARTS(&lt;span class="code-digit"&gt;2024&lt;/span&gt;, &lt;span class="code-digit"&gt;5&lt;/span&gt; + &lt;span class="code-digit"&gt;1&lt;/span&gt;, &lt;span class="code-digit"&gt;1&lt;/span&gt;) THEN &lt;span class="code-digit"&gt;1&lt;/span&gt; ELSE &lt;span class="code-digit"&gt;0&lt;/span&gt; END &lt;span class="code-keyword"&gt;as&lt;/span&gt; thisYear
FROM Employees e
INNER JOIN dateDetails d on e.employeeID = d.employeeID
WHERE e.employeeID = someID
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
I have also tried this:&lt;br /&gt;
&lt;div class='pre-lang' id='premain108727'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode108727' class='copy-code' data-index='108727' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre108727' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
CASE WHEN d.dateSubmitted &amp;gt;= DATEFROMPARTS(&lt;span class="code-digit"&gt;2024&lt;/span&gt;, &lt;span class="code-digit"&gt;3&lt;/span&gt;, &lt;span class="code-digit"&gt;1&lt;/span&gt;) AND d.dateSubmitted &amp;lt;  DATEFROMPARTS(&lt;span class="code-digit"&gt;2024&lt;/span&gt;,&lt;span class="code-digit"&gt;5&lt;/span&gt; + &lt;span class="code-digit"&gt;1&lt;/span&gt;, &lt;span class="code-digit"&gt;1&lt;/span&gt;)&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Same inconsistent result.&lt;br /&gt;
&lt;br /&gt;
I guess my question is why does this work perfectly:&lt;br /&gt;
&lt;div class='pre-lang' id='premain375800'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode375800' class='copy-code' data-index='375800' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre375800' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
CASE WHEN YEAR(d.dateSubmitted) = YEAR(getdate()) THEN &lt;span class="code-digit"&gt;1&lt;/span&gt; ELSE &lt;span class="code-digit"&gt;0&lt;/span&gt; END &lt;span class="code-keyword"&gt;as&lt;/span&gt; thisYear&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
but the date range does not work well?&lt;br /&gt;
&lt;br /&gt;
Thanks in advance for your help.</description>
      <author>samflex</author>
      <link>https://www.codeproject.com/Messages/5983624/Display-records-based-on-selected-date-range-in-mo</link>
      <pubDate>Sun, 21 Jan 2024 20:28:00 GMT</pubDate>
      <guid>3_5983624</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>time-consuming insert operation</title>
      <description>Let's say you have a table with an index on the field "username".&lt;br /&gt;
&lt;br /&gt;
Is it true that eventually you'll have some really time-consuming inserts when the hash table has to resize itself?&lt;br /&gt;
&lt;br /&gt;
Hash table resize is O(n), I think.&lt;br /&gt;
&lt;br /&gt;
Thanks.</description>
      <author>mike7411</author>
      <link>https://www.codeproject.com/Messages/5983258/time-consuming-insert-operation</link>
      <pubDate>Fri, 19 Jan 2024 03:25:00 GMT</pubDate>
      <guid>3_5983258</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>CREATE INDEX</title>
      <description>I was looking at the documentation for CREATE INDEX in SQL:&lt;br /&gt;
&lt;br /&gt;
&lt;a href="https://www.w3schools.com/sql/sql_create_index.asp"&gt;https://www.w3schools.com/sql/sql_create_index.asp&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class='pre-lang' id='premain596957'&gt;&lt;div&gt;SQL&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode596957' class='copy-code' data-index='596957' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre596957' style='margin-top:0;' class='lang-sql' data-language='SQL' data-allowShrink='True' data-collapse='False'&gt;
&lt;span class="code-keyword"&gt;CREATE&lt;/span&gt; &lt;span class="code-keyword"&gt;INDEX&lt;/span&gt; index_name
&lt;span class="code-keyword"&gt;ON&lt;/span&gt; table_name (column1, column2, ...);&lt;/pre&gt;&lt;br /&gt;
I don't understand when you would create it for multiple columns.  Let's say you did this:&lt;br /&gt;
&lt;br /&gt;
&lt;div class='pre-lang' id='premain830643'&gt;&lt;div&gt;SQL&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode830643' class='copy-code' data-index='830643' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre830643' style='margin-top:0;' class='lang-sql' data-language='SQL' data-allowShrink='True' data-collapse='False'&gt;
&lt;span class="code-keyword"&gt;CREATE&lt;/span&gt; &lt;span class="code-keyword"&gt;INDEX&lt;/span&gt; idx_pname &lt;span class="code-keyword"&gt;ON&lt;/span&gt; Persons (LastName, FirstName);&lt;/pre&gt;&lt;br /&gt;
Does that create one index on two columns?  Or, is that the same as creating two indexes?&lt;br /&gt;
&lt;br /&gt;
For instance, does that statement create two hashtables?  Or one hashtable?&lt;br /&gt;
&lt;br /&gt;
Thank you.</description>
      <author>mike7411</author>
      <link>https://www.codeproject.com/Messages/5983060/CREATE-INDEX</link>
      <pubDate>Thu, 18 Jan 2024 04:22:00 GMT</pubDate>
      <guid>3_5983060</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>SQL behind the scenes</title>
      <description>Let's say you have a SQL database with a table called USERS.&lt;br /&gt;
&lt;br /&gt;
Let's say it has 500,000 users in it.&lt;br /&gt;
&lt;br /&gt;
Let's say you do this:&lt;br /&gt;
&lt;br /&gt;
&lt;div class='pre-lang' id='premain324620'&gt;&lt;div&gt;SQL&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode324620' class='copy-code' data-index='324620' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre324620' style='margin-top:0;' class='lang-sql' data-language='SQL' data-allowShrink='True' data-collapse='False'&gt;
&lt;span class="code-keyword"&gt;SELECT&lt;/span&gt; PASSWORD &lt;span class="code-keyword"&gt;FROM&lt;/span&gt; USERS &lt;span class="code-keyword"&gt;WHERE&lt;/span&gt; USER=&lt;span class="code-string"&gt;&amp;#39;&lt;/span&gt;&lt;span class="code-string"&gt;bill.gates&amp;#39;&lt;/span&gt;;&lt;/pre&gt;&lt;br /&gt;
Let's say there's no indices on the table.&lt;br /&gt;
&lt;br /&gt;
Does the database just do a linear search thru each user?&lt;br /&gt;
&lt;br /&gt;
Thank you.</description>
      <author>mike7411</author>
      <link>https://www.codeproject.com/Messages/5982870/SQL-behind-the-scenes</link>
      <pubDate>Wed, 17 Jan 2024 04:02:00 GMT</pubDate>
      <guid>3_5982870</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Sql Server Database goes into Recovery mode</title>
      <description>I have a window based application that creates new database every month programmatically and in that database i have single table which consists of 50 columns which also . But the problem is after crating database programmatically it falls in recovery mode. So my question is Why database falls in recovery mode.</description>
      <author>Nilesh M. Prajapati</author>
      <link>https://www.codeproject.com/Messages/5973593/Sql-Server-Database-goes-into-Recovery-mode</link>
      <pubDate>Sat, 18 Nov 2023 04:59:00 GMT</pubDate>
      <guid>3_5973593</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>SQLite Thread Safety</title>
      <description>The SQLite documentation says that SQLite is thread safe for reading but not for writing. Specifically, they say you can have multiple threads reading from the DB, but only one thread should write at one time.&lt;br /&gt;
&lt;br /&gt;
Do you think this means that I should also avoid two threads accessing the DB at one time if one of the threads is reading and the other is writing?&lt;br /&gt;
&lt;br /&gt;
IOW, does reading need to be serialized as well?&lt;br /&gt;
&lt;div class="signature"&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The difficult we do right away...&lt;br /&gt;
...the impossible takes slightly longer.&lt;/div&gt;</description>
      <author>Richard Andrew x64</author>
      <link>https://www.codeproject.com/Messages/5972449/SQLite-Thread-Safety</link>
      <pubDate>Fri, 10 Nov 2023 23:23:00 GMT</pubDate>
      <guid>3_5972449</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>SQLite syntax error that I can't figure out - SOLVED</title>
      <description>I'm pulling my hair with this one:&lt;br /&gt;
(There's a unique index on the [DOMAIN] field.&lt;br /&gt;
&lt;div class='pre-lang' id='premain28313'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode28313' class='copy-code' data-index='28313' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre28313' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
INSERT INTO DNSLOG ([DATETIME], [DOMAIN], [BLOCKED]) VALUES (&lt;span class="code-digit"&gt;133436157350078746&lt;/span&gt;, &lt;span class="code-string"&gt;&amp;#39;&lt;/span&gt;&lt;span class="code-string"&gt;optimizationguide-pa.googleapis.com.&amp;#39;&lt;/span&gt;, &lt;span class="code-digit"&gt;0&lt;/span&gt;) 
ON CONFLICT (DOMAIN) DO 
UPDATE DNSLOG 
SET HITCOUNT = HITCOUNT + &lt;span class="code-digit"&gt;1&lt;/span&gt; 
WHERE DOMAIN = &lt;span class="code-string"&gt;&amp;#39;&lt;/span&gt;&lt;span class="code-string"&gt;optimizationguide-pa.googleapis.com.&amp;#39;&lt;/span&gt;&lt;/pre&gt;The error is clearly in the ON CONFLICT clause because when I run only the INSERT clause, it does what it's supposed to do. And the UPDATE statement works when I run it by itself.&lt;br /&gt;
&lt;br /&gt;
The actual error message is "SQL Logic error near "DNSLOG" syntax error".&lt;br /&gt;
&lt;br /&gt;
Any idea what the syntax error could be?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
****SOLUTION****&lt;br /&gt;
&lt;br /&gt;
It's not supposed to have the table name in the "DO UPDATE" statement. IOW:&lt;br /&gt;
&lt;br /&gt;
&lt;div class='pre-lang' id='premain523109'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode523109' class='copy-code' data-index='523109' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre523109' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
INSERT INTO DNSLOG ([DATETIME], [DOMAIN], [BLOCKED]) VALUES (&lt;span class="code-digit"&gt;133436157350078746&lt;/span&gt;, &lt;span class="code-string"&gt;&amp;#39;&lt;/span&gt;&lt;span class="code-string"&gt;optimizationguide-pa.googleapis.com.&amp;#39;&lt;/span&gt;, &lt;span class="code-digit"&gt;0&lt;/span&gt;) 
ON CONFLICT (DOMAIN) DO 
UPDATE SET HITCOUNT = HITCOUNT + &lt;span class="code-digit"&gt;1&lt;/span&gt; 
WHERE DOMAIN = &lt;span class="code-string"&gt;&amp;#39;&lt;/span&gt;&lt;span class="code-string"&gt;optimizationguide-pa.googleapis.com.&amp;#39;&lt;/span&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;div class="signature"&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The difficult we do right away...&lt;br /&gt;
...the impossible takes slightly longer.&lt;/div&gt;</description>
      <author>Richard Andrew x64</author>
      <link>https://www.codeproject.com/Messages/5971227/SQLite-syntax-error-that-I-cant-figure-out-SOLVED</link>
      <pubDate>Sun, 05 Nov 2023 00:09:00 GMT</pubDate>
      <guid>3_5971227</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>please</title>
      <description>I would like to have a blank database already written. The list is for monthly entry and exit. Thank you all</description>
      <author>daw htikehtike</author>
      <link>https://www.codeproject.com/Messages/5968573/please</link>
      <pubDate>Sun, 22 Oct 2023 05:17:00 GMT</pubDate>
      <guid>3_5968573</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Getting Last Record and First Record from a Record Set (SQL server DB)</title>
      <description>I am pretty new using MS SQL. I perform a query over some SQL server table; it returns a record set; but I need to read the last record just to get the value of a certain column.&lt;br /&gt;
&lt;br /&gt;
This is my procedure:&lt;br /&gt;
&lt;div class='pre-lang' id='premain652742'&gt;&lt;div&gt;PHP&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode652742' class='copy-code' data-index='652742' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre652742' style='margin-top:0;' class='lang-php' data-language='PHP' data-allowShrink='True' data-collapse='False'&gt;
&lt;span class="code-sdkkeyword"&gt;$connectionInfo&lt;/span&gt; = array( &lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;Database"&lt;/span&gt;=&amp;gt;$myDB, &lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;UID"&lt;/span&gt;=&amp;gt;$myUser , &lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;PWD"&lt;/span&gt;=&amp;gt;$myPass);
&lt;span class="code-sdkkeyword"&gt;$conn&lt;/span&gt; = sqlsrv_connect( $myServer, $connectionInfo);

&lt;span class="code-sdkkeyword"&gt;$query&lt;/span&gt; = &lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;SELECT * FROM( SELECT col0, col1, col2, col3 FROM t1 LEFT JOIN t2 ON t1.col1 = t2.col1 LEFT JOIN t3 ON t1.col2 = t3.col2) AS t ORDER BY t.col0; "&lt;/span&gt;;
&lt;span class="code-sdkkeyword"&gt;$rec_set&lt;/span&gt; = sqlsrv_query($connection, $query, array(), array(&lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;Scrollable"&lt;/span&gt; =&amp;gt; &lt;span class="code-string"&gt;&amp;#39;&lt;/span&gt;&lt;span class="code-string"&gt;buffered&amp;#39;&lt;/span&gt;));

if( &lt;span class="code-sdkkeyword"&gt;$rec_set&lt;/span&gt; === false ) die( print_r( sqlsrv_errors(), true));  

&lt;span class="code-sdkkeyword"&gt;$connectionInfo&lt;/span&gt; = array( &lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;Database"&lt;/span&gt;=&amp;gt;$myDB,  UID&lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;=&amp;gt;$myUser , "&lt;/span&gt;PWD&lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;=&amp;gt;$myPass);
$conn = sqlsrv_connect( $myServer, connectionInfo);

$query = "&lt;/span&gt;SELECT * FROM( SELECT col0, col1, col2, col3 FROM t1 LEFT JOIN t2 ON t1.col1 = t2.col1 LEFT JOIN t3 ON t1.col2 = t3.col2) AS t ORDER BY t.col0; &lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt;;

$rec_set = sqlsrv_query($connection, $query, array(),  array("&lt;/span&gt;Scrollable&lt;span class="code-string"&gt;"&lt;/span&gt;&lt;span class="code-string"&gt; =&amp;gt; &amp;#39;buffered&amp;#39;));
if( $rec_set === false ) die( print_r( sqlsrv_errors(), true));	
			 
$row_count = sqlsrv_num_rows($rec_set);
if ($row_count === false) die( print_r( sqlsrv_errors(), true));

$reg   = sqlsrv_fetch_array( $rec_set, SQLSRV_FETCH_ASSOC, 0);
$first = $reg[&amp;#39;column_name&amp;#39;];

$reg   = sqlsrv_fetch_array( $rec_set, SQLSRV_FETCH_ASSOC, $row_count - 1);
$last  = $reg[&amp;#39;column_name&amp;#39;];&lt;/span&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
It is clear that the sqlsrv_fetch_array DOES NOT work like that. Does anyone know how to achieve my goal, that is, getting last and first records from that record set without generating another SELECT? &lt;br /&gt;
Thank you in advance.</description>
      <author>Member 11843356</author>
      <link>https://www.codeproject.com/Messages/5963582/Getting-Last-Record-and-First-Record-from-a-Record</link>
      <pubDate>Thu, 21 Sep 2023 18:07:00 GMT</pubDate>
      <guid>3_5963582</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>prior action plan to prevent sql database corruption</title>
      <description>prior action plan to prevent sql database corruption&lt;br /&gt;
DISTINCT alternatives in sql query&lt;br /&gt;
conversion of query scan to seek</description>
      <author>Kar_Malay</author>
      <link>https://www.codeproject.com/Messages/5960170/prior-action-plan-to-prevent-sql-database-corrupti</link>
      <pubDate>Sat, 02 Sep 2023 06:01:00 GMT</pubDate>
      <guid>3_5960170</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Fetch row and display in frontend column</title>
      <description>I have 5 tables in my db, I used one form to saved into 4 of them at once. I want the 5th one to be used as a master where I can store the foreign key and be used to display to a table in the frontend. &lt;br /&gt;
How do I make all of them add one ID?&lt;br /&gt;
How can I display a table row as a column in the frontend?</description>
      <author>Kesiena</author>
      <link>https://www.codeproject.com/Messages/5959040/Fetch-row-and-display-in-frontend-column</link>
      <pubDate>Sat, 26 Aug 2023 13:14:00 GMT</pubDate>
      <guid>3_5959040</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Multi-user use the database at the same time</title>
      <description>When we have multiple users, What's the best way connect(logging, query on tables,...) to database?&lt;br /&gt;
&lt;br /&gt;
Which is better and why?&lt;br /&gt;
&lt;br /&gt;
1) Create users(DB User) in the SQL Server for each user(Windows App User).&lt;br /&gt;
&lt;br /&gt;
2) Create a table which is fill with all App user and just connect to SQL Server with a user and query on that table.</description>
      <author>Siavash.BRY</author>
      <link>https://www.codeproject.com/Messages/5956539/Multi-user-use-the-database-at-the-same-time</link>
      <pubDate>Sat, 12 Aug 2023 09:49:00 GMT</pubDate>
      <guid>3_5956539</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Tough one</title>
      <description>I can't figure out the following:&lt;br /&gt;
&lt;br /&gt;
I have order header and detail tables with UPC codes and the order numbers they belong to. There can be many different UPC codes for each order. The Order IDs are in the header table and the UPC codes are in the detail table.&lt;br /&gt;
&lt;br /&gt;
I must find UPC codes that have been used for more than one order, in other words, where the same UPC code exists for two or more distinct orders.&lt;br /&gt;
&lt;br /&gt;
I have tried:&lt;br /&gt;
&lt;br /&gt;
&lt;div class='pre-lang' id='premain204470'&gt;&lt;div&gt;&lt;/div&gt;&lt;div class='pre-action-link'&gt;&lt;span id='copycode204470' class='copy-code' data-index='204470' style='visibility:hidden'&gt;&lt;svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' viewBox='0 0 460 460' style='width: 16px;height:16px;' xml:space='preserve'&gt;&lt;g&gt;&lt;path d='M425.934,0H171.662c-18.122,0-32.864,14.743-32.864,32.864v77.134h30V32.864c0-1.579,1.285-2.864,2.864-2.864h254.272     c1.579,0,2.864,1.285,2.864,2.864v254.272c0,1.58-1.285,2.865-2.864,2.865h-74.729v30h74.729 c18.121,0,32.864-14.743,32.864-32.865V32.864C458.797,14.743,444.055,0,425.934,0z'&gt;&lt;/path&gt;&lt;path d='M288.339,139.998H34.068c-18.122,0-32.865,14.743-32.865,32.865v254.272C1.204,445.257,15.946,460,34.068,460h254.272 c18.122,0,32.865-14.743,32.865-32.864V172.863C321.206,154.741,306.461,139.998,288.339,139.998z M288.341,430H34.068    c-1.58,0-2.865-1.285-2.865-2.864V172.863c0-1.58,1.285-2.865,2.865-2.865h254.272c1.58,0,2.865,1.285,2.865,2.865v254.273h0.001 C291.206,428.715,289.92,430,288.341,430z'&gt;&lt;/path&gt;&lt;/g&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;
&lt;pre id='pre204470' style='margin-top:0;' data-allowShrink='True' data-collapse='False'&gt;
SELECT OD.UPC, OH.OrderId, COUNT(DISTINCT OH.OrderId) [COUNT]
FROM OrderDetail OD
LEFT JOIN OrderHeader OH ON OH.OrderHeaderId = OD.OrderHeaderId
GROUP BY OD.UPC, OH.OrderId
HAVING COUNT(DISTINCT OH.OrderId) &amp;gt; &lt;span class="code-digit"&gt;1&lt;/span&gt;&lt;/pre&gt;But this query returns nothing and I'm not sure if it's because there are no duplicate orders or because the query is wrong.&lt;br /&gt;
&lt;br /&gt;
Any help will be tremendously appreciated. Thank you.&lt;br /&gt;
&lt;div class="signature"&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The difficult we do right away...&lt;br /&gt;
...the impossible takes slightly longer.&lt;/div&gt;</description>
      <author>Richard Andrew x64</author>
      <link>https://www.codeproject.com/Messages/5954666/Tough-one</link>
      <pubDate>Mon, 31 Jul 2023 14:59:00 GMT</pubDate>
      <guid>3_5954666</guid>
      <subject>Database</subject>
    </item>
    <item>
      <title>Why do some websites provide Demo for their premium html themes while the codes can be seen using inspection tool in chrome?</title>
      <description>There are some website that provide Demos for their premium Html/css/javascript themes while we can see and copy the source code without paying anything. Why?&lt;br /&gt;
Why don't they only provide a snapshot of the website theme to prevent any illegal copy?</description>
      <author>Alex Dunlop</author>
      <link>https://www.codeproject.com/Messages/5951631/Why-do-some-websites-provide-Demo-for-their-premiu</link>
      <pubDate>Tue, 11 Jul 2023 16:30:00 GMT</pubDate>
      <guid>3_5951631</guid>
      <subject>Database</subject>
    </item>
  </channel>
</rss>