MySQL Forums :: Stored Procedures :: ISNULL function

Advanced Search

ISNULL function
Posted by: ram krishna ()
Date: February 28, 2008 10:38PM

In a program, I work with SQLServer and MySql. In a particular select,
for SQLServer, I have something like this:


If the field is not null, returns its value; otherwise, 0.

I have found isnull for MySQL, but it does not work exactly the same

Any idea to convert that isnull from SQLServer to MySQL?

This is how i use in MSSql:-

fieldname = "ISNULL(Max(iClientID),0)+1"
ClientID = Convert.ToInt32(obj.ReturnSingleValue("UserClient", fieldname))

So in mysql ,what is its equivalent?

Edited 2 time(s). Last edit at 02/29/2008 01:01AM by ram krishna.

Options: ReplyQuote

Subject Views Written By Posted
ISNULL function 303405 ram krishna 02/28/2008 10:38PM
Re: ISNULL function 85023 William Chiquito 02/29/2008 10:15AM
Re: ISNULL function 31240 Joe Aponte 03/23/2008 12:22PM
Re: ISNULL function 17230 William Chiquito 03/23/2008 01:02PM
Re: ISNULL function 12014 Joe Aponte 03/24/2008 08:10AM
Re: ISNULL function 16553 William Chiquito 03/24/2008 06:05PM
Re: ISNULL function 12773 Joe Aponte 03/25/2008 12:29PM
Re: ISNULL function 15740 Steve Brinton 03/30/2009 06:05AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.