C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |



My Profile

Gifts

Active Members
TodayLast 7 Days more...







Dynamic creation of queries


Posted Date: 25 Sep 2007      Total Responses: 2

Posted By: victoria       Member Level: Gold     Points: 2


Hello All can anyone suggest me the link or material or anything whic help me to study on creating queries dynamically???


please i really need it,or just tell me how an i go about this.



Thankyou




Responses

Author: sathiyasivam    25 Sep 2007Member Level: DiamondRating:     Points: 2
Hi victoria,

Dynamic SQL means the values are assign to it at run time.


SET @SQL= 'SELECT * INTO ' + @VAR + ' FROM server1.dbname.DBO.' + @VAR + ' WHERE Dim_ID IN (SELECT Dim_ID FROM dbo.table2)'
PRINT @SQL
EXECUTE SP_EXECUTESQL @SQL


In the above @var is dynamic value ,here im creating the sql at runtime and it is dynamic.Any more mail me

Regards
Sathiya


Author: http://venkattechnicalblog.blogspot.com/    25 Sep 2007Member Level: DiamondRating:     Points: 2

Please check this link for dynamic query, I think you have asked only for link, if you need more about dynamic sql just send me a message regarding this,

http://www.sqlteam.com/article/introduction-to-dynamic-sql-part-1


Regards,
Venkatesan Prabu. J


Post Reply
You must Sign In to post a response.
Next : how can we do login authentication?
Previous : generating reports in excel from vb.net application
Return to Discussion Forum
Post New Message
Category: .NET

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

doors in nj

Contact Us    Privacy Policy    Terms Of Use