May 28, 2018 at 5:26 am
Hi Team,
I facing some problem at the time inserting the data,
for example:
I insert the one sp into one column of the table its through some exception. please help me
eg:
insert into tblSp(Script,Display,Remarks)
values('Create procedure [dbo].[Delete]
@Id int = null
as
begin
update master
set Status=0,
DeleteDate=getdate(),
Reason = 'Test '
end
','Delete','new')
--> it's through exception on 'Test '
please tell me how to insert the data
May 28, 2018 at 5:37 am
you need to escape the single quotes for that field - so 'test' becomes ''test''
May 28, 2018 at 7:01 am
rabbanishaik.net - Monday, May 28, 2018 5:26 AMHi Team,I facing some problem at the time inserting the data,
for example:
I insert the one sp into one column of the table its through some exception. please help me
eg:
insert into tblSp(Script,Display,Remarks)
values('Create procedure [dbo].[Delete]
@Id int = null
as
begin
update master
set Status=0,
DeleteDate=getdate(),
Reason = 'Test 'end
','Delete','new')--> it's through exception on 'Test '
please tell me how to insert the data
Out of interest, can you explain what this table will be used for? Also, what is the @Id variable for?
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy