Click here to Skip to main content
15,891,375 members
Home / Discussions / Database
   

Database

 
GeneralRe: Help in Query - Oracle Pin
N a v a n e e t h14-Aug-09 17:45
N a v a n e e t h14-Aug-09 17:45 
GeneralRe: Help in Query - Oracle Pin
aaraaayen16-Aug-09 23:54
aaraaayen16-Aug-09 23:54 
GeneralRe: Help in Query - Oracle Pin
aaraaayen17-Aug-09 0:00
aaraaayen17-Aug-09 0:00 
AnswerRe: Help in Query - Oracle Pin
Johan Hakkesteegt17-Aug-09 2:23
Johan Hakkesteegt17-Aug-09 2:23 
QuestionSQLServerCE.dll Pin
sohaib_a13-Aug-09 4:46
sohaib_a13-Aug-09 4:46 
Questionconsidering all the columns in a field Pin
jishbalan13-Aug-09 0:36
jishbalan13-Aug-09 0:36 
AnswerRe: considering all the columns in a field Pin
Ashfield13-Aug-09 1:28
Ashfield13-Aug-09 1:28 
QuestionPROBLEM IN STORED PROCEDURE SUBSTRING :(( Pin
dotnetcsharpdev13-Aug-09 0:16
dotnetcsharpdev13-Aug-09 0:16 
i have a simple stored procedure   and i want to split postcode in it which could be of length either 7 or 6 and tha second part will always be of length 3. am pasting the sql here. and also the error message. Plz help me resolve this error

<code>


SELECT          CONVERT(varchar, DecryptByKey(Postcode)) as Postcode,
          CONVERT(varchar, DecryptByKey(Postcode)) as Postcode1,
          CONVERT(varchar, DecryptByKey(Postcode)) as Postcode2,              
                                    
                    if Postcode.length = 7
                         begin
                              set Postcode1= substring(Postcode,5,7)
                              set Postcode1= substring(Postcode,1,4)
                         end
                    else
                         begin
                              set Postcode1 = substring(Postcode,4,6)
                              set Postcode1 = substring(Postcode,1,3)     
                   
                         end    
                                  
     FROM            xyz
     WHERE (abc = @def)

     END

</code>


<ERROR>
error:
Msg 102, Level 15, State 1, Procedure XYZ,   LINE 7
Incorrect syntax near '='.
Msg 102, Level 15, State 1, Procedure XYZ, Line LINE 12)
Incorrect syntax near '='.
</ERROR>
AnswerRe: PROBLEM IN STORED PROCEDURE SUBSTRING :(( Pin
Ashfield13-Aug-09 1:25
Ashfield13-Aug-09 1:25 
GeneralRe: PROBLEM IN STORED PROCEDURE SUBSTRING :) Pin
dotnetcsharpdev13-Aug-09 1:55
dotnetcsharpdev13-Aug-09 1:55 
GeneralRe: PROBLEM IN STORED PROCEDURE SUBSTRING :) Pin
Ashfield13-Aug-09 4:29
Ashfield13-Aug-09 4:29 
QuestionTurnkey Websites And Php Scripts (3016) Pin
maliksp12-Aug-09 22:46
maliksp12-Aug-09 22:46 
RantRe: Turnkey Websites And Php Scripts (3016) Pin
Ashfield13-Aug-09 1:26
Ashfield13-Aug-09 1:26 
QuestionGet Time From the Datetime of SQL 2005? Pin
Pawan Kiran12-Aug-09 20:26
Pawan Kiran12-Aug-09 20:26 
AnswerRe: Get Time From the Datetime of SQL 2005? Pin
Ashfield12-Aug-09 21:05
Ashfield12-Aug-09 21:05 
NewsSQL Server 2008 R2 Community Preview Now Available To All Pin
brucedkyle12-Aug-09 9:07
brucedkyle12-Aug-09 9:07 
GeneralRe: SQL Server 2008 R2 Community Preview Now Available To All Pin
Mycroft Holmes12-Aug-09 16:55
professionalMycroft Holmes12-Aug-09 16:55 
GeneralRe: SQL Server 2008 R2 Community Preview Now Available To All Pin
Jerry Hammond12-Aug-09 19:14
Jerry Hammond12-Aug-09 19:14 
QuestionSQL 2005 Problem : Insert exec statement cannot be nested Pin
mihirhp12-Aug-09 0:49
mihirhp12-Aug-09 0:49 
AnswerRe: SQL 2005 Problem : Insert exec statement cannot be nested Pin
Jerry Hammond12-Aug-09 3:58
Jerry Hammond12-Aug-09 3:58 
GeneralRe: SQL 2005 Problem : Insert exec statement cannot be nested Pin
Mycroft Holmes12-Aug-09 16:58
professionalMycroft Holmes12-Aug-09 16:58 
GeneralRe: SQL 2005 Problem : Insert exec statement cannot be nested Pin
Luc Pattyn12-Aug-09 17:01
sitebuilderLuc Pattyn12-Aug-09 17:01 
GeneralRe: SQL 2005 Problem : Insert exec statement cannot be nested Pin
_Damian S_12-Aug-09 17:25
professional_Damian S_12-Aug-09 17:25 
JokeRe: SQL 2005 Problem : Insert exec statement cannot be nested Pin
dan!sh 12-Aug-09 18:46
professional dan!sh 12-Aug-09 18:46 
QuestionSQL 2000 Query Pin
CodingYoshi11-Aug-09 11:26
CodingYoshi11-Aug-09 11:26 

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.