Identity Column in SQL Server 2000
I am working on SBO Version 2004a.
I created <b>Identity Column</b> in User Defined Table and made the entries for this Table and its columns in Sap Business One OUTB and CUFD tables respectivily.
I use this identity column to populate the Code and name fields automatically using Insert triggers.
I add 10 records to the table and now delete the 5th record. The Identity column and the code field will contain values as (1,2,3,4,6,7,8,9,10)
Now on Upgrading the patch level( SAP Business One 2004A (6.70.190) SP: 00 PL: 36), the Identity column is converted to simple INT column and no Identity column property is attached to it.
There is no T-SQL in SQL 2000 to convert an existing column to Identity Column hence I can not convert it back to Identity Column.
The Only Solution is to drop the column and re-create it as an Identity Column.
If I do so, the Identity column is polulated for all the rows starting from 1 to 9 (seed is 1).
Now on adding the next record, the primary key voilation occurs on the Code field since the next available Identity column value is 10 but this value is already used in 9th record.
<b>Is there any way so that the patch do not change the definition of the User defined tables and their columns.</b>
Thanks
Vishal Nigam
Hi Vishal,
I agree with Harold. It's against SAP's support policy to allow anyone to change SBO table definitions in any way. Other SQL objects such as stored procedures or triggers will probably be unaffected by an upgrade but it is highly likely that changes to tables will be reverted and may even cause the upgrade to fail.
There is one other possible solution, depending on how you are using the table. It is to create your own table in SQL, i.e. a table in the SBO company database but which is not a user-defined table. SBO itself will be totally unaware of the table but you could read and write to it via code (if you have written an add-on).
Kind Regards,
Owen
Similar Messages
-
What is Oracle's alternative to IDENTITY Column in SQL Server/ DB2
What is Oracle's alternative to IDENTITY Column(Auto Increment Column) in SQL Server/ DB2 ? Is Sequence and Trigger the only way out for this?
Why is Oracle not creating anything like an Identitiy column in SQL Server?What is Oracle's alternative to IDENTITY Column(Auto
Increment Column) in SQL Server/ DB2 ? Is Sequence
and Trigger the only way out for this?Of course not, you can use in your inserts sequences as well:
insert into blahh values (my_seq.nextval, ...) and use returniong clause to get the value back if necessary
You can use them in insert with subselects
insert into blah
select my_seq.nextval, ...
from ....
>
Why is Oracle not creating anything like an Identitiy
column in SQL Server?Because they are different companies with different people and thoughts and existing mechanism is sufficient i.e. one can even argue that it is even more flexible than identity btw ;)
Gints Plivna
http://www.gplivna.eu -
How can I export image column from SQL Server 2000
Hi everybody,could someone tell me how can I export an entire column( pictures type) to a folder on disk?I've tried the textcopy.exe under the SQL installation's binn folder,it can only export one picture a time,I'm trying to find an automated way to export
the whole colum's images to a folder,I'm using SQL Server 2000.Vishal,thanks for the replay,I've tried the BCP method but it seems does not work on my Sql Server 2000,also the SSIS package method is demonstrated with Sql Server 2008 R2 and my machine does not have the visual application to try it.In the BCP method,I
got prompt indicating me that I wrote something wrong in the grammer,and I'm pretty sure that maybe I made something wrong in the below part,the grammer makes me confused
INSERT
INTO @sqlStatements
SELECT 'BCP "SELECT Photograph_Data FROM [ALBSCH_Trial].[dbo].[Photograph] WHERE Photograph_ID = '''
+ CAST(Photograph_ID AS VARCHAR(500)) + '''" queryout ' + @OutputFilePath
+ CAST(Photograph_ID AS VARCHAR(500)) + '.jpg -S localhost\SQLEXPRESS2008 -T -f C:\SQLTest\Images.fmt'
FROM dbo.Photograph -
How to replace a character at a random position of a column in SQL Server 2000?
Hello everyone,
I'm trying to export the data of a table into a flat file. However, when I try to export it, a column which has a specific character (".") is being loaded as a new column into the file rather than the same column.
Here is the DDL/DML:
CREATE TABLE [dbo].[EXT_Name](
[A_Name] [VARCHAR](4),
[U_Name] [VARCHAR](256),
[U_Desc] [VARCHAR](256),
[Acc_Desc] [VARCHAR](256),
[S_Type] [VARCHAR](50))
Its just that's it. No more Keys and Indexes on this table.
Here is the bcp command I'm running:
EXEC [master].[dbo].[xp_cmdshell] 'bcp "SELECT * FROM [dbo].[Ext_Name]" queryout C:\Data\Ext_Name.dat -c -t, -T -S'
Data:
GEHG,/User/Personal/Project/Click.do,Search for User Project.,See Summary,Summaries
GEHG,/User/Personal/Project/Click.do,Search for User Project.Detail,null,Summaries
Instead for the data to be loaded as the above, its loading into the file as
GEHG,/User/Personal/Project/Click.do,Search for User Project.,See Summary,Summaries
GEHG,/User/Personal/Project/Click.do,Search for User Project.Detail
,null,Summaries
This issue occurs only when [Acc_Desc] column has the "." character in between the string. Could experts in this forum help me please?
Thank you,
Bangaaram
Known is a DROP, Unknown is an OCEAN.That is most likely not your problem. Your problem is most likely the source data has a CR and/or LF after it in the database.
Run this to remove them from Acc_Desc:
UPDATE [dbo].[EXT_Name]
SET [Acc_Desc] = REPLACE(REPLACE([Acc_Desc],CHAR(13),''),CHAR(10),'')
Perfect! Thank you Tom :)
Known is a DROP, Unknown is an OCEAN. -
JDBC to access SQL server 2000 and Oracle.
hi,
I have the following requirement. I have an oracle database which contain sql data including BLOB and CLOB. Firstly, I should migrate the data to a SQL server 2000 database. That is, i should be able to have two databases, one on oracle and the other on sql server 2000. the two databases should contain the same data, which includes BLOB data. I guess, sql server 2000 does not have a BLOB data type. What is the equivalent data type i can use to save the Oracle's BLOB data in SQL server?? Should it be image type?
After i migrate the data to the sql server 2000 database, i should be able to connect to the two databases, oracle and sql server 2000, using the same JDBC code to retrieve, insert, update and delete the data. What are the drivers that i should use. I guess, the MS JDBC driver does not support BLOB and CLOB. Is there a driver that can support BLOB for sql server 2000 and is also free???!
Kindly help... Thanks.
Arthi.Hi,
I am new to jdbc... so, pls forgive my ignorance...
I shall try to map a BLOB data column in oracle to an IMAGE data column in sql server 2000. I am using oracle jdbc driver and microsoft's jdbc driver for connecting to the databases.
My question is, can i use setBlob() method in the preparedstatement in jdbc code for setting data to the sql server 2000 image column?
rs.getBlob() and preparedstatement.setBlob()code works fine for oralce's BLOB column using oracle's jdbc driver.... Will the same jdbc code work for sql server 2000's image column using microsoft's jdbc driver??
Kindly help.
Arthi. -
Executing interface for a SQL Server 2000 target
Hi All,
I am trying doing some initial experimentation with ODI, in executing its interface in compiling a SQL Server 2000 target from the same source.
I designed an interface with Source and target having only one column, inserted some sample data for the source data store and left the target empty. After reversing the source and target data models, created an interface and inserted source and target datastores and active mapped the existing column. In the flow tab, I am using LKM MSSQL to MSSQL(Linked Servers) and IKM MSSQL Incremental Update and rectified Flow Control to 'No' as I dont have any keys in my structure. I am using CKM SQL, though no necessity of it, and also tried with LKM MSSQL to MSSQL(BCP), but could not correct the error when executing this interface.
It is not indicating any errors in diagram. In the Operator this is what is the message:
1038 : S0003 : com.microsoft.sqlserver.jdbc.SQLServerException: Cannot use empty object or column names. Use a single space if necessary.
com.microsoft.sqlserver.jdbc.SQLServerException: Cannot use empty object or column names. Use a single space if necessary.
at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PrepStmtExecCmd.doExecute(Unknown Source)
at com.microsoft.sqlserver.jdbc.TDSCommand.execute(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeUpdate(Unknown Source)
at com.sunopsis.sql.SnpsQuery.executeUpdate(SnpsQuery.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execStdOrders(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTaskTrt(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSqlC.treatTaskTrt(SnpSessTaskSqlC.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java)
at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java)
at com.sunopsis.dwg.cmd.DwgCommandSession.treatCommand(DwgCommandSession.java)
at com.sunopsis.dwg.cmd.DwgCommandBase.execute(DwgCommandBase.java)
at com.sunopsis.dwg.cmd.e.i(e.java)
at com.sunopsis.dwg.cmd.h.y(h.java)
at com.sunopsis.dwg.cmd.e.run(e.java)
at java.lang.Thread.run(Unknown Source)
Moreover in the command prompt it is indicating SQL Server Exception: Cannot invoke a rollback operation when the autocommit mode is set to true.
Please help me out in executing this interface, all help is greatly appreciated.
Many Thanks!!!Hi Rathish,
In the query it is indicating that 'It is creating view on target'. This is the step that is causing trouble.
Query description is :
create view dbo.C$_0City_Trg
as
select *
from [].odi_work.dbo.City_Trg
Thanks in Advance!!! -
Problem in Loading Data from SQL Server 2000 to Oracle 10g
Hi All,
I am a university student and using ODI for my final project on real-time data warehousing. I am trying to load data from MS SQL Server 2000 into Oracle 10g target table. Everything goes fine until I execute the interface for the initial load. When I choose the CKM Oracle(Create unique index on the I$ table) km, the following step fails:
21 - Integration - Prj_Dim_RegionInterface - Create Unique Index on flow table
Where Prj_Dim_Region is the name of my target table in Oracle.
The error message is:
955 : 42000 : java.sql.SQLException: ORA-00955: name is already used by an existing object
java.sql.SQLException: ORA-00955: name is already used by an existing object
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:316)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:282)
at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:639)
at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:185)
at oracle.jdbc.driver.T4CPreparedStatement.execute_for_rows(T4CPreparedStatement.java:633)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1086)
at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:2984)
at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3057)
at com.sunopsis.sql.SnpsQuery.executeUpdate(SnpsQuery.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execStdOrders(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTaskTrt(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSqlI.treatTaskTrt(SnpSessTaskSqlI.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java)
at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java)
at com.sunopsis.dwg.cmd.DwgCommandSession.treatCommand(DwgCommandSession.java)
at com.sunopsis.dwg.cmd.DwgCommandBase.execute(DwgCommandBase.java)
at com.sunopsis.dwg.cmd.e.i(e.java)
at com.sunopsis.dwg.cmd.g.y(g.java)
at com.sunopsis.dwg.cmd.e.run(e.java)
at java.lang.Thread.run(Unknown Source)
I am using a surrogate key column in my target table alongwith the natural key. The natural key is populated by the primary key of my source table, but for the surrogate key, I have created a sequence in my oracle schema where the target table exists and have used the following code for mapping:
<%=snpRef.getObjectName( "L" , "SQ_PRJ_DIM_REGION" , "D" )%>.nextval
I have chosen to execute this code on target.
Among my attempts to solve this problem was to set Create Index option of the CKM Oracle(Create Index for the I$ Table) to No so that it wont create any index on the flow table. I also tried to use the simple CKM Oracle km . Both solutions allowed the interface to execute successfully without any errors, but the data was not loaded into the target table.
When I right-click on the Prj_Dim_Region data store and choose Data, it shows empty. Pressing the SQL button in this data store shows a dialog box " New Query" where I see this query:
select * from NOVELTYFURNITUREDW.PRJ_DIM_REGION
But when i press OK to run it, I get this error message:
java.lang.IllegalArgumentException: Row index out of range
at javax.swing.JTable.boundRow(Unknown Source)
at javax.swing.JTable.setRowSelectionInterval(Unknown Source)
at com.borland.dbswing.JdbTable.accessChange(JdbTable.java:2959)
at com.borland.dx.dataset.AccessEvent.dispatch(Unknown Source)
at com.borland.jb.util.EventMulticaster.dispatch(Unknown Source)
at com.borland.dx.dataset.DataSet.a(Unknown Source)
at com.borland.dx.dataset.DataSet.a(Unknown Source)
at com.borland.dx.dataset.DataSet.a(Unknown Source)
at com.borland.dx.dataset.DataSet.open(Unknown Source)
at com.borland.dx.dataset.StorageDataSet.refresh(Unknown Source)
at com.borland.dx.sql.dataset.QueryDataSet.refresh(Unknown Source)
at com.borland.dx.sql.dataset.QueryDataSet.executeQuery(Unknown Source)
at com.sunopsis.graphical.frame.a.cg.actionPerformed(cg.java)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
I do not understand what the problem is and wasting days to figure it out. Any help will be highly appreciated as my deadline is too close for this project.
Thank you so much in advance.
NeelHi Cezar,
Can u plz help me with this scenario?
I have one Oracle data model with 19 source tables and one SQL Server data model with 10 target tables. I have created 10 interfaces which use JournalizedDataOnly on one of the tables in the interface; e.g in interface for DimCustomer target table, I have 2 tables, namely Customer and Address, but the journalizing filter appear only on Customer table and this option is disabled for Address automatically.
Now I want to create a package using OdiWaitForLog event detection. Is it possible to put all these 10 interfaces in just one package to populate the target tables? It works fine when I have only one interface and I use the name of one table in the interface for Table Name parameter of OdiWaitForLogData event, but when I try a comma seperated list of table names[Customer, Address] this error happens
java.sql.SQLException: ORA-00942: table or view does not exist
and if I use this method <%=odiRef.getObjectName("L","model_code","logical_schema","D")%>, I get this error
"-CDC_SET_NAME=Exception getObjectName("L", "model_code", "logical_schema", "D") : SnpLSchema.getLSchemaByName : SnpLschema does not exist" "
Please let me know how to make it work?
Do I need to create separate data models each including only those tables which appear in their corresponding interface and package? Or do I need to create multiple packages each with only one journalized interface to populate only one target table?
Thank you for your time in advance.
Regards,
Neel -
Exceptions thrown while importing tables from SQL Server 2000
Hi all,
<MyProblem:
I cannot import the tables defined in my local SQL Server. An exception is thrown --oracle.jdeveloper.cm.ds.db.ValidationException: Columns of type varchar cannot have a size specified.
/>
<What I have done:
In Oracle JDev 10g, Created a new DB connection called "SQLServerConnection" to connect to the SQL Server and it works fine. I am able to see all tables by expanding the connection.
During the creation of a new partner link named "DBAdapter", I use the adapter wizard to select DB Adapter and then select the "SQLServerConnection" DB connection I have created. I select Perform an Operation on a Table and then check Select. After I pressed OK button on the[i] Import Tables dialog, a Error messege box emmerged indicating the Exception: Columns of type varchar cannot have a size specified.
I try to change the data type of the columns of the tables to char, there is still similar exception (Columns of type char cannot have a size specified).
/>
I got the stack trace from the prompt by using jdev.exe.
<StackTrace:
oracle.jdeveloper.cm.ds.db.ValidationException: Columns of type varchar cannot h
ave a size specified.
at oracle.jdeveloper.offlinedb.OfflineDBTableValidator.validateObject(Of
flineDBTableValidator.java:116)
at oracle.jdeveloper.cm.ds.db.AbstractDBObjectProvider.validateObject(Ab
stractDBObjectProvider.java:601)
at oracle.jdeveloper.offlinedb.OfflineDBObjectProvider.updateObject(Offl
ineDBObjectProvider.java:952)
at oracle.tip.tools.ide.pm.wizard.adapter.db.DBAdapterDescriptorGenerato
r.generate(DBAdapterDescriptorGenerator.java:274)
at oracle.tip.tools.ide.pm.wizard.adapter.db.DBAdapterSelectTablePage.ac
tionPerformed(DBAdapterSelectTablePage.java:451)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:17
86)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(Abstra
ctButton.java:1839)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel
.java:420)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonL
istener.java:245)
at java.awt.Component.processMouseEvent(Component.java:5100)
at java.awt.Component.processEvent(Component.java:4897)
at java.awt.Container.processEvent(Container.java:1569)
at java.awt.Component.dispatchEventImpl(Component.java:3615)
at java.awt.Container.dispatchEventImpl(Container.java:1627)
at java.awt.Component.dispatchEvent(Component.java:3477)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
at java.awt.Container.dispatchEventImpl(Container.java:1613)
at java.awt.Window.dispatchEventImpl(Window.java:1606)
at java.awt.Component.dispatchEvent(Component.java:3477)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchTh
read.java:201)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre
ad.java:151)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre
ad.java:141)
at java.awt.Dialog$1.run(Dialog.java:540)
at java.awt.Dialog.show(Dialog.java:561)
at java.awt.Component.show(Component.java:1133)
at java.awt.Component.setVisible(Component.java:1088)
at oracle.bali.ewt.wizard.WizardDialog.runDialog(Unknown Source)
at oracle.tip.tools.ide.pm.wizard.adapter.techAdapterWizard.display(tech
AdapterWizard.java:151)
at oracle.tip.tools.ide.pm.bpelgraph.editors.PartnerLinkEditPage.handleA
dapterWizard(PartnerLinkEditPage.java:311)
at oracle.tip.tools.ide.pm.bpelgraph.editors.PartnerLinkEditPage.actionP
erformed(PartnerLinkEditPage.java:893)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:17
86)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(Abstra
ctButton.java:1839)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel
.java:420)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonL
istener.java:245)
at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:2
31)
at java.awt.Component.processMouseEvent(Component.java:5100)
at java.awt.Component.processEvent(Component.java:4897)
at java.awt.Container.processEvent(Container.java:1569)
at java.awt.Component.dispatchEventImpl(Component.java:3615)
at java.awt.Container.dispatchEventImpl(Container.java:1627)
at java.awt.Component.dispatchEvent(Component.java:3477)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
at java.awt.Container.dispatchEventImpl(Container.java:1613)
at java.awt.Window.dispatchEventImpl(Window.java:1606)
at java.awt.Component.dispatchEvent(Component.java:3477)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchTh
read.java:201)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre
ad.java:151)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre
ad.java:141)
at java.awt.Dialog$1.run(Dialog.java:540)
at java.awt.Dialog.show(Dialog.java:561)
at oracle.tip.tools.ide.pm.bpelgraph.editors.PartnerLinkDialog.create(Pa
rtnerLinkDialog.java:90)
at oracle.tip.tools.ide.pm.bpelgraph.collaxalaf.BPELGraphPane.createPart
nerLink(BPELGraphPane.java:324)
at oracle.tip.tools.ide.pm.bpelgraph.collaxalaf.BPELDNDDropHandler.handl
eDrop(BPELDNDDropHandler.java:77)
at oracle.tip.tools.ide.common.graph.DefaultGraphPaneDropTargetListener.
routeToDropHandler(DefaultGraphPaneDropTargetListener.java:212)
at oracle.tip.tools.ide.common.graph.DefaultGraphPaneDropTargetListener.
handleDrop(DefaultGraphPaneDropTargetListener.java:200)
at oracle.tip.tools.ide.pm.bpelgraph.collaxalaf.BPELGraphPaneDropTargetL
istener.handleDrop(BPELGraphPaneDropTargetListener.java:75)
at oracle.tip.tools.ide.common.graph.DefaultGraphPaneDropTargetListener.
drop(DefaultGraphPaneDropTargetListener.java:260)
at java.awt.dnd.DropTarget.drop(DropTarget.java:398)
at sun.awt.dnd.SunDropTargetContextPeer.processDropMessage(SunDropTarget
ContextPeer.java:542)
at sun.awt.dnd.SunDropTargetContextPeer.access$800(SunDropTargetContextP
eer.java:52)
at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchDropEven
t(SunDropTargetContextPeer.java:805)
at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchEvent(Su
nDropTargetContextPeer.java:743)
at sun.awt.dnd.SunDropTargetEvent.dispatch(SunDropTargetEvent.java:29)
at java.awt.Component.dispatchEventImpl(Component.java:3494)
at java.awt.Container.dispatchEventImpl(Container.java:1627)
at java.awt.Component.dispatchEvent(Component.java:3477)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483
at java.awt.LightweightDispatcher.processDropTargetEvent(Container.java:
3269)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3123)
at java.awt.Container.dispatchEventImpl(Container.java:1613)
at java.awt.Window.dispatchEventImpl(Window.java:1606)
at java.awt.Component.dispatchEvent(Component.java:3477)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchTh
read.java:201)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre
ad.java:151)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
/>
<Oracle:
Oracle JDeveloper 10.1.2.0.0 (Build 1811)
Oracle IDE 10.1.2.17.84
Business Components Version 10.1.2.17.96
UML Modelers Version 10.1.2.16.71
Versioning Support 10.1.2.16.71
WebDAV Support Version 10.1.2.16.71
Struts Modeler Version 10.1.2.6.15
BPEL Designer 10.1.2.0.0 (Build 050504)
Designer Generators Framework 10.1.2.7.56
ADF UIX 2.2.16
java.version 1.4.2_06
java.home E:\OraBPELPM\jdk\jre
java.vm.name Java HotSpot(TM) Client VM
java.vm.vendor Sun Microsystems Inc.
java.vm.version 1.4.2_06-b03
user.language zh
user.region <no value assigned>
user.name Administrator
user.home C:\Documents and Settings\Administrator
user.dir E:\OraBPELPM\integration\jdev\jdev\bin
os.name Windows 2003
os.version 5.2
os.arch x86
http.proxyHost jproxy.nju.edu.cn
http.proxyPort 8080
/>
<SQL Server:
Microsoft SQL Server 2000 with the Microsoft SQL Server 2000 Driver for JDBC Service Pack 3 installed
/>
By the way, I have read the thread Thread: DB Adapter not importing SQL Svr tables and take some of their advises but the problem still exist.
Any help would be greatly appreciated.
Thanks!
And Merry Christmas to all!Hi, ronen!
Thank you.
I followed the steps and the there were no exceptions then.
However, new runtime error emerged.
The BPEL PM Server cannot build Toplink Session. But I do not know why.
The messeges from the "Start BPEL PM Server" console about this project (named "TryDB") is as following (DoSelect is the service name of the DB Adapter):
<::Outbound><oracle.tip.adapter.db.ox.TopLinkXMLProjectInitializer initialize> I
nitializing an existing toplink project for use by the database adapter.
<::Outbound><oracle.tip.adapter.db.ox.TopLinkXMLProjectInitializer initialize> I
nitializing an existing toplink project for use by the database adapter.
<2006-01-10 16:03:02,656> <INFO> <default.collaxa.cube.compiler> 正在验证 "E:\Or
aBPELPM\integration\orabpel\domains\default\tmp\.bpel_TryDB_1.0.jar\TryDB.bpel"
<2006-01-10 16:03:05,156> <INFO> <default.collaxa.cube.engine.deployment> <CubeP
rocessFactory::generateProcessClass>
流程 "TryDB" (修订 "1.0") 编译成功。
<2006-01-10 16:03:05,765> <INFO> <default.collaxa.cube.engine.deployment> 流程 "
TryDB" (修订标记 "1.0") 已成功加载。
06/01/10 16:03:34 Tutalii: E:\OraBPELPM\integration\orabpel\lib\orabpel.jar arch
ive
<2006-01-10 16:03:34,500> <INFO> <default.collaxa.cube.ws> <AdapterFramework::Ou
tbound> file:/E:/OraBPELPM/integration/orabpel/domains/default/tmp/.bpel_TryDB_1
.0.jar/DoSelect.wsdl [ DoSelect_ptt::DoSelectSelect(DoSelectSelect_inparameters,
AirlineTableCollection) ] - Using JCA Connection Pool - max size = <unbounded>
<2006-01-10 16:03:35,093> <ERROR> <default.collaxa.cube.ws> <Database Adapter::O
utbound> <oracle.tip.adapter.db.DBManagedConnectionFactory acquireClientSession>
unable to build the TopLink Session
<2006-01-10 16:03:35,125> <ERROR> <default.collaxa.cube.ws> <Database Adapter::O
utbound> <oracle.tip.adapter.db.DBInteraction executeOutboundRead> unable to exe
cute the NamedQuery: TryDB.AirlineTable.DoSelectSelect
<2006-01-10 16:03:35,125> <ERROR> <default.collaxa.cube.ws> <AdapterFramework::O
utbound> file:/E:/OraBPELPM/integration/orabpel/domains/default/tmp/.bpel_TryDB_
1.0.jar/DoSelect.wsdl [ DoSelect_ptt::DoSelectSelect(DoSelectSelect_inparameters
,AirlineTableCollection) ] - Could not invoke operation 'DoSelectSelect' against
the 'Database Adapter' due to:
ORABPEL-11622
无法创建/访问 TopLink 会话.
此会话用于连接到数据存储。.
有关特定异常错误, 请参阅根异常错误。您可能需要在 j2ee/home/application-deploymen
ts/default/DbAdapter/oc4j-ra.xml 中配置连接设置并重新启动服务器。由 $J2EE_HOME/a
pplication-deployments/default/DbAdapter/oc4j-ra.xml 导致。
<2006-01-10 16:03:35,125> <INFO> <default.collaxa.cube.ws> <AdapterFramework::Ou
tbound> Change logging level for Logger 'default.collaxa.cube.ws' to DEBUG to se
e full error stack
<2006-01-10 16:03:35,125> <ERROR> <default.collaxa.cube.ws> <AdapterFramework::O
utbound> file:/E:/OraBPELPM/integration/orabpel/domains/default/tmp/.bpel_TryDB_
1.0.jar/DoSelect.wsdl [ DoSelect_ptt::DoSelectSelect(DoSelectSelect_inparameters
,AirlineTableCollection) ] - Rolling back JCA LocalTransaction
And in the Audit part of the BPEL Console, I got the following "details"
<remoteFault xmlns="http://schemas.oracle.com/bpel/extension">
<part name="code">
<code>4003</code>
</part>
<part name="summary">
<summary>file:/E:/OraBPELPM/integration/orabpel/domains/default/tmp/.bpel_TryDB_1.0.jar/DoSelect.wsdl [
DoSelect_ptt::DoSelectSelect(DoSelectSelect_inparameters,AirlineTableCollection) ] - WSIF JCA Execute of operation
'DoSelectSelect' failed due to: ????/?? TopLink ??. ?????????????. ; nested exception is: ORABPEL-11622 ????/??
TopLink ??. ?????????????. ????????, ??????????????? j2ee/home/application-deployments/default/DbAdapter/oc4j-ra.xml
????????????????? $J2EE_HOME/application-deployments/default/DbAdapter/oc4j-ra.xml ???</summary>
</part>
<part name="detail">
<detail>??????: ????????? [com.microsoft.jdbc.sqlserver.SQLServerDriver]?</detail>
</part>
</remoteFault>
My oc4j-ra.xml has the following content (SQLServerConnection is the name of the connection of SQL Server database):
<connector-factory location="eis/DB/SQLServerConnection" connector-name="Database Adapter">
<config-property name="driverClassName" value="com.microsoft.jdbc.sqlserver.SQLServerDriver"/>
<config-property name="connectionString" value="jdbc:microsoft:sqlserver://localhost:1433;SelectMethod=cursor;databasename=lxbpel"/>
<config-property name="userName" value="bpel"/>
<config-property name="password" value="bpel"/>
<config-property name="minConnections" value="5"/>
<config-property name="maxConnections" value="5"/>
<config-property name="minReadConnections" value="1"/>
<config-property name="maxReadConnections" value="1"/>
<config-property name="usesExternalConnectionPooling" value="false"/>
<config-property name="dataSourceName" value=""/>
<config-property name="usesExternalTransactionController" value="false"/>
<config-property name="platformClassName" value="oracle.toplink.internal.databaseaccess.SQLServerPlatform"/>
<config-property name="usesNativeSequencing" value="true"/>
<config-property name="sequencePreallocationSize" value="50"/>
<config-property name="tableQualifier" value=""/>
</connector-factory>
I think this configuration in this oc4j-ra.xml is fine
So please help me again. I owe you so much.
Thank you! -
My sample dataset (below) contains 3 groups -- 'a', 'b', 'c'. I need to retrieve the Min(startDate) and Max(EndDate) for each group so that the output looks something like this (date format not an issue):
fk minStart maxEnd
a 1/13/1985 12/31/2003
b 2/14/1986 12/31/2003
c 4/26/1987 12/31/2002
What is the Tsql to perform this type of operation? Note: the actual data resides in a sql server 2000 DB. If the Tsql is different between version 2000 and the later versions -- I would be grateful for both versions of the Tsql
--I noticed that multiple lines of Insert values doesn't work in Sql Server 2000 -- this sample is in Sql Server 2008
create table #tmp2(rowID int Identity(1,1), fk varchar(1), startDate datetime, endDate datetime)
insert into #tmp2
values
('a', '1/13/1985', '12/31/1999'),
('a', '3/17/1992', '12/31/1997'),
('a', '4/21/1987', '12/31/2003'),
('b', '2/14/1986', '12/31/2003'),
('b', '5/30/1993', '12/31/2001'),
('b', '6/15/1994', '12/31/2003'),
('b', '7/7/2001', '12/31/2003'),
('c', '4/26/1987', '12/31/1991'),
('c', '8/14/1992', '12/31/1998'),
('c', '9/10/1995', '12/31/2002'),
('c', '10/9/1996', '12/31/2000')
Thanks
Rich PRich
It is unclear what you are trying to achieve, you said that it is SQL Server 2000 but provide a sample data with SQL Server 2008 syntax
Is it possible to use UNION ALL for your queries to make its one
select * from
select * from #tmp2 t1 where exists
(select * from (select top 1 * from #tmp2 t2 where t2.fk = t1.fk order by t2.startdate) x where x.rowID = t1.rowID)
UNION ALL
select * from #tmp2 t1 where exists
(select * from (select top 1 * from #tmp2 t2 where t2.fk = t1.fk order by t2.Enddate desc) x where x.rowID = t1.rowID)
as der order by fk
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 -
Problem of Teststand3.1 database and microsoft SQL Server 2000 personal edition
I have a problem when using teststand database function with Microsoft sql server 2000. the error(seen in attached screenshot3.jpg) is:
"An error occurred calling 'LogResults' in 'ITSDBLog' of 'DBLog 1.0 Type Library'
An error occurred executing a statement.
Schema: Generic Recordset (NI).
Statement: UUT_RESULT.
[Microsoft][ODBC SQL Server Driver][SQL Server]unable to insert NULL value to column "ID", table "test.dbo.UUT_RESULT";This column is not alowed to be blank. INSERT Failed. Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.
[Microsoft][ODBC SQL Server Driver][SQL Server]terminated.
Source: TSDBLog"
Here I listed my proceess.
1, Configure in SQL Sever, please see attached screenshot0.jpg
a, Open SQL
b, build a new database with the name of test
c, import the data from "C:\Program Files\National Instruments\TestStand 3.1\Components\NI\Models\TestStandModels\Database\TestStand Results.mdb"
2, Configure Microsoft SQL sever: please see attached screenshot1.jpg
a, Open windows Control Panel and select "Data Sources (ODBC). Under system DSN tab, add a SQL server data source
3, Configure teststand database option, see attached screenshot2.jpg
a, configure logging option, enable
b, configure datalink
c, select schemas of "Generic recordset (NI)
d, No change on the tabs of "statements" and "Columns/Parameters"
4, run an seqence file with the proess model of SequentialModel.Seq.
Attachments:
Screenshot.zip 425 KBThanks Scott,
The database function is OK now after I changed imported tables in SQL Sever.
Actually, I once tried anothor method that you refered by using the scripts
located at: <TestStand>\Components\NI\Models\TestStandModels\Database\SQL Server Create Generic Recordset Result Tables.sql. Attached is the error screenshots, please help me on this.
Thanks
Jacky
Attachments:
Error.jpg 59 KB -
Java and MS SQL Server 2000 problem, please help
please help me. I am using java and MS SQL Server 2000, and I'm trying to access and verify the login. I'm getting the following error message: [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index
Can any please help in this regard.
String userNumber = (String)userNumField.getValue();
char[] userPasswordArray = userPasswordField.getPassword();
String userPassword = new String(userPasswordArray);
try {
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
java.sql.Connection connection = java.sql.DriverManager.getConnection("jdbc:odbc:Dikolobe_Data");
java.sql.PreparedStatement statement = connection.prepareStatement(
"SELECT USER_NUMBER, USER_PASSWORD, USER_CLASS, USER_STATUS " +
"FROM SYS_USER " +
"WHERE (USER_NUMBER = ? AND USER_PASSWORD = ?);");
statement.setString(1, userNumber);
statement.setString(2, userPassword);
java.sql.ResultSet result = statement.executeQuery();
if(result.next()) {
String userStatus = result.getString(4);
if(userStatus.equals("logged on")) {
String loginErrorMessage = "User with number: " + userNumber + " is already logged on.";
javax.swing.JOptionPane loginErrorPane = getNarrowOptionPane(72);
loginErrorPane.setMessage(loginErrorMessage);
loginErrorPane.setMessageType(javax.swing.JOptionPane.ERROR_MESSAGE);
javax.swing.JDialog loginErrorDialog = loginErrorPane.createDialog(null, "Login Error");
loginErrorDialog.setVisible(true);
else {
String userClassification = result.getString(3);
if(userClassification.equals("Administrator")) {
AdminHomePage newAdminHomePage = new AdminHomePage();
newAdminHomePage.setVisible(true);
else if(userClassification.equals("Educator")) {
EduHomePage newEduHomePage = new EduHomePage();
newEduHomePage.setVisible(true);
statement = connection.prepareStatement(
"UPDATE SYS_USER SET USER_STATUS = ? " +
"WHERE USER_NUMBER = ?");
statement.setString(1, "logged on");
statement.setString(2, userNumber);
statement.executeUpdate();
dispose();
}Doesn't the following link give you enough information?
http://www.google.com/search?q=invalid+descriptor+index
Anyway .. This error means that the given ResultSet column index which you're trying to retrieve the value from is out of the range. -
Query Perofmance is much more fast in SQL server 2000 than Oracle 9i
I have converted a database from SQL Server 2000 to Oracle (9.0.2).
In a stored procedure a query based on 4 tables working well in SQL Server which takes just 1 or 2 minutes to give result But in Oracle it takes 3 to 4 Hours to return the results.Although Database hit ratio is 99 plus %. In Oracle when i created indexes on 2 columns of 2 tables it just take 5 to 10 sec. But I want to get the result in less time without indexes. Because in
SQL Server it Works well without indexes.
Please reply me with some solutions or reasons
Regards
ANMost sites have a job that runs every night to keep the statistics up to date.Really? I would be very surprised if that was the case. Firstly, many sites don't want to take the hit of running stats for a whole system each night. Secondly, I would hope that many DBAs know this statement...
Always keep up to date statistics if you want your database to be efficent. ...is wrong.
The best that can happen from refreshing the statistics every night is that it makes no difference to your application. If your application is running nicely - that is, no users are yelling at you - then your current statistics are good enough. Refreshing statistics introduces instability into the system and might lead to queries performing worse than before.
Gathering stats is not the sort of thing you want to do with a scattergun. Analyze your database once, after you've reached what is a representative data volume and then leave it alone. Only refresh statistics if you have a specific issue (user complaint) and you think stale statistics might be the cause.
Cheers, APC -
Regarding ReCreating Catalog in SQL Server 2005 which was existing in SQL Server 2000
Hello
I was using SQL SERVER 2000 ... In one table I've created FULL TEXT SEARCHING ( Full text catalog along with full text indexing)
Now we had to install our db in SQL SERVER 2005 standard edition. But while taking script it gave me two lines like:
if (select DATABASEPROPERTY(DB_NAME(), N'IsFullTextEnabled')) <> 1
exec sp_fulltext_database N'enable'
GO
if not exists (select * from dbo.sysfulltextcatalogs where name = N'DEV_CAS_DiagnosisCatalog')
exec sp_fulltext_catalog N'DEV_CAS_DiagnosisCatalog', N'create'
GO
so I used this in the new db creation script...
But I couldn't get where it actually is in SQL SERVER 2005 standard edition.
and also plz help how should we create if it doesn't exist...
What could be the problem....
Thanks In advanceif (select DATABASEPROPERTY(DB_NAME(), N'IsFullTextEnabled')) <> 1
exec sp_fulltext_database N'enable'
GO
if not exists (select * from dbo.sysfulltextcatalogs where name = N'DEV_CAS_DiagnosisCatalog')
exec sp_fulltext_catalog N'DEV_CAS_DiagnosisCatalog', N'create'
GO
sp_fulltext_catalog [ @ftcat= ] 'fulltext_catalog_name' ,
[ @action= ] 'action'
[ , [ @path= ] 'root_directory' ]
Full-text catalog and index data is stored in files created in a full-text catalog directory(not on SSMS). The full-text catalog directory is created as a sub-directory of the directory specified in
@path or in the server default full-text catalog directory if
@path is not specified. The name of the full-text catalog directory is built in a way that guarantees it will be unique on the server. Therefore, all full-text catalog directories on a server can share the same path.
Refer the path column by running the below query. full text catalog file is created under the root directory by default if the path is not specified.
select * from dbo.sysfulltextcatalogs where name = N'DEV_CAS_DiagnosisCatalog'
Refer
http://technet.microsoft.com/en-us/library/ms189520(v=sql.90).aspx
Regards, RSingh -
When a database is last used in SQL Server 2000.
Hi,
Need to create one script by which I can get my any of the database lastly used, which is running on SQL Server 2000 lastly used.
Lets say if I have 100 databases running on SQL Server 2000, then using one query I can get all the databases last access date.
I dont want to implement audits because that will give only the result after audit setup.
Thanks In Advance
Regards, Ashish TripathiAgree with Erland.
There is no "column" in sys.databases till now. I would suggest you to vote for this feature.
https://connect.microsoft.com/SQLServer/feedback/details/659846/database-last-accessed-time
Balmukund Lakhani
Please mark solved if I've answered your question, vote for it as helpful to help other users find a solution quicker
This posting is provided "AS IS" with no warranties, and confers no rights.
My Blog |
Team Blog | @Twitter
| Facebook
Author: SQL Server 2012 AlwaysOn -
Paperback, Kindle -
Workarounds for searching a text field in SQL Server 2000
Hi,
I have a need to search within a text field in SQL Server 2000. In the
limitations section it notes that this is not possible. Is there a
recommended workaround for this in terms of performance? I have no way
of knowing the length of the text field in advance, and this could be
fairly large. Also, the number of objects that could contain the text
can be fairly large as well.
Thanks in advance,
KhamsoukNote that some databases (or Oracle, at least) provide alternatives to
LIKE '%foo%' that are more efficient for large text blocks, given that
you have the appropriate indexing plugins etc. etc.
To use one of those types of search operators, you'd have to put
together a custom extension.
-Fred
Fred Lucas <[email protected]> wrote:
I'm assuming that when you say 'a text field', you're referring to a
SQLServer TEXT field, as opposed to just any old field that contains
text.
Like I said, I'm by no means a SQLServer pro, but I just ran:
SELECT CLOBSTRINGX
FROM LOCATORTESTOBJECTX
WHERE CLOBSTRINGX LIKE '%o%';
and got back my test row with 'foo' in the CLOBSTRINGX column.
CLOBSTRINGX is a TEXT column.
So, it is possible that our stringContains() extension will just work.
But then again, maybe not. I'm guessing it will.
Give it a try and, if you get an error, post the generated SQL (turn on
SQL output by setting the com.solarmetric.kodo.Logger property to
'stdout') and the error that you get. Also, try executing the generated
SQL directly against your data store to see if it works there.
-Fred
Khamsouk Souvanlasy <[email protected]> wrote:
Basically I just want to use kodo's extended stringContains syntax on a
text field. Is this possible?
Khamsouk
Fred Lucas wrote:
I'm not intimitely familiar with SQLServer's text searching
capabilities, but I'm confident that you could create a query extension
that would do what you need it to do.
What is the SQL that you are trying to generate?
-Fred
Khamsouk Souvanlasy <[email protected]> wrote:
Hi,
I have a need to search within a text field in SQL Server 2000. In the
limitations section it notes that this is not possible. Is there a
recommended workaround for this in terms of performance? I have no way
of knowing the length of the text field in advance, and this could be
fairly large. Also, the number of objects that could contain the text
can be fairly large as well.
Thanks in advance,
Khamsouk
Fred Lucas
SolarMetric Inc.
202-595-2064 x1122
http://www.solarmetric.com
Maybe you are looking for
-
For the second time (I've been to the Genius Bar already once with this) my Wifi isn't working. They gave me a new iphone last time, but the new one has the same issue as the old one, I'm guessing. I've tried resetting the network but that doesn't
-
Transfer Posting for Line Items between Reconciliation Account
HI, My customer want to transfer costing the line items between a old Reconciliation Account and a New Reconciliaton Account. For example, i have a Account Group Vendor with a old Reconciliation Account " Vendor CEE". This reconciliation account has
-
How to save the text in module pool
am working with screen exit for QM01 tcode . I created one subscreen . created 2 text editors in that screen . now I want to save the text in that text editors. am using save_text , but its not working . can any one guide me regarding this with code.
-
I inserted a DVD game into the superdrive of my iMac G5. Nothing happened. It didn't load and the eject button doesn't work. I followed advice found in other discussions but nothing is working. I went to Apple "Help" on my computer and followed the d
-
direct2d acceleration on FF4 causes really bad font rendering problems for my site. Text goes on to of each other and behind pictures making it impossible to read for some parts. Disabling HW acceleration fixes the problem. Is there a script that I c