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 Chris Miller 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: carp
  • Order by date
  1. carp

    web app not saving "all" records suddenly

    Does the web app automatically commit changes or is there a "save" step that the user needs to execute? The app hasn't changed - are these new users who might be leaving the page without saving? I'm sure you've watched them as they did this to show you what's happening; I'm just checking...
  2. carp

    Merge Into with multiple execution

    I'm not aware of any way to do this (a more clever person will soon post a fine solution, I'm sure). In the meantime, I think you'll need to take the more traditional approach of either using two statements (merge the main table, insert the history table) or put a trigger on the main table that...
  3. carp

    Insert multiple records

    Thank you, Mikrom! This gives me something new to explore.
  4. carp

    Insert multiple records

    If your data is already in tables, you can try: INSERT INTO myTable(id, f_name, age) (SELECT id_source, f_name_source, age_source FROM source_tables WHERE filter_conditions); Like Andy, I had seen samples of inserting/joining with tuples, but they never worked right for me. Something to...
  5. carp

    Insert multiple records

    None that I'm aware of. Your best bet (barring a better suggestion) would be to use SQL*Loader or Excel.
  6. carp

    Count records until a record value changes

    SELECT MIN(ranking) - 1 AS initial_nos FROM my_table WHERE answer = 'Y';
  7. carp

    windows command in a sql script

    Not in ANSI SQL. [dazed] A lot will depend on whose SQL (Oracle, SQLServer, etc). If nothing else, you might be able to shim a bit of Java into your code and get it to work.
  8. carp

    Separate 1 row value to multiple rows

    LazyPig - I have to echo Skip's request. You have given us a partial requirement, then introduced a second problem and an unknown parameter-challenged function. You have also provided code that has hard-coded values that appear to have been made up, which completely defeats the purpose of a...
  9. carp

    Inserting Text Decimal to Table Error

    I don't suppose it really matters why it's a varchar2 - it is what it is. But whatever is being used to display the results is interpreting it as a number and displaying it in scientific notation. The data is fine; the display is off. And the OP is not responding. So it goes.
  10. carp

    Inserting Text Decimal to Table Error

    And as a second guess, I'd bet whatever you are displaying your results with is reformatting your number as scientific notation. Excel is notorious for doing this. Reformat the cell and the results will look the way you expect them too. And like Andy, I'm curious why you would cast your...
  11. carp

    Get part of a string with SQL

    I think this should get you within striking distance - it worked with a single hard-coded value, so it should work with the full table: SELECT project_number, LPAD(SUBSTR(project_number,strt, nd - strt +1),3,'0') AS route FROM (SELECT project_number AS project_number...
  12. carp

    Cross Join in an Insert Into

    My guess is that your query is returning one or more columns that are either in a different location or don't exist in your target table. Rather hard to tell without seeing the table structures.
  13. carp

    How to forcibly logout users

    Nope - you save "DROP DATABASE" for when you get laid off! [evil]
  14. carp

    How to forcibly logout users

    You probably want to look up "alter system kill session" and go from there.
  15. carp

    How to forcibly logout users

    As Andy points out, autoterminating sessions is going to lead to wasted work that has to be reaccomplished as well as potentially throwing your books off if commits have been executed part way through a process. On the other hand, you might try putting the database into restricted mode a couple...
  16. carp

    SQL SELECT - where date is null or greater than

    As Andy correctly notes - many DO frown on hard-coding, and with good reason. However, when you are using an absurd date as a default, usually people understand and relax that rule (particularly since it's more efficient than trying to come up with a calculated date (e.g., SYSDATE + 30) that...
  17. carp

    SQL SELECT - where date is null or greater than

    Andy's post points up that you should enclose separate clauses in parentheses if you are mixing ANDs and ORs. Not only does this explicitly force processing of the conjunctions in the way you intended, but also tells anybody maintaining your code in the future that you took the order of...
  18. carp

    Show value from DATA_DEFAULT field

    That sounds like TOAD is thwarting you with the (WIDEMEMO) entry. DATA_DEFAULT is the correct column, but it appears your tool is hindering you. Try the same query using SQL*PLUS in text mode and you may get better results. Unfortunately, data_default is a LONG datatype and those can be...
  19. carp

    Neither ... nor

    On further review, I find that "neither" can apply to more than two alternatives. According to Oxford Languages, the correct conjunction is "nor".
  20. carp

    Neither ... nor

    I think "neither" implies only two choices. Less ambiguous would be "not a or b or c or d".

Part and Inventory Search

Back
Top