Click here to Skip to main content
12,290,979 members (67,980 online)
   

Database

 
GeneralRe: SQL Select Where query Pin
Eddy Vluggen15-Oct-12 1:26
memberEddy Vluggen15-Oct-12 1:26 
AnswerRe: SQL Select Where query Pin
Aadhar Joshi16-Oct-12 20:47
memberAadhar Joshi16-Oct-12 20:47 
AnswerRe: SQL Select Where query Pin
HiteshDR23-Oct-12 1:06
memberHiteshDR23-Oct-12 1:06 
QuestionMS SQL didn't allow to store apostrophe( ' ) in name Pin
Azher.Cybertech15-Oct-12 0:04
memberAzher.Cybertech15-Oct-12 0:04 
AnswerRe: MS SQL didn't allow to store apostrophe( ' ) in name Pin
Eddy Vluggen15-Oct-12 0:55
memberEddy Vluggen15-Oct-12 0:55 
AnswerRe: MS SQL didn't allow to store apostrophe( ' ) in name Pin
HiteshDR23-Oct-12 1:08
memberHiteshDR23-Oct-12 1:08 
GeneralRe: MS SQL didn't allow to store apostrophe( ' ) in name Pin
Azher.Cybertech27-Oct-12 23:34
memberAzher.Cybertech27-Oct-12 23:34 
QuestionError Running SP [SOLVED] Pin
jojoba201113-Oct-12 21:53
memberjojoba201113-Oct-12 21:53 
Hi ,
When i run this Stored Procedure I get this error :
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near 'Pages'.


AND my SP is :

declare @ModuleSettings NVarChar(max) = N'<Article type=''Pages''><Ucl name=''~/UserControls/ModuleSettings/ArticleModuleSettings.ascx''></Ucl><Election>0</Election><IsPaging>False</IsPaging><PageSize>5</PageSize><PagingLocation>Top</PagingLocation><Title>توليد کنندگان مواد اوليه / Suppliers of raw materials</Title><ThumbNail location=''3''>True</ThumbNail><ContentTitle>True</ContentTitle><ContentAbbr>True</ContentAbbr><Icon address=''''>False</Icon><Category>429</Category><All><item align="right" visible="true" order="1" block="true" navigateUrl="~/Management/Modules/Details/">Title</item><item align="right" visible="true" order="2" block="true">Abbr</item><item align="left" visible="true" order="4" block="true">CreateDate</item><item align="right" visible="false" order="5" block="false">Content</item><item align="right" visible="false" order="6" block="false">Keyword</item><item align="right" visible="false" order="7" block="false">Category</item><item align="right" visible="false" order="8" block="false">File</item><item align="right" visible="false" order="9" block="false">Icon</item><item align="right" visible="false" order="10" block="false">writer</item><item align="right" visible="false" order="11" block="false">Source</item></All></Article>' 
 
declare @param nvarchar(max)= N'update [Management].[PageModules] set '
if 100 is not NULL
BEGIN
set @param = @param + '[AreaId]=''' + cast(100 as nvarchar(3)) + ''',' 
End
if @ModuleSettings is not NULL
BEGIN
set @param = @param + '[ModuleSettings]=''' + @ModuleSettings + ''',' 
END
if 0 is not NULL
BEGIN
set @param = @param + '[Election]=''' + cast(0 as nvarchar(3)) + ''',' 
End
if 'sdfg' is not NULL
BEGIN
set @param = @param + '[Title]=''' + 'sdfg' + ''',' 
End
if 418 is not NULL
BEGIN
set @param = @param + '[CategoryId]=''' + cast(418 as nvarchar(17)) + ''',' 
End
if NULL is not NULL
BEGIN
set @param = @param + '[DepartmentId]=''' + cast(NULL as nvarchar(9)) + ''',' 
End
if 38 is not NULL
BEGIN
set @param = @param + '[CultureId]=''' + cast(38 as nvarchar(5)) + ''',' 
End
if 15 is not NULL
BEGIN
set @param = @param + '[ModuleId]=''' + cast(15 as nvarchar(5)) + ''',' 
End
if 1 is not NULL
BEGIN
set @param = @param + '[PageId]=''' + cast(1 as nvarchar(9)) + ''',' 
End
set @param= substring(@param,0,len(@param))
set @param = @param + ' Where Id=''' + cast( 68 as nvarchar(17)) + ''' ' 
 
exec sp_executesql @param


modified 6-Nov-12 4:38am.

AnswerRe: Error Running SP Pin
Eddy Vluggen14-Oct-12 3:06
memberEddy Vluggen14-Oct-12 3:06 
AnswerRe: Error Running SP Pin
Richard Deeming15-Oct-12 3:38
memberRichard Deeming15-Oct-12 3:38 
QuestionRe: Error Running SP Pin
jojoba201115-Oct-12 4:52
memberjojoba201115-Oct-12 4:52 
NewsRe: Error Running SP [Solved] Pin
jojoba20115-Nov-12 22:37
memberjojoba20115-Nov-12 22:37 
QuestionBug in SQLBulkCopy? Truncates decimal digits after 26 records Pin
Allan Watkins12-Oct-12 14:25
memberAllan Watkins12-Oct-12 14:25 
AnswerRe: Bug in SQLBulkCopy? Truncates decimal digits after 26 records Pin
jschell13-Oct-12 11:05
memberjschell13-Oct-12 11:05 
GeneralRe: Bug in SQLBulkCopy? Truncates decimal digits after 26 records Pin
Allan Watkins13-Oct-12 13:02
memberAllan Watkins13-Oct-12 13:02 
GeneralRe: Bug in SQLBulkCopy? Truncates decimal digits after 26 records Pin
jschell14-Oct-12 6:51
memberjschell14-Oct-12 6:51 
GeneralRe: Bug in SQLBulkCopy? Truncates decimal digits after 26 records Pin
Mycroft Holmes14-Oct-12 15:06
memberMycroft Holmes14-Oct-12 15:06 
GeneralRe: Bug in SQLBulkCopy? Truncates decimal digits after 26 records Pin
Allan Watkins14-Oct-12 19:36
memberAllan Watkins14-Oct-12 19:36 
GeneralThe "bug" is actually in the Fill() method Pin
Allan Watkins16-Oct-12 16:09
memberAllan Watkins16-Oct-12 16:09 
AnswerRe: Bug in SQLBulkCopy? Truncates decimal digits after 26 records Pin
Aadhar Joshi17-Oct-12 1:31
memberAadhar Joshi17-Oct-12 1:31 
QuestionConfigure SQL Server 2005 Remote Access Pin
Kevin Marois11-Oct-12 11:35
memberKevin Marois11-Oct-12 11:35 
AnswerRe: Configure SQL Server 2005 Remote Access Pin
Marcus Kramer11-Oct-12 12:06
memberMarcus Kramer11-Oct-12 12:06 
AnswerRe: Configure SQL Server 2005 Remote Access Pin
Eddy Vluggen11-Oct-12 12:37
memberEddy Vluggen11-Oct-12 12:37 
AnswerRe: Configure SQL Server 2005 Remote Access Pin
Bernhard Hiller12-Oct-12 3:24
memberBernhard Hiller12-Oct-12 3:24 
QuestionGlobal Database Design for example to store Addresses Pin
LiQuick10-Oct-12 21:38
memberLiQuick10-Oct-12 21:38 

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.


Advertise | Privacy | Mobile
Web02 | 2.8.160518.1 | Last Updated 23 May 2016
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid