Skip to content
Code Project
CODE PROJECT For Those Who Code

Database

Discussions on database access, SQL, and ADO

This category can be followed from the open social web via the handle database@forum.codeproject.com

17.1k Topics 61.8k Posts
  • How rollback tran in while loop

    help tutorial announcement
    2
    0 Votes
    2 Posts
    0 Views
    P
    Use Try Catch block and in catch block write statement rollback tran this may work for you easily
  • javascript calculation total not working

    javascript html com sales tools
    3
    0 Votes
    3 Posts
    0 Views
    E
    Sorry for posting in the wrong area. I corrected this by post in the suggested area of Web Development. Thank you for correcting me. Evan
  • SQL Server re-installs when already installed

    database sql-server sysadmin
    2
    0 Votes
    2 Posts
    0 Views
    M
    Oooh nasty So your app has not changed, now it comes down to your environment, you know all those lovely security and product updates courtesy of every vendor with software on your platform, one (or more) of them has probably changed something. I would think that rebuilding your install may make a difference. You may want to look at changing your references away from 'specific version' Never underestimate the power of human stupidity RAH
  • Query / Design Optimization help

    database help design algorithms performance
    2
    0 Votes
    2 Posts
    0 Views
    C
    Instead of a computed column, use a normal column and use an after update/insert trigger on the table that calls your function and sets the column value for the row in question. You then also have the advantage of adding an index on this column. :) Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]
  • SQL Server Exported Text File Differences

    database sql-server sysadmin help question
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • SSIS Connection Problem in C#

    database sql-server sysadmin help csharp
    3
    0 Votes
    3 Posts
    0 Views
    V
    1: The connection string is Correct it comes from my webconfig 2: Can you give me more info on this one. Thanks 3: what Configuration needs to be there ? i have SQl 2005 installed and 2008 installed they both use the same port 4: i saw that links and i have Googled Thanks Vuyiswa Maseko, Spoted in Daniweb-- Sorry to rant. I hate websites. They are just wierd. They don't behave like normal code. C#/VB.NET/ASP.NET/SQL7/2000/2005/2008 http://www.vuyiswamaseko.com vuyiswa@its.co.za http://www.itsabacus.co.za/itsabacus/
  • DateTime ; between query in SQL SERVER 2000

    database sql-server sysadmin help question
    10
    0 Votes
    10 Posts
    0 Views
    A
    Try this: select * from tablename where (datediff(day, startdate, '23-Feb-2010') = 0) Adam
  • Oracle Primary key

    question database oracle help
    4
    0 Votes
    4 Posts
    0 Views
    D
    Try this: http://www.techonthenet.com/oracle/questions/find_pkeys.php[^]
  • SQL Anywhere 10 Password Field

    database question
    3
    0 Votes
    3 Posts
    0 Views
    M
    Hi Mark, Thanks for your feedback, do you have an example of that? Is there not a constraint in sybase or something along those lines that I can apply to the column? Thanks again, Mel
  • Convert a String into datetime

    database help tutorial
    4
    0 Votes
    4 Posts
    0 Views
    K
    try the below SELECT CONVERT(VARCHAR(10), GETDATE(), 103) AS [DD/MM/YYYY]
  • Error.

    help tutorial
    4
    0 Votes
    4 Posts
    0 Views
    N
    Can you post how you resolved it? Naina
  • PIVOT

    help
    5
    0 Votes
    5 Posts
    0 Views
    N
    Can i know the reason why you want to use Pivot? Using For XML PATH('') also you can get the same result. select emp_name + ', ' from tabble where condition for xml path('') Regards Naina Naina
  • error : The instance name specified is invalid

    database sql-server sysadmin help
    4
    0 Votes
    4 Posts
    0 Views
    M
    mehrnoosh wrote: please explain more i am a beginner Then you need to do some research, there are plenty of resources on the web and you should have Books On Line (BOL) with your SQL Server. Use them, research instancename. I think you need to reinstall if you need to change the instance name but I'm not sure. Never underestimate the power of human stupidity RAH
  • a SQL Statement Error

    asp-net database help question
    11
    0 Votes
    11 Posts
    0 Views
    M
    Thank you Niladri it helped
  • Conditional Sum in SQL Query

    database sql-server sysadmin
    4
    0 Votes
    4 Posts
    0 Views
    N
    Even you can try this declare @t table(field int) insert into @t select -2 union all select 5 union all select 4 union all select -1 select top 1 PositiveSum = (select SUM(field) from @t where field >0) ,NegetiveSum =(select SUM(field) from @t where field <0) from @t Output: PositiveSum NegetiveSum 9 -3 :) Niladri Biswas
  • how to get the count under different values in the same feilld.

    sales tutorial
    2
    0 Votes
    2 Posts
    0 Views
    M
    Look into the group by clause. Select count(*), Customer, Status From Table Group By Customer, Status Never underestimate the power of human stupidity RAH
  • List products sold to buyers

    help
    5
    0 Votes
    5 Posts
    0 Views
    F
    Hi It's good point, I want to show data in Crystal Report. Do you know any tutorial ?
  • TSql , Update master / child records

    database sql-server sales announcement
    5
    0 Votes
    5 Posts
    0 Views
    M
    You should immediately remedy the primary key issue if you have control of the database. I would add an identity field UserNo to user table and the appropriate fields and keys to the FK table(s). As Bob said you have made a fundamental error in data design, fix it and you no longer have the update problem. Never underestimate the power of human stupidity RAH
  • 0 Votes
    1 Posts
    0 Views
    No one has replied
  • sql statement to find missing records

    database tutorial
    3
    0 Votes
    3 Posts
    0 Views
    J
    thank you