Getting [Microsoft][ODBC SQL Server Driver] Optional feature not implemented
I am using below mentioned code to insert values in MSAccess 2000 which having table structure as mentioned below:-
Field Name Data Type
TodaysDate Date/Time
Cart ID Number
Client Name Text
Campaign Text
Team & Segment Text
Duration Number
Tape ID Text
Start Date Date/Time
End Date Date/Time
Station Text
Code:-
private boolean enterDataIntoMSAccessDatabaseusingPreparedStatement()
try {
ps = connection.prepareStatement("INSERT INTO Cart ID Details VALUES (?,?,?,?,?,?,?,?,?)");
System.out.println("After Query");
catch (SQLException se) {
generateErrorMessage("Error in Prepared Statement \n " + se.getMessage() );
return false;
catch (Exception e)
generateErrorMessage("Unexpected Error Occured \n " + e.getMessage());
String todaysDate = cartIDApplicationAddCartIDDatejTextField.getText().trim();
String cartID = cartIDApplicationAddCartIDCartIDjTextField.getText().trim();
String clientName = cartIDApplicationAddCartIDClientNamejTextField.getText().trim();
String campaign = cartIDApplicationAddCartIDCampaignjTextField.getText().trim();
String teamSegment = cartIDApplicationAddCartIDTeamAndSegmentjTextField.getText().trim();
String duration = cartIDApplicationAddCartIDDurationjTextField.getText().trim();
String tapeID = cartIDApplicationAddCartIDTapeIDjTextField.getText().trim();
String startDate = cartIDApplicationAddCartIDStartDatejTextField.getText().trim();
String endDate = cartIDApplicationAddCartIDEndDatejTextField.getText().trim();
String station = cartIDApplicationAddCartIDDELjCheckBox.getText().substring(0, 3);
System.out.println(station);
try {
System.out.println("Before ps.setString()");
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-mm-dd", Locale.ENGLISH);
System.out.println("Simple Date Format");
/*ps.setString(1, todaysDate);
ps.setString(2, cartID );
ps.setString(3, clientName);
ps.setString(4, teamSegment);
ps.setString(5, duration);
ps.setString(6, tapeID);
ps.setString(7, startDate);
ps.setString(8, endDate);*/
System.out.println("1");
ps.setDate(1, new java.sql.Date(simpleDateFormat.parse(todaysDate).getTime()));
ps.setString(2, cartID);
ps.setString(3, clientName);
ps.setString(4, campaign);
ps.setString(5, teamSegment);
ps.setString(6, duration);
ps.setString(7, tapeID);
ps.setDate(8, new java.sql.Date(simpleDateFormat.parse(startDate).getTime()));
ps.setDate(9, new java.sql.Date(simpleDateFormat.parse(endDate).getTime()));
ps.setString(10, station);
System.out.println("After ps.setString()");
ps.executeUpdate();
catch (SQLException se) {
generateErrorMessage("Error while inserting data in database \n " + se.getMessage());
return false;
catch (Exception e)
generateErrorMessage("Unexpected Error Occured \n" + e.getMessage() );
return true;
I got below error after implementing the above code:-
[Microsoft][ODBC SQL Server Driver]Optional feature not implemented.
Kindly help me for the same.
>> [Microsoft][ODBC SQL Server Driver]
I don't see anything Oracle in your question. It looks like you're getting an error using Microsoft's SQL Server driver, did you mean to post this to a forum on Microsoft's site perhaps?
Similar Messages
-
Microsoft][ODBC SQL Server Driver]Optional feature not implemented
this is my program code for java jdbc:odbc SQL connectivity
but iam getting the error as
*java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Optional feature not implemented*
package desktopapplication2;
import java.sql.*;
* @author Bharat Raj Verma
public class db {
void get(String gr,String fn,String ln,String job ,Integer rate,Integer ot,String att,long amt,String cmt)
try
Connection con=null,con1=null;
Statement stmt2;
String query = "Update dbo.attend SET Gr = ? , fn = ? ,ln = ?, job = ? , rate = ? , ot = ? , att = ? ,amt = ? , comment = ?";
// String query1 = "Select accnum rom dbo.newacc where accnum= ?";
String url = "jdbc:odbc:bharat";
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
con = DriverManager.getConnection(url,"","");
con1 = DriverManager.getConnection(url,"","");
System.out.println("connection Established");
stmt2 = con.createStatement();
Statement stmt = con1.createStatement();
ResultSet rs;
rs=stmt.executeQuery("select * from dbo.attend");
while(rs.next())
String cmp1= rs.getString("gr");
if(cmp1.equalsIgnoreCase(gr))
PreparedStatement ps1 = con.prepareStatement(query);
System.out.println("Insisde RS");
ps1.setString(1,gr);
ps1.setString(2,fn);
ps1.setString(3,ln);
ps1.setString(4,job);
ps1.setInt(5,rate);
ps1.setInt(6,ot);
ps1.setString(7,att);
ps1.setLong(8,amt);
ps1.setString(9,cmt);
System.out.println("SSS");
// ps1.setString(1,gr);
ps1.executeUpdate();
System.out.println("Success");
catch(Exception e1)
System.err.println(e1);
}This is the SQL table in which iam trying to insert the value
SET ANSI_PADDING OFF
create table attend
Gr VARCHAR(20) primary key,
fn VARCHAR (25),
ln VARCHAR(25),
job VARCHAR(25),
rate integer,
ot integer,
att varchar(10),
amt varchar (10),
comment varchar(70)
)the complete output is
init:
deps-jar:
Compiling 1 source file to C:\Documents and Settings\Bharat Raj Verma\My Documents\NetBeansProjects\DesktopApplication2\build\classes
compile:
run:
connection Established
Insisde RS
java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Optional feature not implemented
BUILD SUCCESSFUL (total time: 29 seconds)
here is the stack trace
java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Optional feature not implemented
at sun.jdbc.odbc.JdbcOdbc.createSQLException(JdbcOdbc.java:6958)
at sun.jdbc.odbc.JdbcOdbc.standardError(JdbcOdbc.java:7115)
at sun.jdbc.odbc.JdbcOdbc.SQLBindInParameterBigint(JdbcOdbc.java:1225)
at sun.jdbc.odbc.JdbcOdbcPreparedStatement.setLong(JdbcOdbcPreparedStatement.java:592)
at desktopapplication2.db.get(db.java:47)
at desktopapplication2.DesktopApplication2View.jButton1ActionPerformed(DesktopApplication2View.java:394)
at desktopapplication2.DesktopApplication2View.access$800(DesktopApplication2View.java:22)
at desktopapplication2.DesktopApplication2View$4.actionPerformed(DesktopApplication2View.java:183)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)
at java.awt.Component.processMouseEvent(Component.java:5517)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3135)
at java.awt.Component.processEvent(Component.java:5282)
at java.awt.Container.processEvent(Container.java:1966)
at java.awt.Component.dispatchEventImpl(Component.java:3984)
at java.awt.Container.dispatchEventImpl(Container.java:2024)
at java.awt.Component.dispatchEvent(Component.java:3819)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
at java.awt.Container.dispatchEventImpl(Container.java:2010)
at java.awt.Window.dispatchEventImpl(Window.java:1791)
at java.awt.Component.dispatchEvent(Component.java:3819)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
Plz can anyone help ???and what was the solution?
thanks in advance
brindy -
[ODBC SQL Server Driver]Optional feature not implemented
Hi,
Has anyone faced such error @ analysis,
Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P
State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43113] Message returned from OBIS. [nQSError: 43119] Query Failed: [nQSError: 16001] ODBC error state: S1C00 code: 0 message: [Microsoft][ODBC SQL Server Driver]Optional feature not implemented. [nQSError: 16012] ODBC error occurred while binding the parameters of a SQL statement. (HY000)
we are having some issue on DBfeature check box issue.
Thanks
DevaHi,
Yes. after that only i am getting error. if i enabled Query DBMS then report is working with out error (we don't want to use query dbms option that's i just query dbms off option by Reset to default) then its thoewing error.
Thanks
Deva -
in my project i wanted insert a date object to the database for that i am using PreparedStatement.setDate(fieldNum,dateObject), i tried out the code segmets and used the java.sql.date onject only but i am gettig the exception"java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Optional feature not implemented".see the code below which i used
String sql = "insert into debug (filing_date) values (?)";
PreparedStatement insertPS = dbConn.prepareStatement(sql);
String dateS = "2001-00-01"; //That's jan 1, 2001
java.sql.Date date = java.sql.Date.valueOf(dateS);
insertPS.setDate(1,date);
insertPS.executeUpdate();
@@@@@@@@@@@@ i tried using this way also to get into the real format "MMM d, yyy"but got the exceptoin this time also, the code is
MMM d, yyy format, which java.sql.Date doesn't accept: String dateIn = "January 1, 2001"; String formatIn = "MMM d, yyyy"; // format of incoming string
//parse the date using java.util.Date classes
ParsePosition pp = new ParsePosition(0);
SimpleDateFormat sdfi = new SimpleDateFormat(formatIn);
java.util.Date date = sdfi.parse(dateIn,pp);
if( date == null ) (throw new RuntimeException"Unparsable date: "+dateIn);
//convert a java.util.Date to a java.sql.Date
java.sql.Date sqlFromLong = new java.sql.Date(date.getTime());
//output is: 2001-01-01 System.out.println("sqlFromLong (java.sql.Date): "+sqlFromLong);
pls help me regardig this thanks in advance susanthSame question at the ranch...
http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topic&f=3&t=009727 -
Hi All,
I am getting the following error when i am running swing program. I have a large volume of data. My resultset is running upto 2 hours. after 2 hours process is stoped and i got the following error on console.I am using Swing and MS SQL Server 2000.
Exception :java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Unspecified error occurred on SQL Server. Connection may have been terminated by the server.
Exception :java.sql.SQLException: General error
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:464)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:169)
Exception :java.sql.SQLException: General error
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:469)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:169)
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:474)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:169)
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'T'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'T' order by tblTransaction.FareBasis
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:419)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:424)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'T'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'T' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
java.lang.Exception: Invalid handle [null] Database error code:0
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'T'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:429)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:434)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'T' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closedjava.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:439)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:444)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'T'
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:449)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'T' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'T'
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:454)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'T' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'T'
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:459)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'T' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:464)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:469)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 4 : select count(*) from tblTransaction where AuditID = 10001720 and ExcludedFromAudit = 'F' and SystemPricedFare = 'F'
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.batchTransactions(GenerateAuditBatches.java:966)
at com.select.auditlink.GenerateAuditBatches.batchAudit(GenerateAuditBatches.java:474)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:172)
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
GenerateAuditBatches.java sql 5 transactions : select tblTransaction.BatchID, tblTransaction.TransactionNumber, tblTransaction.PrimeDocumentNumber, tblTransaction.AgentIATACode, tblTransaction.NetRemitInd, tblTransaction.ITBTFare, tblTransaction.TourCode, tblTransaction.FareBasis, tblTransaction.TransactionCode, tblTransaction.TransactionCategory, tblTransaction.InternationalOrDomestic, tblTransaction.NumberOfSectors, tblTransaction.TransactionStatus, tblTransaction.TransactionStatusUserID, tblTransactionCRSCheck.FareCorrect, tblTransactionCRSCheck.TaxCorrect, tblTransactionCRSCheck.CommissionCorrect, tblTransactionCRSCheck.ContractRulesCorrect, tblTransactionCRSCheck.ContractID from tblTransaction left join tblTransactionCRSCheck on tblTransactionCRSCheck.AuditID = tblTransaction.AuditID and tblTransactionCRSCheck.TransactionNumber = tblTransaction.TransactionNumber where tblTransaction.AuditID = 10001720 and tblTransaction.ExcludedFromAudit = 'F' and tblTransaction.SystemPricedFare = 'F' order by tblTransaction.FareBasis
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 1 : update tblAudit set NumberOfBatches = 1078 where AuditID = 10001720
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 12 query2 : select BatchID from tblAuditBatch where AuditID = 10001720
Exception :java.sql.SQLException: Invalid handle
Exception :java.lang.Exception: Invalid handle [null] Database error code:0
java.lang.Exception: Invalid handle [null] Database error code:0
at com.select.auditlink.GenerateAuditBatches.updateAuditBatches(GenerateAuditBatches.java:1427)
at com.select.auditlink.GenerateAuditBatches.run(GenerateAuditBatches.java:217)
GenerateAuditBatches.java sql 2 : update tblAudit set NumberOfAuditedBatches = ( select count(*) from tblAuditBatch where AuditID = 10001720 and NumberOfAuditedTransactions = NumberOfTransactions) where AuditID = 10001720
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
GenerateAuditBatches.java sql 3 : update tblAudit set NumberOfAuditedTransactions = ( select count(*) from tblTransaction where AuditID = 10001720 and Audited = 'T') where AuditID = 10001720
Exception :java.sql.SQLException: Invalid handle
Exception :java.sql.SQLException: Connection is closed
Exception :java.sql.SQLException: Connection is closed
Please give me suitable solution of this issue.
Thanks
Rajnish
Message was edited by:
rajnishsunjavajava.sql.SQLException: [Microsoft][ODBC Visual FoxPro Driver]File must be opened exclusively.
In the Visual Foxpro table, I saw no READ ONLY settings.And also, there are
no delete permission grants and there is no user database sesssion concept.
The ODBC DSN for MYTABLE is setup as:
- Free Tables (not database)
- Null (checked)
- Deleted (checked)If you're using Visual Foxpro database(.DBC), you should see "Exclusive" option too. You can try check it, but I don't know whether your issue will disappear. -
Help,
setup a new sql server 2012 on a windows 2012r2 server to replace old sql server 2005 on an old windows server 2003 machine. When i test the ODBC connection locally on the server it works fine, however when i try to connect via windows 7 client machine
i get the following error:
Connection failed:
SQLState:'01000'
SQL Server Error:67
[Microsoft]ODBC SQL Server Driver][DBNETLIB]ConnectionOpen
(Connect()).
Connection failed:
SQLState:'08001'
SQL Server Error:17
[Microsoft]ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist or access denied
I think it must be a permissions thing, I've turned off the firewall for now and still no difference, 've also made sure remote connection is enabled. I can connect to the other sql server in studio manager on the new machine however, i can't go do
the same in the old server, says:
cannot connect to hbfsqlpro1\hbfsqlpro1
Additonal information a network related or instance specifc error occured while establising a connection to SQL server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL server is configured to
allow remote connections. (provider:SQL Network Interfaces, error 26 - error locationg server/instance specified) (Microsoft SQL server)
the instance is def correct, as that is what i use to connect locally on the new machine and what it comes up on the studio manager on the new machine. STarting to pull my hair out somewhat, i'm sure it's something really simple!Hello,
You are trying to connect to a named instance. Make sure the SQL Server Browser service is started on the SQL Server computer.
Make sure TCP/IP is enabled.
http://msdn.microsoft.com/en-us/library/ms191294(v=sql.110).aspx
Try to disable Windows Firewall or security software on both, SQL Server instance and client computer.
Test basic connectivity too. Try to ping from the client computer to the SQL Server computer.
Hope this helps.
Regards,
Alberto Morillo
SQLCoffee.com -
Hi All,
when i add setAutoCommit(false),
i got run error [Microsoft][ODBC Excel Driver]Optional feature not implemented.
i just want to insert data into excel using db.
can anyone give suggestion??
here my code:
public void insertDatabase( ){
String rule = "fty";
double weight = 0.245;
try{
String sql = "INSERT INTO [Sheet2$] ( Rule, Weight ) " +
"VALUES ( '"+ rule +"', '" + weight + "' )";
int row = myStatement.executeUpdate(sql);
myConnect.setAutoCommit(false);
myResultSetPapar = myStatement.executeQuery("Select * from [Sheet2$]");
catch(SQLException e){
System.out.println(e.getMessage());
}//catch
}is it true that my driver does not supported??
my MS Excel version 2002
and driver vers. 4.0 -
BO XI 3.1 in Webi Rich Client, i get this when I use the default Audit Universe to run the Sample Auditing Report.
A database error occured. The database error text is: [Microsoft][ODBC SQL Server Driver][SQL Server]Statement(s) Could not prepared..(WIS 10901)
In infoview webi i get this,
A Database error occured. The database error text is: [Microsoft][ODBC driver Manager] Data source name not found and no default driver specified. (WIS 10901)
We tried checking all the rights and we are trying this using the Administrator user. Also tried logon to Desinger, Import Auditing Universe and Verify the Parameters and then re exported. Still not workingHi Prasanth,
Thanks for your suggestions and I tried all that what I can do along with your suggestion, and still getting the same error, all the connection are working fine, but when I checked for Integrity, Parse Object and Cardinality I was getting some Object error and cardinality error, which am trying to resolve, so I think am having a wrong version of the Activity Universe.
Thanks for your suggestion.
Thanks and Regards
Senthil -
Hi All,
I am getting the following message, when i try to retreive the child object from the parent..
Session sess = sessionFactory.openSession();
Team obj = (Team) sess.load(Team.class, new Long(2457600));
Set s = obj.getPlayers();
System.out.println("PLayer -- "+obj.getPlayers());
Error Message :
org.hibernate.exception.GenericJDBCException: could not initialize a collection: [com.test.Team.players#2457600]
org.hibernate.exception.GenericJDBCException: could not initialize a collection: [com.test.Team.players#2457600]
at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:82)
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:70)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.loadCollection(Loader.java:1351)
at org.hibernate.loader.collection.OneToManyLoader.initialize(OneToManyLoader.java:106)
at org.hibernate.persister.collection.AbstractCollectionPersister.initialize(AbstractCollectionPersister.java:484)
at org.hibernate.event.def.DefaultInitializeCollectionEventListener.onInitializeCollection(DefaultInitializeCollectionEventListener.java:60)
at org.hibernate.impl.SessionImpl.initializeCollection(SessionImpl.java:1346)
at org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:170)
at org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCollection.java:47)
at org.hibernate.collection.PersistentSet.toString(PersistentSet.java:221)
at java.lang.String.valueOf(String.java:2131)
at java.lang.StringBuffer.append(StringBuffer.java:370)
at com.test.TeamPlayer.main(TeamPlayer.java:70)
Caused by: java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index
at sun.jdbc.odbc.JdbcOdbc.createSQLException(JdbcOdbc.java:6958)
at sun.jdbc.odbc.JdbcOdbc.standardError(JdbcOdbc.java:7115)
at sun.jdbc.odbc.JdbcOdbc.SQLGetDataDouble(JdbcOdbc.java:3658)
at sun.jdbc.odbc.JdbcOdbcResultSet.getDataDouble(JdbcOdbcResultSet.java:5579)
at sun.jdbc.odbc.JdbcOdbcResultSet.getLong(JdbcOdbcResultSet.java:635)
at sun.jdbc.odbc.JdbcOdbcResultSet.getLong(JdbcOdbcResultSet.java:653)
at org.hibernate.type.LongType.get(LongType.java:26)
at org.hibernate.type.NullableType.nullSafeGet(NullableType.java:77)
at org.hibernate.type.NullableType.nullSafeGet(NullableType.java:68)
at org.hibernate.persister.collection.AbstractCollectionPersister.readKey(AbstractCollectionPersister.java:612)
at org.hibernate.loader.Loader.readCollectionElement(Loader.java:545)
at org.hibernate.loader.Loader.readCollectionElements(Loader.java:344)
at org.hibernate.loader.Loader.getRowFromResultSet(Loader.java:299)
at org.hibernate.loader.Loader.doQuery(Loader.java:384)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:203)
at org.hibernate.loader.Loader.loadCollection(Loader.java:1344)
... 10 more
Team [Parent] <--> Player [Child]
Team.hbm.xml
<hibernate-mapping>
<class name="com.test.Team" table="dbo.teams">
<id name="id" column="team_id" >
<generator class="hilo"/>
</id>
<property name="name" column="team_name" />
<property name="city" column="city" />
<set name="players" cascade="all" inverse="true" lazy="true">
<key column="team_id"/>
<one-to-many class="com.test.Player"/>
</set>
</class>
</hibernate-mapping>
PLayer.hbm.xml:
<hibernate-mapping>
<class name="com.test.Player" table="dbo.players">
<id name="id" column="player_id">
<generator class="hilo"/>
</id>
<property name="firstName" column="first_name" />
<property name="lastName" column="last_name" />
<property name="draftDate" column="draft_date" />
<property name="annualSalary" column="salary" />
<property name="jerseyNumber" column="jersey_number" />
<many-to-one name="team" class="com.test.Team" column="team_id" />
</class>
</hibernate-mapping>
Any help would be highly appreciated..
Thanks,
/Shridhar..http://forums.hibernate.org/viewtopic.php?t=928277&view=next&sid=e3ed34f2b57526386ba6ac7ac29b6471
-
[Microsoft][ODBC SQL Server Driver][SQL Server]
I have a stored procedure named windog_ReadSpecifications in a database called AssetDB and schema dbo, one of my users is getting the following errors when she try's to use a program which executes the stored procedure
"Error description:COM error message: [Microsoft][ODBC SQL Server Driver][SQL Server]The EXECUTE permission was denied on the object 'windog_ReadSpecifications', database 'AssetDB', schema 'dbo'."
I am not sure why she is getting this error because she is a user who has all permissions required to execute the stored procedure . Any help on how to approach this is highly appreciated.
thanks.i ran fn_my_permissions as the user and it returned an empty
Empty result means: No effective permissions. Have you checked it the right way with:
select *
from fn_my_permissions('AssetDB.dbo.windog_ReadSpecifications', 'OBJECT');
Olaf Helper
[ Blog] [ Xing] [ MVP] -
OK, something seemed to have changed with my system because this error is NEW. It might be related to my system upgrade from Vista to Win7, but just guessing here.
I run a database on a corporate MS Sql Server (2005) and an ASP application that connects via ODBC. The real world application works fine, however when I attempt to access Stored Procedures from Dreamweaver (on my development machine) I am getting the following error:
[Microsoft][ODBC SQL Server Driver][SQL Server]Could not find stored procedure 'dbo.sp_SPNAMEHERE'.
This only seems to happen on Stored procedures that RETURN a recordset.
system:
Win7
Dreamweaver CS4
Code: VBScript/Classic ASP
SQL Server 2005
Connecting via ODBC: MM_MY_STRING = "Driver={SQL Server};Server=wscxxxxxxxxx;Database=dbsystem;Uid=username;Pwd=XXXXXXXXXXXX"
Stored procedures that do not return a recordset are not an issue.... this has put my development work at a standstill!!
Thanks in advance!Well, I hate bumps, but I am really running out of solutions. I have now tried to use a system DSN on my development machine and that didnt solve the problem. I just un-installed DW and re-installed it and that didnt solve my problem either.
This is very frustrating, because I cannot use any stored procs that return recordsets... I am stuck... can anybody think of a relatively easy work-around to working in DW w/ recordsets that come from SPs when you cant actually access them?
The really weird thing is, when I build the command, and choose the stored proc, and give it valid input variables, and TEST it from the TEST button, everything works and data is returned as expected. Once I click "OK" and actually add it to the ASP page the recordset that should be visible isnt... and when I click the plus sign in the bindings window I get the error...
Help!! -
Hi, I've seen questions about this error posted elsewhere but I'm not sure if the same issues applied.
I'm trying to connect to SQL Server from a VBA macro in excel. I've managed to do this with the code below where my query is return to cells in my active worksheet but for another query I want to run the data to be return is too large for Excel to handle
and so I'd like to save it as a .csv file but using the second example of my code I get the message "[Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist or access denied". Since I have access to this database from the first example
of the code, I assume my conn.ConnectionString line of code is letting me down.
Can anyone help me please?
'Code to return data to worksheet'
Sub macro2()
With ActiveSheet.ListObjects.Add(SourceType:=0, Source:=Array(Array( _
"ODBC;DSN=SQLRA - OPENBET;UID=user1;Trusted_Connection=Yes;APP=Microsoft Office 2013;WSID=pdfdf3001;DATABASE=open;Network=DBMSS" _
), Array("OCN;Address=SQLRA_DB,55455;ApplicationIntent=READONLY;")), _
Destination:=Range("$BG$1")).QueryTable
.CommandText = Array( _
"select A.ev_oc_id, B.ev_mkt_id, A.ev_id, D.start_Time, Upper(Replace(A.[desc],'|','')) , A.result, COALESCE(A.sp_num, A.lp_num) , ", _
"COALESCE(A.sp_Den, A.lp_Den) from open.reporting.tevoc A, open.reporting.tevmkt B, open.reporting.tevocgrp C, open.reporting.tev D ", _
"where A.ev_mkt_id = B.ev_mkt_id and B.ev_oc_grp_id = C.ev_oc_grp_id and D.ev_id = A.ev_id and Upper(Replace(D.[desc],'|','')) = 'home' and upper(B.name) = '|today|' and D.ev_type_id in (264, 289) and D.ev_class_id = 49
and D.start>= '" & Year & "-" & Month & "-" & Day & "'" _
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = True
.BackgroundQuery = True
.RefreshStyle = xlInsertDeleteCells
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True
.RefreshPeriod = 0
.PreserveColumnInfo = True
.ListObject.DisplayName = "Table_Query_from_SQLRA___OPEN_1"
.Refresh BackgroundQuery:=False
End With
End Sub
'Code that produces error'
Sub macro1()
Dim conn As ADODB.Connection
Set conn = New ADODB.Connection
Dim testSQL As String
Dim qd As DAO.QueryDef
Dim openbetdb As Database
conn.ConnectionString = "driver={SQL Server}; server= sqlra_db;uid=user1;APP=Microsoft Office 2013;WSID=pdfdf3001;database=openbet"
conn.Open
testSQL = "SELECT * FROM open.reporting.TevType where ev_class_id = 49 and ev_type_id in(289,330,518,13492);"
Set qd = Db.CreateQueryDef("tmpExport", testSQL)
DoCmd.TransferText acExportDelim, , "tmpExport", "C:\\export.csv"
End SubHello,
Are you connect to remote SQL Server? If so,
please make sure the target SQL Server is running and is listening on appropriate protocols. Please take a look at the following article about general steps to troubleshoot
SQL connectivity issues:
http://blogs.msdn.com/b/sql_protocols/archive/2008/04/30/steps-to-troubleshoot-connectivity-issues.aspx
Regards,
Elvis Long
TechNet Community Support -
<p>I'm getting the following error:</p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Database Connector Error: '07009:[Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index'</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"> </p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="times new roman,times" size="2">when trying to run a report in Crystal 11 (inside of Crystal Report Designer 11)</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"> </p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="times new roman,times" size="2">Please help!!!!!</font></p>
duplicate - please do not post multiple times
-
Hi,
while running jsp page i m getting error as follows:
java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Connection is busy with results for another hstmt..
what is this error...
what should i do to solve this problem...
plz let me know what is this error & how to solve this...
Thanx in advance....Why don't you do a search in google with the excpetion?
If you cannot then try this link
[http://www.idssoftware.com/faq-e.html] -
Hi,
I am getting the above error when trying to connect to a database located on remote database. if the database is on same system no problem.
any clue???????pls help me.The full error msg is as follows and the back ground of the problem is decribed below...pls help me out.
I have written some perl programs to be called by java to execute some database related tasks. My database located at a remote win2K server and database is MSSql and my programs are executing on WIN2k server. The problem is with perl talking to remote database...the following error is displaying...
"ODBC Error= [17] [] "[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]SQL Server does not exist or access denied."
Maybe you are looking for
-
Can someone help me?
-
Table changes between releases?
Hi- I am attempting to look at table column canges between release 12.0.6 and 12.1.2. How can I do this? Is it documented somewhere on metalink? I have read all the RCDs but no technical specifics are given. Maybe there is a script I can run to compa
-
Where is the inventory tab gone?
Hello, This is something I've noticed for some time now (probably since 7.0 released). No matter where I am in Spiceworks there is no Inventory tab. I can still get to it because I know I can just add /inventory to the end of the URL. In my helpdesk
-
HT3529 how do I create a voicemail greeting?
how do I set up my new iPhone voicemail greeting?
-
How come Father's Day and Chanukah are not included in calendar?
How come Father's Day and Chanukah are not included in calendar?