Where should we put the cast in following situation

user3129097

where should we put cast in the following situation.

bridgid is bigint in the table.

CAST(ISNULL(br.bridgid, 0) as bigint)

or

ISNULL(br.bridgid, cast(0 as bigint))
cloudsafe
CAST(ISNULL(br.bridgid, 0) as bigint)

is correct because

ISNULL(br.bridgid, cast(0 as bigint))

will always return the datatype of br.brigid even if the second argument is a higher precedence. Thanks @AlexK

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Meteor: Where should we put common functions?

From Dev

Domain Driven Design - where should we put repositories?

From Dev

Should we cast JQuery parameter in functions?

From Dev

Where should i put the function?

From Dev

Where should the credentials for mysql be put?

From Dev

.tolowerCase() Where should I put it?

From Dev

Where should I put the codes?

From Dev

Should we put an S in the name of array of things?

From Dev

why should we put glGetError in a loop?

From Dev

Storyboard reference in Xcode, where should we use it?

From Dev

ExtJS 6 - Where should we write styles?

From Dev

why we should use a template wrapper in the following code?

From Dev

Where is or where should be the folder following the port number in a url?

From Dev

How should I refactor the following situation so that Rails autoloads my class

From Dev

Where should I put automapper code?

From Dev

Where should I put this code in Laravel?

From Dev

Where should I put removeObserver from NSNotification

From Dev

Composer: where should I put the "vendor" folder?

From Dev

Where should I put the "clear: both"?

From Dev

Where should I put navigation code?

From Dev

Where should I put unhandled exception handler?

From Dev

Where should I put interfaces and implementations

From Dev

Where should I put the images for the Java app?

From Dev

Where should I put my bash scripts

From Dev

Where should I put my defaults?

From Dev

Where should I put automapper code?

From Dev

Where should I put functions in Javascript code?

From Dev

Where should I put ownerless log file

From Dev

Where should users put custom vim functions?

Related Related

HotTag

Archive