2,736 Topics
| |
hi I am new in SQL Scritpting and my question might sound stupid, but please help me out to understand. Can one explain the difference between the two and similarity? The need and and use of the two? As for Temporary table does one create them or it comes with … | |
Hi Guys, I have some confusing part in the sql command the question is i have 2 different query : a)[code=sql] Select SUM(T1.Amount+T2.Amount) as Total From TABLE1 T1 INNER TABLE2 T2 ON T1.ID = T2.ID[/code] b) [code=sql]Select Sum(Amount) as Total FROM TABLE3 [/code] the result if a) query is 100 … | |
I have questionnaire that has two radio buttons(one is "Register" and the another one is "Drop") in it and all answers are saved in an SQL database. For Example ,when the user checked "Register" and then by clicking "Sumbit Page" the values stored in the sql database.When the user returns … | |
I have two tables as below table 1 ProductID---Int Descritption---Text table 2 Id FK_ProductID--Int Category but on the FK_ProductID I dont want my table not to display a number but the description from TBLA. | |
HI! I've got a problem... Given the schema below I need to create an SQL query, but for some reason I think there is something wrong with it.... BRANCH(BRANCH-NAME, BRANCH-CITY, ASSETS) Query: in what cities are the branches where the maximal bank assets are less than £200,000? So I've come … | |
I have a problem in my SQL 2005 Data Warehouse. I'm using a slowly changing dimension data flow transformation in SSIS which will not delete any records from my DB when they are deleted from the source data. I need to keep the dimension keys, but in this one case/one … | |
Hi All, I have to do a rather simple query, but a previous design error that did not make one of the fields required (it allows nulls when it shouldn't have) makes it a bit harder. I have a table projects and a table clients [B]Projects_Tbl[/B] ProjId ProjName ClientId [B]Clients_Tbl[/B] … | |
i am working in sql 2005, i have problem in Sql collations. our database modified in different people, some time we get collations error. how to solve this error? and how to avoid this problem in my future? | |
I have to tables as parent & child tables as below Table 1 TID1 Name 1 Test1 2 Test2 3 Test3 Table2 [U]TID2 || TID1 || ID1 || ID2 || ID3 || Name[/U] 1 1 1 2 3 All 2 2 2 2 2 All2 3 1 1 1 12 … | |
I have several questions: Here is the context: The ASP.NET application I'm building - a web service in essence - will be connecting to MSSQL to log requests to a table. These are basic INSERT commands. During high-volume hours, do I risk race conditions? How does MSSQL handle sequential INSERT … | |
can't solve a homework problem for computer class. Any clues?: Given two tables, USERS and LOG, where USERID is a primary key in USERS and a foreign key in LOG, write a SQL statement that will return LOG records (all fields) with corresponding USERIDs in USERS. The report should include … | |
Hello Guys, I was dumped in the middle of a project with not a lot of experience in MS SQL server. I have 3 little questions 1) If i receive a bak file(restore file) from another server, is it normal that if i restore the file i will no see … | |
Hi, In my Insert SP, I have 5 local variables: @MemberID int, @VideoID int, @Total money, @DateRented datetime, @DateDue datetime insert into RentalRecord values (@MemberID,@VideoID,@Total,GETDATE(), DATEADD(dd,5,GETDATE())) When I try to execute the SP, I get this error: Procedure or function 'sp_AddRentalRecord' expects parameter '@DateRented', which was not supplied. Please advise. … | |
is it possible to convert system made from php with a database of mysql to ms sql database..? how? thaks | |
Hi Everyone! I have to make a forum with MS SQL, and, as I'm Hungarian, we use characters, like áéíőúű, etc. Now, if I insert a text with the letter ő or ű, I get back o and u. How can I solve this problem? The users write posts in … | |
Hi All I am writting an stored procedure to get the recently inserted records primary key as follows: [CODE]ALTER PROCEDURE [DBO].[AddEditUserMsgDetails] ( @iJobID [INT]=NULL, @iUserID [INT]=NULL, @vFromName [VARCHAR](50)=NULL, @vFromAddress [VARCHAR](50)=NULL, @vSubject [VARCHAR](50)=NULL, @iListID [INT]=NULL, @vActualText [VARCHAR](100)=NULL ) AS BEGIN /* Logic Comments: INSERTING OR UPDATING INTO THE TABLE ezlMailJobs EXEC … | |
When some datas are inserted in to a DB table from a jsp page, how do i get the primary key in my table autogenerated?? finiding out the highest value for the primary key in the table? Pls help me wid the coding in JAVA or HTML.. I use SQL*PLus. | |
I have an awkward problem. I'm debugging what I believe is a race condition in a legacy codebase. The issue involves a userID column being set to the wrong value. Essentially, one user's record will be non-deterministically reassigned to another user. The real problem is that this column is set … | |
hi. i would like to work on my computer without connecting to server. i installed the ms sql management studio 2005 express. how can i create a local host server to work on ? | |
Hi everyone. I'm printing a list of articles from my database. Some articles are set as 'sponsored', meaning they appear at the top of the list. Articles also have a 'type' field - if it's set to 0 then there is no specific type, otherwise the value corresponds to a … | |
Hi I wrote simple query like [code=sql]select Code,CashDeposited,Date from dbo.RDBankingDetails where Code='SE0001' group by Date,Code,CashDeposited[/code] It generate report like below TE0001 12000 2005:03:26 TE0001 49150 2005:03.26 TE0001 209000 2005:03.26 I want to generate the report like below Code Date CashDeposisted1 CashDepostis2 CashDeposists3 TE0001 2005:03:26 120000 49150 209000 In above CashDeoposisted … | |
Hi Everyone, I would need your help. I have a project that I need to insert multiple records into my table. Here is more detail. I design a purchase order table with 3 columns (a, b, c): a: is primary key with identity (1,1) primary key b: is defined integer … | |
Hello Everyone! I'm new to MS SQL, so this may be a dumb error, but anyway, I can't figure it out. I'd like to connect to an SQL server on the internet, I've a valid username and password, but it can't find the server. So, I've tried the following connectionstring: … | |
Hi, [code=sql] SELECT DISTINCT dbo.RoomRates.RoomID, CASE WHEN (dbo.RoomRates.Overflow = 1 AND MIN(dbo.RoomRates.Availability) <= 5) THEN 5 ELSE MIN(dbo.RoomRates.Availability) END AS Availability, SUM( dbo.RoomRates.Price ) AS RoomTotalPrice FROM dbo.RoomRates WHERE dbo.RoomRates.[Date] BETWEEN @FromDate AND @ToDate GROUP BY dbo.RoomRates.RoomID , dbo.RoomRates.Overflow[/code] Input [code] roomid Date AvailableRooms RoomPrice FreeSale 100 01/12/08 FA 0 … | |
Hi I hope I have the right forum for this. This is a tricky one....I think! I have a reporting services report that runs off a csv file using integration services 2005. The report is based on a link between two tables linked by cc. The cc field links to … | |
hi, i m fetching the record from the given xml but not success full please help [code]DECLARE @XMLString xml set @XMLString ='<timetable> <day1 id="DY101"> <lecture1 id="LECT101"> <subject>SUB101</subject> <faculty>FAC101</faculty> <room>ROOM101</room> </lecture1> <lecture2 id="LECT102"> <subject>SUB102</subject> <faculty>FAC102</faculty> <room>ROOM102</room> </lecture2> <lecture3 id="LECT103"> <subject>SUB103</subject> <faculty>FAC103</faculty> <room>ROOM103</room> </lecture3> <lecture4 id="LECT104"> <subject>SUB104</subject> <faculty>FAC104</faculty> <room>ROOM104</room> </lecture4> <lecture5 id="LECT105"> … | |
I've got a multi union sql statement however union distinct doesn't work the way I want it to because I just use distinct on 1 column only (link_id). I've several ideas from the internet but I just can't get it to work. Below is the statement. [code] SELECT TOP (500) … | |
I'm not sure I did this right. It's for an assignment for school where i'm supposed to return the author last name and the balance (described below) relating to each author. It's from the pubs database (I'm thinking that most people have used it for testing/learning before?) I'm an SQL … | |
New to triggers and SQL programming but I'm trying to figure it out by looking at code examples. I have a table, called child. My program inserts a new child into the child table and stores the parentid as a FK. What I need to do is when a new … | |
How do I get [B]ONLY[/B] data type and name of all the columns available in given table_name |
The End.