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 Wanet Telecoms Ltd 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: *

  • Users: xxing
  • Order by date
  1. xxing

    Search Query Construct-

    Another method Select * from best_Sellers minus Select * from Orders
  2. xxing

    PL SQL help using SQLPlus

    I would suggest you go to the oracle site regards Mark
  3. xxing

    Disk Capacity trends

    Thanks George
  4. xxing

    Disk Capacity trends

    ...'zyxwvuts' ,'20140428' ,40 ,500 union all select 'zyxwvuts' ,'20140328' ,30 ,500 union all select 'zyxwvuts' ,'20140228' ,20 ,500 select * from #dummytable Need to add 6 months of the last day of the month from the last date for each server Need to calculate the additional Disk Used...
  5. xxing

    Age Bounds

    Hi I have the following data which i have scripted for your convenience: if object_id('tempdb..#people') is not null drop table #people create table #people ( DOB datetime ) insert into #people values('19630901') insert into #people values('19640901') insert into #people...
  6. xxing

    Selecting Only the Second Row in a Record Pair

    Hi Larry This might help: if object_id('tempdb..#test') is not null drop table #test create table #test ( companyID int ,[$_Paid] decimal(10,2) ,[$_Billed] decimal(10,2) ) insert into #test values(22,181.38,67.88) insert into #test values(22,5986.34,2279.03) insert into #test...
  7. xxing

    Need help with WHERE clause to exclude records

    Hi Jose Sorry I did not read your original emal properly. Try the reverse WHERE ( ProjectedSubmissionDate is not null and ActualSubmittedDate > to_date('1-Dec-10','dd-MON-yy') ) or ( ActualApprovedDate > to_date('1-Dec-10','dd-MON-yy') )...
  8. xxing

    Need help with WHERE clause to exclude records

    Try something like this in the WHERE part of your sql statement WHERE ( ProjectedSubmissionDate is null and ActualSubmittedDate < to_date('1-Dec-10','dd-MON-yy') ) or ( ActualApprovedDate < to_date('1-Dec-10','dd-MON-yy') ); regards Mark
  9. xxing

    Select * from table in a procedure

    I found a website that answered my question. Compared to sql server it's surprisingly difficult to do a simple thing like select * from a table in a stored procedure. This website has a good explanation for SQL Server Programmers http://www.akadia.com/services/ora_return_result_set.html...
  10. xxing

    Select * from table in a procedure

    ...table. Something like this. create or replace "ShowMonthlyReport" as begin execute LoadMonthlyReport -- load the data into a table select * from MonthlyReport -- display the data end; Can you please show how this is done? Shown below is the stored procedure that loads the data into...
  11. xxing

    Select * from table in a procedure

    ...on how to create a stored procedure that selects the columns from a table. Like this: create or replace procedure "P1" is begin select * from T; end; / The code to create Table T is shown: whenever sqlerror continue drop table T; create table T ( x number(2) ,y varchar2(1)...
  12. xxing

    Spliting comma-delimited column to many columns

    I found this on the internet courtesy Wayne S at http://www.sqlservercentral.com/Forums/Topic845680-338-1.aspx -- if temp table already exists (failed previous run), drop it if OBJECT_ID('tempdb..#test') IS NOT NULL DROP TABLE #test -- simulate the table with the data in it. -- NOTE how your...
  13. xxing

    Spliting comma-delimited column to many columns

    Hi Borislav Thank you for replying. The split function puts the data in rows, not columns. E.g Split function puts Apple,Pear,Kiwifruit,Orange as Fruit1 Apple Pear Kiwifruit Orange I want the data as: Fruit1 Fruit2 Fruit3 Fruit4 Apple Pear Kiwifruit Orange i.e the...
  14. xxing

    Spliting comma-delimited column to many columns

    ...null then drop table #Fruit create table #Fruit ( TheFruit varchar(100) ) insert into #Fruit values ('Apple,Pear,Kiwifruit,Orange') select * from #Fruit In my real life data there is 10 items in the TheFruit column, so parsename can't be used, and it would be a nightmare using lots...
  15. xxing

    Show the code for a stored procedure

    Hi Thank you all for your help Regards Mark
  16. xxing

    Show the code for a stored procedure

    Hi I created the following code to show the code in my stored procedures: set serveroutput ON set feedback off set linesize 200 set ver off col name format A100 Heading 'List of Stored Procedures' PROMPT -- Show the list of stored procedures for the user name SELECT distinct name FROM...
  17. xxing

    Multi value parameters

    Thanks for your help SantaMufasa
  18. xxing

    Multi value parameters

    Hi Dave Thank you for replying. I have a stored procedure that takes a parameter of a fruit name say Kiwifruit. A select statement will filter the records so only kiwifruit will appear. I would like to change the stored procedure so it can take multi-values of say kiwifruit,pear,orange. These...
  19. xxing

    Multi value parameters

    Hi I have a stored procedure that has a multi-value parameter. The parameter called GetFruitNames will have a value such as 'kiwifruit,pear,orange' In the select statement I have the folowing select fruitnames from fruit where fruitnames in (GetFruitNames) The GetFruitNames...
  20. xxing

    Inserting data into an oracle database

    Hi I worked out how to do this. Here is my code for future reference Sub InsertDataTooOracle(Sql As String) ' The following code inserts data into the oracle database ' Can only run 1 sql statement. Don't use commit. Don't use semi-colon at the end of the sql statement On Error GoTo...

Part and Inventory Search

Back
Top