# New to QlikView

Discussion board where members can get started with QlikView.

New Contributor III

## Floor Function

How do I use floor function for date?

Thanks

11 Replies
MVP

## Re: Floor Function

You can use to get just the date (excluding the time). For example try this:

Date(Floor(Now())) -> will give you just the date

Time(Frac(Now())) -> will give you just the time

Highlighted
Valued Contributor

## Re: Floor Function

Clearly it removes time part from the date

first try this in text object

=Now()

then try this

=Date(Floor(now()))

you will find the difference

MVP

## Re: Floor Function

See if the attached helps:

Contributor III

## Re: Floor Function

What is the diff btw =Date(Floor(now())) & =Date(now())... I see both returning same value

## Re: Floor Function

This is old thread, Some how look Floor() in help - Floor ‒ QlikView

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Contributor III

## Re: Floor Function

Saw that.. But not able to understand clearly.. On what circumstances floor func will be useful in Biz cases? any simple example / illustration ?

## Re: Floor Function

Example is there where we use floor() and ceil() in qlikview?

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Contributor III

## Re: Floor Function

TY!

Honored Contributor

## Re: Floor Function

Ceil function will round up a number. Ex: ceil(3.4) will return 4.

Floor will round down a number. Ex: floor(3.4) will return 3.

I use this when working with timestamps with hour and minutes values. Behind each date there's a number associated. Those dates with time, will have a decimal value (56321,23) where 23 represents the time and minutes (this is a random example!).

When in your model you don't need to use the hour, you can use ceil(Date) so your dates will always be DD/MM/YYYY 00:00:00 instead of DD/MM/YYYY 10:36:00.

This can also be used to format values. If you are working with big amounts, it might not tell you much to show the decimal. Instead of showing \$26.354.201,31, you can use the ceil or floor function and round up/down the number, or using the format in the Number tab for the charts.

Advantage: It will helps to save lot of memory since it trims of timestamp.

For More: Get the Dates Right

-Siva