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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. hazelsisson

    Ref Cursor query containing IN operator as parameter

    Hello, I have a ref cursor report which works fine apart from one line of the query: and e.org_id in (:p_orgs) After asking on the Oracle 8i forum I understand that this is not possible, and that I need to concatenate the bind variable with the rest of the query...
  2. hazelsisson

    "IN" operator - invalid number error

    Hello, I have a stored sql query used in a report. Parameters are passed to it and all work apart from this line: and e.org_id IN (:p_orgs) e.org_id is a numeric column in the table. :p_orgs is a string that can be blank, or can contain any number of integers separated by commas (e.g. "18...
  3. hazelsisson

    Using TRIM function with outer join

    Hi guys, just a quick question (hopefully). This is my desired query (simplified): select p.dm_id, x.title from post p, post_desc x where p.post_num = trim(x.post_no)(+) But I get the error "ORA-00933: SQL command not properly ended" because of the use of the trim function before the...
  4. hazelsisson

    Help with Decode statement to replace Case

    Hi all, I've devised a CASE statement for use within my stored procedure SQL insert query but then found out it doesn't work in our version of Oracle. (The error message is PLS-00103: Encountered the symbol "CASE" when expecting one of the following: ( - + mod not null others <an...
  5. hazelsisson

    Correlated Subquery - invalid column error

    Hi guys, I have two tables: cm_std_locations loc_code char(10) loc_desc varchar2(50) cm_std_distance loc1 char(10) loc2 char(10) distance number I have a query as follows: select l.loc_code, l.LOC_DESC, d.distance from cm_std_locations l, (select s.distance from...
  6. hazelsisson

    Return row for each date in range

    Hi, I have a simple query that retrieves appointments from a table. Some appointments are over multiple days; for these the field app_date_end is not null. select a.app_date, a.app_date_end, a.app_id from m_calendar.appointments a where a.APP_DATE_END is not null; Output: APP_DATE...
  7. hazelsisson

    Union Query question

    Hi guys, I have a union query in my stored procedure as follows, which inserts the results into a database over a database link. insert into zcmintranet@hrtest( zcmi_con_no, zcmi_car_reg, zcmi_occ_no, zcmi_car_sch, zcmi_car_cc, zcmi_mls_ntx, zcmi_mls_tax ) --Part one of the query: select...
  8. hazelsisson

    Excel Macro - Method 'Range' of object '_Global' failed

    Hi guys, I have a problem with some code I've written which takes some data from Sheet 1 of my workbook and pastes it into Sheet 2. The error occurs on the line "Range(Bcell).Copy". When I debug I can see that Bcell is holding the value of the cell; I'm not sure if it should be this or the...
  9. hazelsisson

    Prevent against accidental Word document deletion

    Hello, is there any setting in Word to help prevent accidentally deleting a Word document? It's for files held on a shared network, and all I need is a prompt to say "are you sure you want to delete this file?" or something similar. I've seen the "Display Delete Confimation Dialog Box" option...
  10. hazelsisson

    Displaying function value on report

    Hi, I have a report which asks the user for a parameter [Week Commencing]. The parameter is used both in the query and is displayed on the report. I have a public function which returns a date value which is calculated from the parameter value. I'm trying to use this function in both the...
  11. hazelsisson

    Null sub-select resultset

    Hello, I have a query which is similar to this: select SUM(ENTITLEMENT) into timeAllocated from bh_entitlements where edate between l_start and l_end and staff_id = l_user and edate not in ( select tdate from bh_time t where (conditions) ) and edate not in ( select...
  12. hazelsisson

    Outer join problem

    Hi guys, It's an SQL problem - the query works fine without the date bits in the where clause, but as soon as I put them in it stops working. I've searched through many similar threads on the forum but none have pinpointed my problem! Tables: TIS_LINES Line CALLS_SUMMARY Ln Total TIS_LINES...
  13. hazelsisson

    Merging rows from union query

    Hello, I have a query that produces almost the right output but not quite. If I show you the output first it will probably help rather than trying to decipher my query. This is the output: month design_cost external_cost ------ ------------ ------------- 05/04 100 200 05/04...
  14. hazelsisson

    Eliminating duplicate data, possibly using decode

    Hello, I have a query that gathers data from 3 tables. Some of the data is duplicated, like this: TITLE ORDER NO FIRM USED ----- -------- --------- June job 191 firm1 June job 192 firm2 (It's a similar situation to thread759-615918). I would like the...
  15. hazelsisson

    Multiple select boxes to be validated

    Hello! I've got a page which contains multiple (dynamically created) select boxes, and I'm trying to check that at least one of them has a selected value before the form is submitted. The select boxes all have unique names, and are all single selects. Here's the code: function...
  16. hazelsisson

    Create portal report from dynamic query

    Hi! I have a portal application which outputs data based on options the user chooses, and the resulting data can be downloaded in an Excel format. I have managed this in the past by creating a portal report using the "reports From SQL Query" option, which accepts the user's chosen parameters...
  17. hazelsisson

    &quot;Object required&quot; error when setting Excel formula

    Hi! I'm having trouble trying to set formulae in a range of Excel cells using this code: Sub p1formula() For i = 10 To 12 Dim Address, myFormula Address = "EX" & i jref = "Sheet1!J" & i rref = "Sheet1!R" & i myFormula = "=SUM(INDIRECT(" &...
  18. hazelsisson

    Temporary table insert before creation problem!

    Hello, I have a PL/SQL procedure that creates a temporary global table (after checking that it doesn't already exist). Later on in the procedure, values are inserted into the table (after checking again to see if it exists). The problem is, when I compile the code I get the error...
  19. hazelsisson

    Send javascript variable via html form

    Hello! Here's the problem: I want to send a javascript variable via a html form by using a hidden value, but the value doesn't get sent as it should and only the default value, &quot;TEST&quot; gets sent. The javascript function, &quot;delUser&quot; is: function delUser() { var removeUserid...
  20. hazelsisson

    Select box validation (SelectedIndex == -1)

    Hi guys, here's an annoying problem that you may be able to help me with: I have two multiple select boxes side by side, which can have options swapped by clicking on an &quot;add&quot; or &quot;remove&quot; button. The problem is if nothing is selected and &quot;add&quot; or...

Part and Inventory Search

Back
Top