Click here to Skip to main content
15,886,110 members
Home / Discussions / Database
   

Database

 
GeneralRe: Integration Services or C# code Pin
RichardInToronto7-Dec-11 15:35
RichardInToronto7-Dec-11 15:35 
AnswerRe: C# code Pin
David Mujica6-Dec-11 5:55
David Mujica6-Dec-11 5:55 
GeneralRe: C# code Pin
RichardInToronto7-Dec-11 4:09
RichardInToronto7-Dec-11 4:09 
GeneralRe: C# code Pin
David Mujica7-Dec-11 8:08
David Mujica7-Dec-11 8:08 
GeneralRe: C# code Pin
RichardInToronto7-Dec-11 15:31
RichardInToronto7-Dec-11 15:31 
GeneralRe: C# code Pin
Mycroft Holmes7-Dec-11 15:55
professionalMycroft Holmes7-Dec-11 15:55 
Questiondatabase role permissions Pin
Danzy835-Dec-11 3:53
Danzy835-Dec-11 3:53 
AnswerRe: database role permissions Pin
R. Giskard Reventlov5-Dec-11 4:11
R. Giskard Reventlov5-Dec-11 4:11 
QuestionHow to import data from excel to sql server 2005 Pin
rahul honey4-Dec-11 23:47
rahul honey4-Dec-11 23:47 
AnswerRe: How to import data from excel to sql server 2005 Pin
PIEBALDconsult5-Dec-11 1:57
mvePIEBALDconsult5-Dec-11 1:57 
Questionhow to start business intelligence in sql server 2008 Pin
developerit4-Dec-11 20:03
developerit4-Dec-11 20:03 
Question.sql file Pin
palakash2-Dec-11 21:04
palakash2-Dec-11 21:04 
AnswerRe: .sql file Pin
R. Giskard Reventlov3-Dec-11 2:57
R. Giskard Reventlov3-Dec-11 2:57 
QuestionSql Server 2008R2 Developers version Pin
SQL Ed2-Dec-11 8:40
SQL Ed2-Dec-11 8:40 
AnswerRe: Sql Server 2008R2 Developers version Pin
Mycroft Holmes2-Dec-11 12:19
professionalMycroft Holmes2-Dec-11 12:19 
AnswerRe: Sql Server 2008R2 Developers version Pin
Wonde Tadesse2-Dec-11 16:46
professionalWonde Tadesse2-Dec-11 16:46 
QuestionSolved:Update Multiple Rows of one table on the base of multiple rows in another table Pin
Rupesh Kumar Swami2-Dec-11 0:26
Rupesh Kumar Swami2-Dec-11 0:26 
AnswerRe: Update Multiple Rows of one table on the base of multiple rows in another table Pin
Varsha Ramnani2-Dec-11 0:44
professionalVarsha Ramnani2-Dec-11 0:44 
GeneralRe: Update Multiple Rows of one table on the base of multiple rows in another table Pin
Rupesh Kumar Swami2-Dec-11 2:51
Rupesh Kumar Swami2-Dec-11 2:51 
GeneralRe: Update Multiple Rows of one tableon the base of multiple rows in another table Pin
Varsha Ramnani2-Dec-11 4:20
professionalVarsha Ramnani2-Dec-11 4:20 
GeneralRe: Update Multiple Rows of one tableon the base of multiple rows in another table Pin
Rupesh Kumar Swami2-Dec-11 20:35
Rupesh Kumar Swami2-Dec-11 20:35 
Hi Varsha,
i update the query as you suggested. and following is the original query

UPDATE issdetails_new a,<br />
(<br />
SELECT secid, country, PriceDate,<br />
OPEN , High, Low, Close, Ask, midval, Last, Bid, BidSize, AskSize, TradedVolume, MktCloseDate, Volflag, TradedValue, TotalTrades,<br />
COMMENT , LocalCode<br />
FROM hist_prices<br />
WHERE MktCloseDate = (<br />
SELECT max( MktCloseDate )<br />
FROM hist_prices )<br />
) AS b<br />
SET a.PriceDate = b.PriceDate,<br />
a.Open = b.Open,<br />
a.High = b.High,<br />
a.Low = b.Low,<br />
a.Close = b.Close,<br />
a.Midval = b.Midval,<br />
a.Ask = b.Ask,<br />
a.Last = b.Last,<br />
a.Bid = b.Bid,<br />
a.BidSize = b.BidSize,<br />
a.AskSize = b.AskSize,<br />
a.TradedVolume = b.TradedVolume,<br />
a.MktCloseDate = b.MktCloseDate,<br />
a.Volflag = b.Volflag,<br />
a.TradedValue = b.TradedValue,<br />
a.TotalTrades = b.TotalTrades,<br />
a.Comment = b.Comment,<br />
a.LocalCode = b.LocalCode WHERE a.SecId = b.SecId AND a.Country = b.Country


Its works well. Thanks a lot

but there are one more problem

in table issdetails, there are 9500 records and in table hist_prices there are 41,50,000 records so it takes 11 -13 minute for update the table issdetails. Any option to reduce the execution time ? Please suggest
rup28aug@yahoo.co.in
Rupesh Kumar Swami
Software Developer,
Integrated Solution,
Bikaner (India)

Company - ISOL, India


Award: Best VB.NET article of June 2008: Create Column Charts Using OWC11

GeneralRe: Update Multiple Rows of one tableon the base of multiple rows in another table Pin
Varsha Ramnani2-Dec-11 23:34
professionalVarsha Ramnani2-Dec-11 23:34 
GeneralRe: Update Multiple Rows of one tableon the base of multiple rows in another table Pin
Rupesh Kumar Swami3-Dec-11 0:52
Rupesh Kumar Swami3-Dec-11 0:52 
GeneralRe: Update Multiple Rows of one table on the base of multiple rows in another table Pin
Eddy Vluggen3-Dec-11 4:26
professionalEddy Vluggen3-Dec-11 4:26 
GeneralRe: Update Multiple Rows of one table on the base of multiple rows in another table Pin
Varsha Ramnani4-Dec-11 17:15
professionalVarsha Ramnani4-Dec-11 17:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.