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 Rhinorhino 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: HoustonGuy
  • Content: Threads
  • Order by date
  1. HoustonGuy

    What is [sys].[sp_columns_100_rowset] used for?

    It appears [sys].[sp_columns_100_rowset] simply returns schema data for a DB, or table. I see it being called in a trace I have on a DB, but I'm not sure why a process would use this system SP. It's being called via RPC by VS2013 application. (Either manually, or automated - I can't tell.) Any...
  2. HoustonGuy

    Need to pivot semi-colon separated names

    I have this list: Name1;Name2;Name3; etc. And need to write code to pivot it to this: Name1 Name2 Name3 Any suggestions?
  3. HoustonGuy

    Best way to flatten a table without Math functions

    I have a table that spills out this way: Column1 Column2 column3 Column4 Column5 etc... John Attended John Attended John Attended Tom Attended Tom...
  4. HoustonGuy

    Syntax for Excel in an Execute SQL Task to drop a specific cell

    I'm trying to delete two specific cells in a ss. (A32 and A33) I'm using an Exxecute SQL task to do this. I've seen examples online that show this syntax: Drop Table ['My Sheet Summ$A32:A33'] - The name of my sheet is ['Agent Summary Report-Agent Summ$'] This doesn't work, since it can't find...
  5. HoustonGuy

    Syntax for Excel in an Execute SQL Task to drop a specific cell

    I'm trying to delete two specific cells in a ss. (A32 and A33) I'm using an Exxecute SQL task to do this. I've seen examples online that show this syntax: Drop Table ['My Sheet Summ$A32:A33'] - The name of my sheet is ['Agent Summary Report-Agent Summ$'] This doesn't work, since it can't find...
  6. HoustonGuy

    Opening a checked-out RDL and making a copy

    I have a report I checked-out and I want to simply open the rdl (Not in XML) and save it as a new name in my file system. (Make a copy as a new template.) I can't seem to open the rdl after I check it out. It defaults to the XML view. What am I doing wrong? VS 2008 is what I build reports in.
  7. HoustonGuy

    Silverlight4 - Unhandled Exception in the XAML Designer

    I'm getting an unhandled exception error for the designer when starting a NEW Silverlight application: System.NullReferenceException Object reference not set to an instance of an object. at...
  8. HoustonGuy

    How to check if all of the characters are the same in a field

    Is there a function that will help me check a field for a repetition of characters in a single field? Such as: Field1 ------- AAAAAAAA 00000000 44444444 Currently I use substring to check to see if the first four characters = the last four characters. If substring(Field1, 1, 4) =...
  9. HoustonGuy

    Tips on optizming my sql Code

    I feel like I have a lot of code that could definitely be written better. Here is one example: I have 20 fields that need updating from a temp table (#Final) that has a numeric counter field (MyCount). Currently I have 20 sets of updates for each field. UPDATE MainTable SET Field1 FROM...
  10. HoustonGuy

    Creating a new SQL Server agent job to call a SP

    I need help creating a new Job in SQL Server Agent (2008). I need to call a procedure on another server - 2008 as well, on a monthly basis. I'm hung up on the STEP right off the bat. It appears I need to call the SP from TSQL, but since it's on another server I'm not sure how the code should be...
  11. HoustonGuy

    Logging Processing time in SQL Code - @@timeticks?

    I would like to store processing time for each script I run. The only global variable I see that I think might work is @@Timeticks - but I can't get a good calculation when converting it to seconds. I know it is machine dependent, but I would like to understand a basic conversion to seconds or...
  12. HoustonGuy

    Looping through indexof characters

    I'm new to C# - so I'm having trouble iterating through a string using indexof. My String: "Hello|There|How|Are|You|" I'm trying to loop through each found instance of the pipe character: "|" to provide a resultset like this: Hello There How Are You Simple and frustrating. But here is the...
  13. HoustonGuy

    Using Case Statement with Merge

    I can't get the syntax correct for using a case statement within a Merge Statement. I've tried many variations. I found an example online once, but can't find it now. All of the online samples don't show conditional statements with the Merge Statement. Here's what I'm trying to do: MERGE...
  14. HoustonGuy

    Stored Procedure Best Practices

    I've got about five scripts that perform different tasks that finally generate a flat file in the end. I need to move these to Stored Procedures so they can be used by others. What's the best practice for this? Do I trigger all of the SPs from one main SP? From one main SP EXEC sp_1 EXEC...
  15. HoustonGuy

    Removing Nulls and Reordering sequentially

    I have a table with names and sequences that was loaded with some null values. The table is larger than this example, but this is the erratic Null pattern that can occur. Example: Name Sequence ------------------ John 1 Null 2 Null 3 Bill 4 Null 5 Tom 6 Jim...
  16. HoustonGuy

    How do I utilize Indexing when querying?

    I have quite a few heavy queries I'm running against a production server. A few points: I'm not a fan of NOLOCK in this instance, since I can get dirty reads. I don't have Group by, or Order by clauses that might benefit from referencing an indexed field. I do have Where clauses, but most of...
  17. HoustonGuy

    Advice for best practice when consolidating code

    I have a very, very wide resultset that I create for our processes. Once the first iteration of the table is created, I conditionally update a lot of the fields using additional statements. I have about 50 statements that update the table based on various conditions. Some of these statements use...
  18. HoustonGuy

    Syntax for multiple updates in a case statement

    I have multiple fields to update based on a single field's condition. I can't find the proper format. Update Table1 Set Field1 = CASE when Field85 <> '' then isnull(A.Field2, ''), Field2 = isnull(A.Field3, ''), Field3 = isnull(A.Field4, '') else Field1 = isnull(A.Field1, ''), Field2 =...
  19. HoustonGuy

    Unusual Select Problem

    I'm mentally stuck! I have two tables. TableOne has simple data like this: Row_Id, StartRow, StopRow TableTwo has data like this: Row_id, String_of_Data I need to select String_of_Data rows in TableTwo that fall between the StartRow and StopRow from TableOne in one resultset, so that the...
  20. HoustonGuy

    Reading XML in SQL

    I have a field that contains XML that I need to read values from. I haven't found any good references for the basic task of reading a text field containing an XML string, and selecting certain nodes needed. Any help is appreciated my brothers and sisters! :-)

Part and Inventory Search

Back
Top