
Search In
If you want to extract only the date, we can use the strftime method of Time/Date class, as
2.1.5 :055 > DateTime.now.strftime('%d/%m/%Y')
=> "12/30/2015"
(Here d is used to display date, m displays month and Y display the year in 4-dig
If you want to create handler , here is the code snippet that can help you out.
Step :-1 Create the object for Handler.
private Handler myHandler = new Handler();
Step :-2 Create the Runnable Thread.
private Runnable myRunnableThread = new Run
LPAD(str,len,padstr)
LPAD mysql funtion returns the string str, left-padded with the string padstr to a length of len characters means if you want to extend a string to a certain length and insert some character in left side of string at the place o
LENGTH(str)
LENGTH(str) mysql function returns the length of the string str, measured in bytes. This function counts a multibyte character as multiple bytes. hence it means for a string containing 4(four) 2-byte characters then LENGTH() returns 8, w
If you want to getting calendar for a month then we can set calendar module as it gives a wide range of methods to play with yearly and monthly calendars. Here, we print a calendar for a given month ( Jan 2008 ) − and for example you can see below co
Sometimes we need to find the last inserted record into table. We can do this by using ORDER by and LIMIT.
Syntax:
SELECT *
FROM table_name
ORDER by id DESC
LIMIT 1;
Example: Suppose we have a table named "tickit" and we want to find the last in
Environment swapping is most important for odoo module and with_context([context][, **overrides]) → records[source]
It Returns a new version of this recordset attached to an extended context.
The extended context is either the provided context&n
Hi Reader's,
Welcome to FindNerd, today we are going to discuss how to use glob() function in php ?
Basically the glob() function is used for returning an array of filenames or directories matching a specified pattern.
The glob() function retur
Enumeration is a named value which is used to allocate various constant values to a single variable. This makes the program more easier to understand and maintain. Enumeration is also having better error checking techniques which additional security.
Difference between datatype char(n),varchar(n),nchar(n),nvarchar(n) in sql server?
char(n)
A char datatype takes 1 byte per character. It is a fixed length character datatype i.e even though character entered are less than n,fixed memory size i.e n
