Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB SQL » View Thread |
Messages 11 to 20 of 20 total |
Basic "parameters in SP" question |
Tue, Apr 1 2008 6:11 PM | Permanent Link |
Uli Becker | Tim,
<< It depends upon the needs of the application. Right now it simply uses a NULL value instead, so it gives you the option of having "optional" parameters, so to speak. >> OK, I see. So the opposite should be possible as well: if condition1 then Select * from TABLE; else Select * from TABLE where TableID = ?; end if; Execute Statement using ID; Is that true? In case of condition1 = true, the parameter is ignored? Or have I to use: if condition1 then Select * from TABLE; Execute Statement; else Select * from TABLE where TableID = ?; Execute Statement using ID; end if; Regards Uli |
Wed, Apr 2 2008 1:16 AM | Permanent Link |
Roy Lambert NLH Associates Team Elevate | Fernando
>I was talking about nulls, not the error message I know <vbg> Roy Lambert |
Wed, Apr 2 2008 2:21 AM | Permanent Link |
Roy Lambert NLH Associates Team Elevate | Uli
>I know that named parameters are not allowed in sp's. (A man from [Team-Elevate] should >know it as well, Roy. I thought that was the case but I have this memory (obviously wrong) of using them in a procedure at some point. Anyway if you note I didn't have the [Team Elevate] tag after my name there thus indicating I wasn't speaking infallibly Roy Lambert |
Wed, Apr 2 2008 5:43 AM | Permanent Link |
Fernando Dias Team Elevate | Roy
Looking at your "<vbg>" ... Should I run ? Am I speeking to Dr Jekyll or Mr Hyde when you don't use the tag ? -- Fernando Dias [Team Elevate] |
Wed, Apr 2 2008 6:16 AM | Permanent Link |
Roy Lambert NLH Associates Team Elevate | Fernando
>Looking at your "<vbg>" ... Should I run ? >Am I speeking to Dr Jekyll or Mr Hyde when you don't use the tag ? Just hide Roy Lambert |
Wed, Apr 2 2008 2:21 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Fernando,
<< What happens to the expressions containing the missing argument? >> They are evaluated using NULL as the parameter value. << Are they evaluated taking NULL as the actual value for the parameter and in that case, how does EDB deal with expressions like <ColName> = NULL ? >> It evaluates the expression according to the rules for NULL handling: http://www.elevatesoft.com/manual?action=mantopic&id=edb1sql&category=0&topic=7 -- Tim Young Elevate Software www.elevatesoft.com |
Wed, Apr 2 2008 2:24 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Uli,
<< Is that true? In case of condition1 = true, the parameter is ignored? >> Yes. -- Tim Young Elevate Software www.elevatesoft.com |
Wed, Apr 2 2008 4:20 PM | Permanent Link |
Fernando Dias Team Elevate | Tim,
> They are evaluated using NULL as the parameter value. So, for example, the expression "Column = ?" evaluates to NULL for any value of "Column" ? Even when "Column" is NULL? -- Fernando Dias [Team Elevate] |
Thu, Apr 3 2008 3:07 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Fernando,
<< So, for example, the expression "Column = ?" evaluates to NULL for any value of "Column" ? Even when "Column" is NULL? >> Yes. ElevateDB uses standard SQL NULL handling rules, and does not permit anything to equal NULL since NULL represents an unknown value. Only IS NULL or IS NOT NULL can be used to test for NULLs. DBISAM allowed the use of =, <>, etc. with NULL, but ElevateDB does not. http://www.elevatesoft.com/manual?action=mantopic&id=edb1sql&category=0&topic=7 -- Tim Young Elevate Software www.elevatesoft.com |
Thu, Apr 3 2008 3:35 PM | Permanent Link |
Fernando Dias Team Elevate | Tim,
Perfect. Thank you for the clarification. -- Fernando Dias [Team Elevate] |
« Previous Page | Page 2 of 2 | |
Jump to Page: 1 2 |
This web page was last updated on Tuesday, April 30, 2024 at 03:55 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |