Create Log for PL/SQL
Hi all,
Is it store precedure create any log file when I do insert or delete in my procedure?
Thank in advanc.
eg.
create my procedure
begin
insert into mytable()select * from employee;
delete from mytable where id < 100;
end
You always have redo data generated for the redo logs that you could investigate with LogMiner tool.
If you active auditing, you can have SQL statements in Oracle audit trail.
Otherwise you have to code your own logging system: you can use UTL_FILE package to write log files, for example or code auntonomous transaction to store your logs in database tables.
Similar Messages
-
Cannot create datasource for MS SQL Server
Hi,
I'm trying to create a datasource for MS SQL server and I get this error
Connection test failed.
Login failed for user 'gdahan'. The user is not associated with a trusted SQL Server connection.
com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Lcom.microsoft.sqlserver.jdbc.SQLServerConnection;Ljava.lang.Object;Ljava.lang.String;Lcom.microsoft.sqlserver.jdbc.StreamError;Z)V(Unknown Source)
com.microsoft.sqlserver.jdbc.TDSTokenHandler.onEOF(Lcom.microsoft.sqlserver.jdbc.TDSReader;)V(Unknown Source)
com.microsoft.sqlserver.jdbc.TDSParser.parse(Lcom.microsoft.sqlserver.jdbc.TDSReader;Lcom.microsoft.sqlserver.jdbc.TDSTokenHandler;)V(Unknown Source)
com.microsoft.sqlserver.jdbc.SQLServerConnection.sendLogon
The database is in "Windows authentication" mode (not "SQL authentication") and I can connect to it through "Toad for MS SQL Server". In this case I don't need to specify any username or password because I'm already logged in as gdahan on my computer. But when I try to create the datasource I need a username and password. Is there any way to specify to the datasource that I want to connect via Authentication windows ?
I tried with BEA MS SQL server driver and Microsoft SQL Server 2005 JDBC Driver 1.2[Guillaume Dahan wrote:
Hi,
I'm trying to create a datasource for MS SQL server and I get this error
Connection test failed.
Login failed for user 'gdahan'. The user is not associated with a trusted SQL Server connection.
com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Lcom.microsoft.sqlserver.jdbc.SQLServerConnection;Ljava.lang.Object;Ljava.lang.String;Lcom.microsoft.sqlserver.jdbc.StreamError;Z)V(Unknown Source)
com.microsoft.sqlserver.jdbc.TDSTokenHandler.onEOF(Lcom.microsoft.sqlserver.jdbc.TDSReader;)V(Unknown Source)
com.microsoft.sqlserver.jdbc.TDSParser.parse(Lcom.microsoft.sqlserver.jdbc.TDSReader;Lcom.microsoft.sqlserver.jdbc.TDSTokenHandler;)V(Unknown Source)
com.microsoft.sqlserver.jdbc.SQLServerConnection.sendLogon
The database is in "Windows authentication" mode (not "SQL authentication") and I can connect to it through "Toad for MS SQL Server". In this case I don't need to specify any username or password because I'm already logged in as gdahan on my computer. But when I try to create the datasource I need a username and password. Is there any way to specify to the datasource that I want to connect via Authentication windows ?
I tried with BEA MS SQL server driver and Microsoft SQL Server 2005 JDBC Driver 1.2[See the complete documentation for MS's JDBC driver
for how/whether it can do Windows Authentication.
This is completely at the driver level, not WebLogic,
except that (of course) WebLogic would have to be
running on Windows.
Joe -
Creating webservice for pl/sql API without using BPEL
Hi All,
Using BPEL, We have created partner links using DB Adapter for accessing our pl/sql API's.
Is there any way to create a web service for a pl/sql API having complex datatype parameters like (Record, table of records etc) using DB Adapter or any other tool without using BPEL?
Thanks,
Uma.We introduced the use of JPublisher to automate the generation of wrappers for PL/SQL procedures that use types such as boolean, record and table. The wizard will invoke JPub and generate artifacts that the partnerlink will use to invoke the wrapper instead of the original API. Boolean is replaced by INT, record is replaced by an object type and table is replaced by a nested table. The wrapper will invoke the original API. JPub also takes care of converting between the different types (i.e. record <-> object).
-
How to create .log for sqlplus script
Hi All,
I created a sqlplus script and run it through a window form. My user want to me create a .log file for this script so they can know the job is completed or not. Does any one know how to do it?
Thanks
OFI created a "Login.sql" script that I use for all my sql*plus sessions.
It creates a spool file in my common directory and everything i do is logged unless i set spool off.
Take a look and it gives you an example of using spool files and how to set a directory and unique filename for each spoolfile.
The contents of this file:
-- any uppercase commands are my specific changes.
-- this file must go in the oracle bin path or where sqlplus exe is located
SET HEADING OFF
PROMPT Who What Why Where When, This is SQL*Plus!
Select 'You are connected to ' || GLOBAL_NAME || ' as ' || USER FROM GLOBAL_NAME;
set appinfo ON
set appinfo "SQL*Plus"
set arraysize 15
set autocommit OFF
set autoprint OFF
set autorecovery OFF
set autotrace off
set blockterminator "."
set cmdsep OFF
set colsep " "
set compatibility NATIVE
set concat "."
set copycommit 0
set copytypecheck ON
set define "&"
set describe DEPTH 1 LINENUM OFF INDENT ON
set markup HTML OFF SPOOL OFF ENTMAP ON PRE OFF
set echo OFF
set editfile "afiedt.buf"
set embedded OFF
set endbuftoken ""
set escape OFF
set feedback 6
set flagger OFF
set flush ON
SET HEADING ON
set headsep "|"
SET LINESIZE 250
set logsource ""
set long 80
set longchunksize 80
set newpage 1
set null ""
set numformat ""
set numwidth 10
SET PAGESIZE 24
set pause OFF
set recsep WRAP
set recsepchar " "
SET SERVEROUTPUT ON size 1000000 format WORD_WRAPPED
set shiftinout invisible
set showmode OFF
set sqlblanklines OFF
set sqlcase MIXED
set sqlcontinue "> "
set sqlnumber ON
set sqlprefix "#"
set sqlprompt "SQL> "
set sqlterminator ";"
set suffix "sql"
set tab ON
set termout ON
SET TIME ON
SET TIMING ON
SET TRIMOUT ON
set trimspool OFF
set underline "-"
set verify ON
set wrap ON
COL SPOOLFILE NEW_VALUE SPOOL;
COL SYSTIMESTAMP FORMAT a38
SELECT 'C:\oracle\spoolfiles\'||NAME||'_'||TO_CHAR(SYSDATE,'DD_MON_YYYY_HH24MISS')||'.lst' spoolfile FROM V$DATABASE;
spool &spool
PROMPT -----------------------------------------------
SELECT SYSTIMESTAMP FROM DUAL;
PROMPT ----------------------------------------------- -
Error using WebServicesAssembler to create webservice for PL/SQL-Example
Hello all,
I tried to create a webservice based upon the pl/sql package emptax (Oracle Example: Boolean). The package just contains:
PACKAGE EMPTAX as
FUNCTION getTax(employeeid number, ismarried boolean) RETURN number ;
END Emptax;
JAVA_HOME, ORACLE_HOME and CLASSPATH are all set according to the manual. Now I start the WebServiceAssembler.jar with:
java -jar C:\oracle11\product\11.1.0\db_1\oc4j\webservices\lib\WebServicesAssembler.jar
-config C:\Daten\tmp\webservice_boolean\Boolean\config\config.xml
The config.xml looks like this:
<web-service>
<destination-path>./EmpTax.ear</destination-path>
<temporary-directory>./tmp</temporary-directory>
<context>/webservices</context>
<stateless-stored-procedure-java-service>
<uri>/EmpTax</uri>
<jar-generation>
<schema>scott/tiger</schema>
<db-url>jdbc:oracle:thin:@10.10.10.10:1521:prod11</db-url>
<db-pkg-name>EmpTax</db-pkg-name>
<prefix>EmpTax</prefix>
</jar-generation>
<database-JNDI-name>jdbc/prod11</database-JNDI-name>
</stateless-stored-procedure-java-service>
</web-service>
The EmpTax.jar is created, containing:
- EmpTax.java
- EmpTaxBase.java
- EmpTaxBase.sqlj
- EmpTaxUser.java
- EmpTaxUser.sqlj
At the end, there appears the error:
java.lang.Win32Process.create
java.lang.Runtime.execInternal
java.lang.Runtime.exec
oracle.j2ee.ws.tools.WsAssemblerConfig
=> NullPointerException: class EmpTax.EmpTaxUser not found
The EmpTax.ear-File is not generated. I'm really stuck now. Does anybody has a hint?
Thanks in advance
ChristophIgnore the last one. I did the example here over lunch and it works fine.
http://www.oracle.com/technology/sample_code/tech/java/jsp/samples/boolean/boolean.html
Try the -debug and see what happens.
When I run these tests, I always make sure that my PATH, and CLASSPATH are the absolute minimum. That is:
SET PATH=C:\j2sdk1.4.2_10\bin
SET CLASSPATH=.\
SET OC4J_HOME=C:\OC4J_101202
SET J2EE_HOME=%oracle_home%\j2ee\home
It may just be that the classpath that you see when you run it in debug mode is missing some of the required jars for the jpub/sqlj stuff. Verify that they are all ok.
Eric -
Log for "Transfer SQL Server Objects" (SSIS 2008)
We are transferring several large tables (Data only) and the Transfer SQL Server Objects Control has remained yellow "state" for six hours. Is there a log file or other approach we can use tell what is happening? (For example, I found the
process spid and ran dbcc inputbuffer(<spid>) but the results are not too helpful. Repeatedly running "sp_who2" show the process as suspended but the CPU\DiskIO numbers are constantly increasing. Go figure)
TIA,
edm2Use Adam's great procedure
Who Is Active? v10.00 (2010-10-21)
(C) 2007-2010, Adam Machanic
Feedback: mailto:[email protected]
Updates: http://sqlblog.com/blogs/adam_machanic/archive/tags/who+is+active/default.aspx
"Beta" Builds: http://sqlblog.com/files/folders/beta/tags/who+is+active/default.aspx
License:
Who is Active? is free to download and use for personal, educational, and internal
corporate purposes, provided that this header is preserved. Redistribution or sale
of Who is Active?, in whole or in part, is prohibited without the author's express
written consent.
Best Regards,Uri Dimant SQL Server MVP,
http://sqlblog.com/blogs/uri_dimant/
MS SQL optimization: MS SQL Development and Optimization
MS SQL Consulting:
Large scale of database and data cleansing
Remote DBA Services:
Improves MS SQL Database Performance
SQL Server Integration Services:
Business Intelligence -
can any1 pls help... i stuck in create logging for my router. i wish to log all the host connected to my router throught SSH. My router only allow ssh or console.
hi
few posts already been here in netpro about ssh ,the H/W platform may vary depending on case to case....
http://forum.cisco.com/eforum/servlet/NetProf?page=netprof&forum=Network%20Infrastructure&topic=LAN%2C%20Switching%20and%20Routing&CommCmd=MB%3Fcmd%3Ddisplay_location%26location%3D.1dd91fb2/0
http://forum.cisco.com/eforum/servlet/NetProf;jsessionid=jswaxxoax1.SJ3B?page=netprof&forum=Network%20Infrastructure&topic=LAN%2C%20Switching%20and%20Routing&CommCmd=MB%3Fcmd%3Ddisplay_location%26location%3D.1dd91d30
would suggest to give a search over here too which will also yield a lot for u..
regds -
ODI's CDC Support for MS SQL Server 2000
Hi,
Does ODI provides CDC with log for MS SQL Server 2000? I read somewhere that we need to get a separately priced adapter for this because ODI supports only trigger based CDC for MS SQL Server 2000 and 2005.
Could anyone please shed some light on this?
Thank you.Hi,
Are you able to find out any info on this?
Appreciate your help on any leads..
Regards
Naveen -
Make EXE for Pl/sql procedure
Hi all,
I have one Pl/sql procedure for which i want make EXE.
can we make EXE files for PL/sql procedures using ' Oracle Developer Tools for Visual Studio .NET'
Thank you.Hi Al,
Can you tell me in steps how to create EXE for pl/sql procedure using C# console application.
I have one webservice link which i want to invoke and i have to put the webservice output in a saparate file.
I wrote Pl/sql procedure which invokes/consumes the webservice using UTL_HTTP and also placed the output of Webservice in a saparate file using UTL_FILE.
But i have to execute this procedure on a Workstation where there is No Oracle installed.
as you suggested using C# console application. Will this Procedure with UTL_FILE & UTL_HTTP packages run in that c# console application.
Thank you -
I m using SQL Server 2012 Developer Edition. Even I tried 2012 express and enterprise edition but all
gave same error. I browsed msdn blog. But nothing help me out.
Below is the error log details--
Overall summary:
Final result: Failed: see details below
Exit code (Decimal): -2061893606
Start time: 2013-10-21 12:58:05
End time: 2013-10-21 13:52:30
Requested action: Install
Setup completed with required actions for features.
Troubleshooting information for those features:
Next step for RS: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Next step for SQLEngine: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Next step for DQ: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Next step for FullText: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Next step for Replication: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Machine Properties:
Machine name: CROY-TOSH
Machine processor count: 4
OS version: Windows 7
OS service pack: Service Pack 1
OS region: United States
OS language: English (United States)
OS architecture: x64
Process architecture: 64 Bit
OS clustered: No
Product features discovered:
Product Instance Instance ID Feature
Language Edition Version Clustered
Package properties:
Description: Microsoft SQL Server 2012 Service Pack 1
ProductName: SQL Server 2012
Type: RTM
Version: 11
SPLevel: 0
Installation location: C:\Users\CRoy\Downloads\SQL Server 2012 Developer Edition (x86 and x64) - DVD (English)\x64\setup\
Installation edition: Developer
Product Update Status:
None discovered.
User Input Settings:
ACTION: Install
ADDCURRENTUSERASSQLADMIN: false
AGTSVCACCOUNT: NT Service\SQLSERVERAGENT
AGTSVCPASSWORD: *****
AGTSVCSTARTUPTYPE: Manual
ASBACKUPDIR: C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Backup
ASCOLLATION: Latin1_General_CI_AI
ASCONFIGDIR: C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Config
ASDATADIR: C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Data
ASLOGDIR: C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Log
ASPROVIDERMSOLAP: 1
ASSERVERMODE: MULTIDIMENSIONAL
ASSVCACCOUNT: NT Service\MSSQLServerOLAPService
ASSVCPASSWORD: <empty>
ASSVCSTARTUPTYPE: Automatic
ASSYSADMINACCOUNTS: CRoy-TOSH\CRoy
ASTEMPDIR: C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Temp
BROWSERSVCSTARTUPTYPE: Disabled
CLTCTLRNAME: ROY
CLTRESULTDIR: C:\Program Files (x86)\Microsoft SQL Server\DReplayClient\ResultDir\
CLTSTARTUPTYPE: Manual
CLTSVCACCOUNT: NT Service\SQL Server Distributed Replay Client
CLTSVCPASSWORD: <empty>
CLTWORKINGDIR: C:\Program Files (x86)\Microsoft SQL Server\DReplayClient\WorkingDir\
COMMFABRICENCRYPTION: 0
COMMFABRICNETWORKLEVEL: 0
COMMFABRICPORT: 0
CONFIGURATIONFILE: C:\Program Files\Microsoft SQL Server\110\Setup Bootstrap\Log\20131021_125116\ConfigurationFile.ini
CTLRSTARTUPTYPE: Manual
CTLRSVCACCOUNT: NT Service\SQL Server Distributed Replay Controller
CTLRSVCPASSWORD: <empty>
CTLRUSERS: CRoy-TOSH\CRoy
ENABLERANU: false
ENU: true
ERRORREPORTING: true
FEATURES: SQLENGINE, REPLICATION, FULLTEXT, DQ, AS, RS, RS_SHP, RS_SHPWFE, DQC, BIDS, CONN, IS, BC, SDK, BOL, SSMS, ADV_SSMS, DREPLAY_CTLR, DREPLAY_CLT, SNAC_SDK, MDS
FILESTREAMLEVEL: 2
FILESTREAMSHARENAME: MSSQLSERVER
FTSVCACCOUNT: NT Service\MSSQLFDLauncher
FTSVCPASSWORD: <empty>
HELP: false
IACCEPTSQLSERVERLICENSETERMS: false
INDICATEPROGRESS: false
INSTALLSHAREDDIR: C:\Program Files\Microsoft SQL Server\
INSTALLSHAREDWOWDIR: C:\Program Files (x86)\Microsoft SQL Server\
INSTALLSQLDATADIR: <empty>
INSTANCEDIR: C:\Program Files\Microsoft SQL Server\
INSTANCEID: MSSQLSERVER
INSTANCENAME: MSSQLSERVER
ISSVCACCOUNT: NT Service\MsDtsServer110
ISSVCPASSWORD: <empty>
ISSVCSTARTUPTYPE: Automatic
MATRIXCMBRICKCOMMPORT: 0
MATRIXCMSERVERNAME: <empty>
MATRIXNAME: <empty>
NPENABLED: 0
PID: *****
QUIET: false
QUIETSIMPLE: false
ROLE: <empty>
RSINSTALLMODE: DefaultNativeMode
RSSHPINSTALLMODE: SharePointFilesOnlyMode
RSSVCACCOUNT: NT Service\ReportServer
RSSVCPASSWORD: <empty>
RSSVCSTARTUPTYPE: Automatic
SAPWD: *****
SECURITYMODE: SQL
SQLBACKUPDIR: <empty>
SQLCOLLATION: Latin1_General_CI_AI
SQLSVCACCOUNT: NT Service\MSSQLSERVER
SQLSVCPASSWORD: *****
SQLSVCSTARTUPTYPE: Automatic
SQLSYSADMINACCOUNTS: CRoy-TOSH\CRoy
SQLTEMPDBDIR: <empty>
SQLTEMPDBLOGDIR: <empty>
SQLUSERDBDIR: <empty>
SQLUSERDBLOGDIR: <empty>
SQMREPORTING: false
TCPENABLED: 0
UIMODE: Normal
UpdateEnabled: true
UpdateSource: MU
X86: false
Configuration file: C:\Program Files\Microsoft SQL Server\110\Setup Bootstrap\Log\20131021_125116\ConfigurationFile.ini
Detailed results:
Feature: Management Tools - Complete
Status: Passed
Feature: Client Tools Connectivity
Status: Passed
Feature: Client Tools SDK
Status: Passed
Feature: Client Tools Backwards Compatibility
Status: Passed
Feature: Management Tools - Basic
Status: Passed
Feature: SQL Server Data Tools
Status: Passed
Feature: Reporting Services - Native
Status: Failed: see logs for details
Reason for failure: An error occurred for a dependency of the feature causing the setup process for the feature to fail.
Next Step: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Component name: SQL Server Database Engine Services Instance Features
Component error code: 0x851A001A
Error description: Wait on the Database Engine recovery handle failed. Check the SQL Server error log for potential causes.
Error help link: http://go.microsoft.com/fwlink?LinkId=20476&ProdName=Microsoft+SQL+Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=11.0.3128.0&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026
Feature: Database Engine Services
Status: Failed: see logs for details
Reason for failure: An error occurred during the setup process of the feature.
Next Step: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Component name: SQL Server Database Engine Services Instance Features
Component error code: 0x851A001A
Error description: Wait on the Database Engine recovery handle failed. Check the SQL Server error log for potential causes.
Error help link: http://go.microsoft.com/fwlink?LinkId=20476&ProdName=Microsoft+SQL+Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=11.0.3128.0&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026
Feature: Data Quality Services
Status: Failed: see logs for details
Reason for failure: An error occurred for a dependency of the feature causing the setup process for the feature to fail.
Next Step: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Component name: SQL Server Database Engine Services Instance Features
Component error code: 0x851A001A
Error description: Wait on the Database Engine recovery handle failed. Check the SQL Server error log for potential causes.
Error help link: http://go.microsoft.com/fwlink?LinkId=20476&ProdName=Microsoft+SQL+Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=11.0.3128.0&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026
Feature: Full-Text and Semantic Extractions for Search
Status: Failed: see logs for details
Reason for failure: An error occurred for a dependency of the feature causing the setup process for the feature to fail.
Next Step: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Component name: SQL Server Database Engine Services Instance Features
Component error code: 0x851A001A
Error description: Wait on the Database Engine recovery handle failed. Check the SQL Server error log for potential causes.
Error help link: http://go.microsoft.com/fwlink?LinkId=20476&ProdName=Microsoft+SQL+Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=11.0.3128.0&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026
Feature: SQL Server Replication
Status: Failed: see logs for details
Reason for failure: An error occurred for a dependency of the feature causing the setup process for the feature to fail.
Next Step: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Component name: SQL Server Database Engine Services Instance Features
Component error code: 0x851A001A
Error description: Wait on the Database Engine recovery handle failed. Check the SQL Server error log for potential causes.
Error help link: http://go.microsoft.com/fwlink?LinkId=20476&ProdName=Microsoft+SQL+Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=11.0.3128.0&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4026
Feature: Master Data Services
Status: Passed
Feature: Distributed Replay Client
Status: Passed
Feature: Distributed Replay Controller
Status: Passed
Feature: Integration Services
Status: Passed
Feature: Data Quality Client
Status: Passed
Feature: Analysis Services
Status: Passed
Feature: Reporting Services - SharePoint
Status: Passed
Feature: Reporting Services Add-in for SharePoint Products
Status: Passed
Feature: SQL Browser
Status: Passed
Feature: Documentation Components
Status: Passed
Feature: SQL Writer
Status: Passed
Feature: SQL Client Connectivity
Status: Passed
Feature: SQL Client Connectivity SDK
Status: Passed
Rules with failures:
Global rules:
Scenario specific rules:
Rules report file: C:\Program Files\Microsoft SQL Server\110\Setup Bootstrap\Log\20131021_125116\SystemConfigurationCheck_Report.htmHi,
This 3rd time I followed this link. But nothing new, same error.
Can you please tell me how to do follow, I cannt do the 1st step, how to change the local system to windows level account, vice-versa. It is shown mine as
Server Configuration Manager(Local)
From here I folllowed the steps ---[I cannt insert link/image :-(]
SQL 2008/R2 setup fails with "Wait on the database engine recovery handle failed"
If I right clicked on SQL Server Service, there is no option to change the account.
Hello,
Thanks for your patience,did you tried stesp mentioned in below article
http://blogs.msdn.com/b/sqljourney/archive/2012/03/16/sql-2008-r2-setup-fails-with-quot-wait-on-the-database-engine-recovery-handle-failed-quot.aspx
To resolve it, follow these steps:-
When the installation throws this error, click on OK and allow it to proceed. It will fail for Database Engine, but the SQL Server service should have
been created. Check the Services console.
If the service is present, perform the following steps:-
1. Go to SQL Server Configuration manager, right click on the SQL Server service, and change the service account (if it is local system, give
it a windows level account, and vice-versa). It might throw a WMI error but you will see the account getting updated anyway. If not, then use the Services console. Change the account for SQL Agent as well.
Use this link to change sql server service account
http://technet.microsoft.com/en-us/library/ms345578.aspx
2. Next, try to start the service. It should come online.
3. However, you will not be able to log in to the SQL Server
4. Now stop the service and start it from the command prompt using -m -c -T3608 parameters.
5. Now try logging in to the server using admin connection from sqlcmd (sqlcmd admin:<server name>\<instance name> ...)
6. Once logged in, use the sp_addsrvrolemember '<domain\username>','sysadmin'.
Also add the builtin/administrators to the sysadmin role
7. Now stop the service from the command prompt and start it from SQL Server configuration manager
You should be able to log in to the server now.
Hope this helps someone.
Please revert if it helps or even if it does not
Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers -
Logs for sql server agent restart
Hi,
Can I get log on the sql server agent restart history of week. I mean the sql server agent has been restarted several times in last week I want to know the date and time when the sql server agent restarted in that week. Is it possible to get
the info?
Thanks in advance,
Pavan
PavanIn addition to Uri's post, here is some more information that might help you:
SQLAGENT.OUT, the log file for SQL Agent. SQL Server Agent can maintain up to 10 Error Logs files. The currently used SQL Server Agent Error Log will be named SQLAGENT.OUT
where is the SQLAGENT.OUT file?
C:\Program Files\Microsoft SQL Server\MSSQL11.SQL2012\MSSQL\Log\
What will be when a new file create?
The old file should get a name like SQLAGENT.X and the new file get the name SQLAGENT.OUT (X is numbers 1-9)
This can help you to get more information on sql agent properties (like the location of the log file, the user that start the service and more):
EXEC msdb..sp_get_sqlagent_properties
[Personal Site] [Blog] [Facebook] -
How to monitor Log Backups for MS SQL Server
Hello all.
We are running Solution Manager 7.1 on SP Stack 10 and have downloaded the latest template content.
When configuring the templates for DB monitoring, we noticed that although there is a metric that monitors the age of the last DB backup, there is no such metric to monitor the age of the last successful Log backup, or even a metric to alert us on a failed backup / log backup.
Has any of you ever had to create a custom metric to monitor either the age of the latest successful log backup for MS SQL Server, or a custom metric to alert on failed backups / log backups?
If yes, could you provide some instructions on how to create such a metric?
Thank you in advance for your answers.
PhevosDivyanshu, thank you for your answer.
I had a similar idea to check the DB log file for failed log backups. The problem is that when I opened the log file from the dbacockpit, I found no errors/warnings for the days that our log backups did not run or failed. Here is a small part of that log to show you what I mean. In this example, the log backup was not running from 25th of July until the 28th of July when we fixed the log backups again, after receiving a disk space warning (log disk drive was almost full):
The last successful log backup is mentioned in the log: "20140724091524 Backup Log was backed up"
Then as the days go by, there is no backup failure entries whatsoever to look for them in the log:
20140725000023 spid18s This instance of SQL Server has been using a process ID of 1304 since 5/27/2014 11:50:00 PM (local) 5/28/2014 6:50:00
20140725000023 spid18s AM (UTC). This is an informational message only; no user action is required.
20140726000020 spid21s This instance of SQL Server has been using a process ID of 1304 since 5/27/2014 11:50:00 PM (local) 5/28/2014 6:50:00
20140726000020 spid21s AM (UTC). This is an informational message only; no user action is required.
20140727000023 spid22s This instance of SQL Server has been using a process ID of 1304 since 5/27/2014 11:50:00 PM (local) 5/28/2014 6:50:00
20140727000023 spid22s AM (UTC). This is an informational message only; no user action is required.
20140728000022 spid17s This instance of SQL Server has been using a process ID of 1304 since 5/27/2014 11:50:00 PM (local) 5/28/2014 6:50:00
20140728000022 spid17s AM (UTC). This is an informational message only; no user action is required.
Until finally on the 28th we restored the log backup functionality:
20140728042814 Backup Log was backed up. Database: XXX, creation date(time): 2010/12/22(16:45:29)
So, I find it difficult to deduce an appropriate string to look for in the log, in order to generate an alert when my log backups are not working.
Any suggestions? Am I looking at the wrong place perhaps? -
Need Guide to create a table in SQL Server and Process data for JDBC
Dear All,
Scenario:JDBC to JDBC
I need to practice JDBC to JDBC scenario and for that i need to create a table in SQL server for sender ,receiver and update i have installed SQL Server and no idea about creation of table and Connection string for PI.
I want you to explain each and every step for the Table Creation ,Driver and connection string.
Thanks in Advance.Try searchin in the forum and then google. This forum is not for teaching the basics.
VJ -
How can I create a log for the dice roll generator on my website?
Here is my website: http://gator789.hostgator.com/~stillman/index.html
I want to create a log for each time the roll button is clicked to generate a random image of a six-sided die on my website. I was thinking maybe a MySQL database with PHP would get me what I want? I have no idea how I would start setting this up though. I don't want to sound to pushy here, but I would also like to have a form setup above the roll button for name details, etc. How would I go about doing this?I don't understand why you need a log to generate a random number. The logic behind a random javascript image generator with a math function is all you need. Put your gif images into an array and let the script do the rest.
http://eposic.org/samples/dice/part1.php
Nancy O.
Alt-Web Design & Publishing
Web | Graphics | Print | Media Specialists
http://alt-web.com/
http://twitter.com/altweb
http://alt-web.blogspot.com -
I have created an RDL file programatically. When I execute the code I get the error as mentioned below:
Error: Sub report cannot be shown.
An internal error occurred on the report server. See the error log for more details. (rsInternalError)
When I copy and paste the code of RDL file into new RDL file and try to preview the output I get correct result.
Note: The new RDL file does not give any error if the output is seen using preview tab but it gives the error only when executed from report viewer or from internet explorer.
Any Suggestion/feedback is highly appreciated.
Thank You.
The code of the sample RDL is shown below:
<?xml version="1.0" encoding="utf-8"?>
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
<DataSources>
<DataSource Name="DataSource1">
<DataSourceReference>DataSource1</DataSourceReference>
<rd:DataSourceID>fe4806ee-0358-4a87-b764-ac5de049545e</rd:DataSourceID>
</DataSource>
</DataSources>
<BottomMargin>0.25in</BottomMargin>
<RightMargin>0.25in</RightMargin>
<PageWidth>11in</PageWidth>
<ReportParameters>
<ReportParameter Name="machine_id">
<DataType>String</DataType>
<Prompt>machine_id</Prompt>
</ReportParameter>
<ReportParameter Name="from_date">
<DataType>String</DataType>
<AllowBlank>true</AllowBlank>
<Prompt>From Date</Prompt>
</ReportParameter>
<ReportParameter Name="to_date">
<DataType>String</DataType>
<AllowBlank>true</AllowBlank>
<Prompt>To Date</Prompt>
</ReportParameter>
</ReportParameters>
<rd:DrawGrid>true</rd:DrawGrid>
<InteractiveWidth>8.5in</InteractiveWidth>
<rd:SnapToGrid>true</rd:SnapToGrid>
<Body>
<ReportItems>
<Table Name="table1">
<DataSetName>Main_Report</DataSetName>
<TableGroups>
<TableGroup>
<Header>
<TableRows>
<TableRow>
<TableCells>
<TableCell>
<ReportItems>
<Textbox Name="textbox2">
<rd:DefaultName>textbox2</rd:DefaultName>
<ZIndex>1</ZIndex>
<Style>
<TextAlign>Left</TextAlign>
<PaddingLeft>2pt</PaddingLeft>
<PaddingBottom>2pt</PaddingBottom>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
</Style>
<CanGrow>true</CanGrow>
<Value>=Fields!syscode.Value</Value>
</Textbox>
</ReportItems>
</TableCell>
</TableCells>
<Height>0.25in</Height>
</TableRow>
</TableRows>
<RepeatOnNewPage>true</RepeatOnNewPage>
</Header>
<Grouping Name="table1_Group1">
<PageBreakAtEnd>true</PageBreakAtEnd>
<GroupExpressions>
<GroupExpression>=Fields!syscode.Value</GroupExpression>
</GroupExpressions>
</Grouping>
</TableGroup>
</TableGroups>
<Details>
<TableRows>
<TableRow>
<TableCells>
<TableCell>
<ReportItems>
<Subreport Name="subreport1">
<Parameters>
<Parameter Name="machine_id">
<Value>=Fields!machine_ip.Value</Value>
</Parameter>
<Parameter Name="syscode">
<Value>=Fields!syscode.Value</Value>
</Parameter>
<Parameter Name="from_date">
<Value>=Parameters!from_date.Value</Value>
</Parameter>
<Parameter Name="to_date">
<Value>=Parameters!to_date.Value</Value>
</Parameter>
</Parameters>
<ReportName>Holding_Summary_Multi_Period</ReportName>
</Subreport>
</ReportItems>
</TableCell>
</TableCells>
<Height>0.25in</Height>
</TableRow>
</TableRows>
</Details>
<TableColumns>
<TableColumn>
<Width>10.5in</Width>
</TableColumn>
</TableColumns>
<Height>0.5in</Height>
</Table>
</ReportItems>
<Height>0.75in</Height>
</Body>
<rd:ReportID>d0a1293a-e98c-4f75-9597-03426d2e7218</rd:ReportID>
<LeftMargin>0.25in</LeftMargin>
<DataSets>
<DataSet Name="Main_Report">
<Query>
<rd:UseGenericDesigner>true</rd:UseGenericDesigner>
<CommandText>select account_syscode as syscode , 'display Name' as display_name , * from mars_customer_list
where machine_ip = @machine_id</CommandText>
<QueryParameters>
<QueryParameter Name="@machine_id">
<Value>=Parameters!machine_id.Value</Value>
</QueryParameter>
</QueryParameters>
<DataSourceName>DataSource1</DataSourceName>
</Query>
<Fields>
<Field Name="syscode">
<rd:TypeName>System.Int64</rd:TypeName>
<DataField>syscode</DataField>
</Field>
<Field Name="display_name">
<rd:TypeName>System.String</rd:TypeName>
<DataField>display_name</DataField>
</Field>
<Field Name="customer_syscode">
<rd:TypeName>System.Int64</rd:TypeName>
<DataField>customer_syscode</DataField>
</Field>
<Field Name="account_syscode">
<rd:TypeName>System.Int64</rd:TypeName>
<DataField>account_syscode</DataField>
</Field>
<Field Name="machine_ip">
<rd:TypeName>System.String</rd:TypeName>
<DataField>machine_ip</DataField>
</Field>
</Fields>
</DataSet>
</DataSets>
<Code>Shared offset As Integer
Public Function GetPN(reset As Boolean, pagenumber As Integer) As Integer
If reset
offset = pagenumber - 1
End If
Return pagenumber - offset
End Function
</Code>
<Width>10.5in</Width>
<InteractiveHeight>11in</InteractiveHeight>
<Language>en-US</Language>
<PageFooter>
<ReportItems>
<Image Name="image1">
<Sizing>Fit</Sizing>
<Left>8.875in</Left>
<MIMEType />
<Width>1.5in</Width>
<Source>External</Source>
<Style />
<Value>bottom_right_logo.gif</Value>
</Image>
</ReportItems>
<Height>0.5in</Height>
<PrintOnLastPage>true</PrintOnLastPage>
<PrintOnFirstPage>true</PrintOnFirstPage>
</PageFooter>
<TopMargin>0.5in</TopMargin>
<PageHeight>8.5in</PageHeight>
</Report>i created a SSRS report with shared datasets and uploaded rdl files and rsd files , while trying to map rdl file with data sets i am getting an error
when i click on manage for .rdl file, its throwing error , as
"An internal error occurred on the report server. See the error log for more details. (rsInternalError)
Object reference not set to an instance of an object.
please help me with this
Maybe you are looking for
-
Itunes on Windows Vista with SATA Intel Raid Matrix, BLUE SCREEN!
If I wasn't an IT Administrator this problem could've really upset me. I might have perceived your software crashed my hard drives. At least I had the knowledge to know how to re-detect my raid array and get things going; but for a moment i was worri
-
I am trying to signon as sys to Oracle 9i personal edition with Toad. I can signon as scott or system but when I try signon with sys/password as sysdba it gives me a error. When I sign on using Oracle SQL*Plus it works fine. Can you tell me how to us
-
Hello, In my report, I want to change how the parameter (prompt) dialogue box is setup, like where to place the parameters and change the size of the parameters and so on... For example, I want the parameters to be located side by side in the prompt
-
My Mac is very slow, after installing mac OS x snow leopard
Hi I am quite sad to note that the new Mac OS X Snow leopard software is a big let down. After installing i found my mac has become very slow, its taking a long time to process applications and stuff. It does not shut down completely, i get an error
-
Is there any way to enable support for the 'cvs edit -c' command in 9.0.3? The -c option is available in a special branch of CVS and forces the edit command to abort if somebody else is already editing the requested file. The version of cvs that come