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 IamaSherpa 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. Pattycake245

    Select List into an array

    I lied, I don't think it is even getting to the .jsp I created.
  2. Pattycake245

    Select List into an array

    Thanks for your help so far Dave. OK, so I have created a small update2.jsp and I know I am able to reference it because it is clearing out my second select list. I am trying to grasp then how the second list will be populated by whatever value is selected in the first. I suppose that if I...
  3. Pattycake245

    Select List into an array

    Thanks for the input. I have never worked with iframes before. To apply your second suggestion, I am loking at a list that would cointain about 40 values in it. If you say the third is the way to go, maybe you could give me an example of how to apply it. And maybe an example of the second...
  4. Pattycake245

    Select List into an array

    I have two select lists in my form. The first will have values in it based on results from a SQL stored proc. The second one will as well, but I only want to show those items in the second select list based on the value chosen in the first. I hope I have explained myself well enough. How can...
  5. Pattycake245

    Select Question using DateTime Field

    Use convert function found in BOL. You can then chose a format that will not include the time: select convert(char(10),getdate(),120) returns 2005-08-09 Tim
  6. Pattycake245

    Populating a ColdFusion Web Edit Form using a Stored Proc

    No questions are dumb. You are obviously quite new to Cold Fusion and are trying to figure out what benefits it has. The information on Macromedia's site when you sign in will be databased, so I would assume that either SQLserver or some other database will certainly be holding your account...
  7. Pattycake245

    Populating a ColdFusion Web Edit Form using a Stored Proc

    The way I wrote that was that I was assuming a few things. There are many ways to go about it depending on what you want to do. I just assumed that when the page loads you would want to display the current companyname for that id and then have the ability to modify it. Your first Cold Fusion...
  8. Pattycake245

    Populating a ColdFusion Web Edit Form using a Stored Proc

    I actually just meant that in your cfquery and your cfstoredprocedure calls you usually have to pass the username and password to access the database: <CFSTOREDPROC procedure="dbo.Update_Northwind_Customers_Table5" datasource="Northwind" username="#username#"...
  9. Pattycake245

    Populating a ColdFusion Web Edit Form using a Stored Proc

    You are wanting to populate this form when it is loaded initially, then have the ability to edit the company name and submit and reload the form with the new value. first Cold Fusion page will include your query to select the data and dispolay the results inside of a form. You'll have to set up...
  10. Pattycake245

    Adding Sort direction to current Stored Procedure via parameter

    I guess you would never have a case where you would need the first else statement: Order by case when @sorttype='desc' then null When SortOption=8 then cast(SortFld as int) When SortOption<>8 then SortFld else '' end desc, Tim
  11. Pattycake245

    Adding Sort direction to current Stored Procedure via parameter

    You are getting error messages because you have more end statements than there are case statements. This is more what it should look like: Order by case when @sorttype='desc' then null When SortOption=8 then cast(SortFld as int) else 0 When SortOption<>8 then SortFld else...
  12. Pattycake245

    Adding Sort direction to current Stored Procedure via parameter

    Try this: CREATE PROCEDURE [dbo].[sql_searchClientAccount] @company varchar(10), @id varchar(7), @name varchar(50), @status varchar(1), @phone varchar(16), @sortOrder int, @sorttype varchar(4) AS IF @status != '0' Select TBL.id, TBL.dba_name, TBL.phone, TBL.fax...
  13. Pattycake245

    Query

    If you are passing these two values as variables from a web app you can use case statements. Something like: SELECT Downtime, Shift, Equipment FROM Report WHERE Shift = case when @shift<>'' then @shift else shift end AND Equipment=case when @equipment<>'' then @equipment...
  14. Pattycake245

    possible to have dynamic Order By in stored procedure?

    I would guess that based on the error message you are getting that it is failing when trying to insert into your @temp table. You declare the table with ID as int and if you are trying to insert an ID like T000003, it isn't going to like it. Try changing the ID field to varchar. Tim
  15. Pattycake245

    creating stored procedure with optional parameters?

    If you are going to check to see if @company is null then when passing it through to the stored proc you must set it to NULL if no values passed. CREATE PROCEDURE [dbo].[sql_searchClientPhone] @company varchar(10) = NULL, @id varchar(7), @name varchar(50), @status...
  16. Pattycake245

    output from query analyzer

    There is a way to turn these off, however it will also not print out headings to your file. Go to Tools--->Options Click on the Results tab. Uncheck the "Print Column Headers(*)" option You wil get your results only without the headings. Don't know if this helps you at all. Tim
  17. Pattycake245

    creating stored procedure with optional parameters?

    Why not use case statement instead: CREATE PROCEDURE [dbo].[sql_searchClientPhone] @company varchar(10), @id varchar(7), @name varchar(50), @status varchar(1), @phone varchar(16) AS SELECT dba_name, id FROM client WHERE id LIKE @id AND company = case...
  18. Pattycake245

    A simple query I imagine

    Try this: insert authorArtist(authorName) select a.productAuthorOrArtist from (select distinct productAuthorOrArtist from products where productAuthorOrArtist != '-') a left join authorArtist b on a.productAuthorOrArtist=b.authorName where b.authorName is null Tim
  19. Pattycake245

    if exists function in MS SQL

    if exists(select table_name from INFORMATION_SCHEMA.TABLES where table_name = <tablename>) begin DROP TABLE <tablename> end Tim
  20. Pattycake245

    Stored Procedure

    Your basic syntax for creating a stored procedure is something like below: CREATE PROCEDURE <procedure name> @variable1 varchar(100), @variable2 varchar(100) AS.... @variable1 and @variable2 would be the names of the two parameters you would be passing from VB.NET. Some basic syntax to...

Part and Inventory Search

Back
Top