Hi all,
Can any one help me with a command by which I can change the system date thru Oracle
Regards
Reshmi
10 36793
Oracle takes System date from the OS. Shut down Oracle, Change the OS date and restart Oracle. That will give you New Systemdate.
If you do not Shut down/ Restart Oracle, it some time creates problems.
Hope this helps.
Hi
Thanks for ur time.
But its not the thing I want. The exact problem is when I make changes in a table, and if some condition satisfies, I will execute a trigger in which I will change the system date itself. (ie; UPDATE.... SYSDATE = '27-Nov-2006') This will create an error , then how can I change the SYSDATE ???
Regards
Reshmi
Use 1)nls_format_da te
To Change Date Format Or Use
2)to_char, 3)or To_date
Use 1)nls_format_da te
To Change Date Format Or Use
2)to_char, 3)or To_date
Hey,
Reshmi is trying to change the SystemDate, not the date format.
It can be done, using a batchfile/shell script, if you want it to be automatic.
Hey,
Reshmi is trying to change the SystemDate, not the date format.
It can be done, using a batchfile/shell script, if you want it to be automatic.
Hi
Can u help me in how to execute a batch file from Oracle?
Reshmi
Hi
Can u help me in how to execute a batch file from Oracle?
Reshmi
sqlplus "/as sysdba"; SQL> shutdown immediate
Stop listener as - lsnrctl stop[listener_name]
date [New Date]
Start listener as - lsnrctl start[listener_name]
Start Database as - sqlplus "/as sysdba"; SQL> startup
hope this helps.
By the way, the above script is for Windows. what are you trying to do?
If you ask your Oracle Admin. they will do it for you.
OK , you may proceed as Pragati has told u .
But through a DML statement like UPDATE it is not possible as SYSDATE works like a function and it can't be used in the left hand side of a = operator .
Hi
Can u help me in how to execute a batch file from Oracle?
Reshmi
u can execute batch file with
@path/filename from sql prompt
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: gimme_this_gimme_that |
last post by:
Might some kind soul take on this Oracle statement and
translate it into DB2? Yes ... I know the equivalent of SYSDATE
is CURRENT TIMESTAMP, and that DUAL is SYSIBM.SYSDUMMY1.
But I'm puzzled by the 'Q' (Quarter), and NEXT_DAY
translations. Thanks.
SELECT
TO_CHAR(SYSDATE, 'Q') Q,
TO_CHAR(SYSDATE, 'MM') MON,
TO_CHAR(NEXT_DAY(SYSDATE,'SUNDAY' ),'MM/DD/YYYY') WEEKEND,
|
by: Alexey Golikov |
last post by:
Hi, all!
How can i change System Date?
|
by: Richard |
last post by:
How can we change/reset the system date.
Thanks in advance.
RC
|
by: Mike9900 |
last post by:
How can I get the real system date/time if the user fakes the date, for
example by setting the system date back.
--
Mike
|
by: shyam vashista |
last post by:
i have problem in validation check for system date with server date
problem:::
If i change my system date as september 30, 2006
and use validation for filling form as current date as oct30, 2006 than it will ask me for check ur entry date but wen i fill form that time date is oct 30, 2006
so how to solve this problem ? how to check date with server date?
it is not compulsary that system date by which i am filling form date is same...
| |
by: tenshi |
last post by:
Hi!
We are currently supporting an old application using Win NT 4.0, Oracle 8i, MTS/IIS, and ASP.
This is the scenario:
During run-time, most of our pages has a textbox where it displays the current system date (default format is mm/dd/yyyy) on form load. Lately, there are times when it displays an invalid date format such as 04/11/197 or 04/11/07. As an immediate solution, we just restart the production server.
Do you have any idea...
|
by: ksrashmi |
last post by:
Hi ,
I want to change the system date using java/jsp . i am using linux system .
public class LinuxJava {
public static void main(String args) {
try {
String command = "date 07212008";
final Process process = Runtime.getRuntime().exec(command);
|
by: samvb |
last post by:
Hi,
I have just finished a program that uses ms access and depends on system date to do certain things. just when i was testing it, a friend suggested that i change system date to see how it reacts. And it totally failed if the system date changes. I have written a small module that can save me from this errors upon the user's request i.e. the user clicks a button to reset the date using my program. during the reseting process, i fix any date...
|
by: Moorad |
last post by:
how to assign the system date for windows and linux?
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |