Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Retreiving data from another db.

Status
Not open for further replies.

AlexR

Programmer
Feb 19, 2002
17
US
I am trying to pull data from another db and it is of the long type (in oracle). Whenever I pull in data from more than one long type my app freezes. How can i pull data from multiple long type fields? Do I have to convert the type of field before i pull the data and if so how? I am using a business object to run my query.
 
Hello..

If you don't mind i want to see the code where you pull them in.
Not the BO.
If there is now error in it it my be your BO. I can send you mime.

rr.abdulhamid@spijkenisse.nl
 
In my code I have a select statement like this "SELECT FIELD1, FIELD2, FIELD3, FIELD4 FROM TABLE@DBLINK WHERE FIELD1 = 1". Field 1 is a varchar2 and Field 2 through Field 4 are long. When I run this query it just hangs. I am invoking this query through the BO. All seems to work fine if I only query with Field1 and 2, but I need to import all of the data. Thanks for the help.

Alex
 
Do you bind the data to a dataview ???
if so try this.

in your general put :
final static COLUMNNAMES[] = {"FIELD1","FIELD2","FIELD3"}
as many fields you are retrieving.


Bind the results to your dataview and see i it works.
If you allready done this let my know...

something like this.

agpdata1.setDataSource("dsoISQL");
agpdata1.invokeQuery(hshQueryInfo);


boolean bINSITE = agpdata1.gotoFirst();

while (bINSITE )
{
Object objRecord3[] = new Object[2];

for (int i = 0; i < objRecord3.length; i++)

{

objRecord3 = agpdata1.getProperty(i);
vctRecords3.addElement(objRecord3);
}

bINSITE = agpdata1.gotoNext();

}


vctRecords3.toArray();

AgoTreeDataManager treeData = new AgoTreeDataManager(vctRecords3, COLUMN_NAMES3);
AgiRowCursor rowCursor2 = treeData.getRootRowCursor();

agDataMgr.bind(Label2, &quot;Text&quot;, &quot;getText&quot;, &quot;setText&quot;, rowCursor2, &quot;l1&quot;);
agDataMgr.bind(Label3, &quot;Text&quot;, &quot;getText&quot;, &quot;setText&quot;, rowCursor2, &quot;l2&quot;);
agDataMgr.bind(Label4, &quot;Text&quot;, &quot;getText&quot;, &quot;setText&quot;, rowCursor2, &quot;l3&quot;);

view1.setDataProvider(rowCursor2);



 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top