Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default How to find record in Oracle

Hi,

If the excel sheet1 have item unique more than 10,000 item_numbers.
Could you please help to find the way how to find record in Oracle Object.
due to i need to fill out sum qty in excel sheet1.

Example :-
Excel Sheet1
Item_number Quantity
A1 ?
1250-9999 ?
B1 ?
B2 ?
..
..
..
total 10,000 rows

Oracle Object(sort by item_number)

Item_number Quantity
1259-9999 200
A1 100
A1 200
B2 100
X1 100
X2 300
..
..

Program

sub FindOCL()

SQL_Text = €śSELECT item_number, Item_Description FROM mtl_system_items_b€ť
Set objSession = CreateObject("OracleInProcServer.XOraSession")
Set objDatabase = objSession.OpenDatabase("prod", "ap/aps", 0)
Set oraDynaSet = objDatabase.DBCreateDynaset(SQL_Text, 0)

If oraDynaSet.RecordCount 0 Then
oraDynaSet.MoveFirst
End If

what i can do next to find record like below excusion

1st Loop:
Excel sheet1 item_number = "A1"
go to find data in Oracle object that item_number = "A1", if found
sum quantity all record that contain "A1" in Oracle object and fill out back
to Excel Sheet1 at line that contain "A1"
movenext to 2nd line

2nd Loop:
Excel sheet1 item_number = "1250-9999" 'at 2nd line of excel sheet1
go to find data in Oracle object that item_number = "1250-9999", if found
sum quantity all record that contain "1250-9999" in Oracle object and fill
out back to Excel Sheet1 at line that contain "1250-9999"
movenext to 3rd line

--do it until excel sheets end of record

any can help would be appreciate very much.




--
Sakol
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Find in Oracle Sakol Excel Programming 9 September 9th 08 11:57 AM
Find record MarkN Excel Worksheet Functions 3 November 9th 06 07:42 AM
Connect to Oracle using Microsoft ODBC for Oracle Kent Excel Programming 2 January 18th 06 03:53 AM
don't find my message : connect to oracle db (4.2. 19:39) b geber Excel Programming 1 February 11th 05 11:24 AM
Excel cannot 'FIND' data imported from oracle JJanzen Excel Programming 4 April 6th 04 11:33 AM


All times are GMT +1. The time now is 01:20 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"