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 strongm 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. Elegabalus

    VMware on "desktop" versus "server"

    I have recently purchased a server (HP ProLiant DL380, 8GB Ram, SAS hard drives, dual quad core xeon processors, etc.) and vmware esx. I have only really ever used vmware on "desktop" machines, so I am not sure if there are any gotcha's that I am not aware of. That is, I have created a guest...
  2. Elegabalus

    return a COUNT of records by Week

    The easiest way to do this is to use the datepart function to group by. Select count(*) from table group by datepart(wk, datefield) The default week is Sunday to Saturday, but you can change it with SET DATEFIRST.
  3. Elegabalus

    Pivot Using Multiple Items

    The indexed view is not so important, but does anyone know of a more efficient way of getting these results? I can't think that hitting the table 2 times to get one result set is the optimal way of getting these results. Any help is appreciated.
  4. Elegabalus

    Pivot Using Multiple Items

    I've got a table that has multiple records for a given Person (i.e., each Person has many offices, and each office has a phone number). I want to be able to flatten the records into one row for each Person. Sample data: DECLARE @test TABLE(PersonID1 varchar(10), PersonID2 varchar(10)...
  5. Elegabalus

    Rows to Columns

    For anyone that's interested, the only solution I found was to use the regular pivot syntax for each item, and then join the resulting tables together at the end to get the correct values. i.e., Create a pivot table with the phone numbers, and insert the results into a temp table. Then create a...
  6. Elegabalus

    Rows to Columns

    Bit of new development that I'm having trouble with. I need something similar to the above, but using multiple pivot items. i.e.: DECLARE @test TABLE(id varchar(10), name varchar(10), OfficePhone varchar(20), OfficeAddress varchar(20)) insert into @test values ('c10xx2', 'joe'...
  7. Elegabalus

    scalar variable "@original_OrderID".

    In the SQLDataSource, make sure the OldValuesParameterFormatString="original_{0}" This will allow you to use the @original_<fieldname> syntax. This behavior was by default in beta1 of .NET 2.0, I believe, but you have to explicity set the oldvalues format now. Alternatively, if you changed...
  8. Elegabalus

    How do I include graphics on emailed pages?

    I've found this website (http://www.systemnetmail.com/) to be particularly helpful when dealing with emailing in ASP.NET. Particularly, http://www.systemnetmail.com/faq/4.4.aspx, although it is for 2.0 only, unfortunately. The only problem that I've come across in using this technique to embed...
  9. Elegabalus

    kinda complicated redirect question

    If all you want to do is to force a redirect to an https site is to include the following code: protected void Page_Load(Object sender, EventArgs e) { if (Request.ServerVariables["SERVER_PORT"] == "80") { string strSecureURL; strSecureURL = "https://"...
  10. Elegabalus

    Varchar(MAX) and Split Function

    Hmm...I'm using SQL Server 2005 (sorry, should have specified that). I thought 2005, with varchar(max) meant that the size limit of the variable was much, much larger than 8000 characters. Is this not true?
  11. Elegabalus

    Varchar(MAX) and Split Function

    I'm using the split function mentioned in the FAQ (http://www.tek-tips.com/faqs.cfm?fid=5207), and it's been working great for me. I pass in a delimited string, and it converts it to a table format. However, recently I needed to use it to pass in a very long string, and it has stopped working...
  12. Elegabalus

    Enum Problem

    Ah, great, thanks...that did the trick.
  13. Elegabalus

    Enum Problem

    Having an odd problem with an enum I'm working with: public enum EnumTest { Value1 = 1, Value2 = 2, Value3 = 3 } int i = 2; EnumTest val = (EnumTest)i Result: Value3 It seems when I cast an integer to the enum type, it is casting it by index, not by value. I want to be able to...
  14. Elegabalus

    App.Config ConnectionStrings

    I've got a class library that I use as the data access component of a web application in .NET 2.0. I'm having trouble getting the connectionString information from the file, though. When I hard code the connectionString into a string, it works fine. When I try to get the value from the config...
  15. Elegabalus

    SQL server and HTML

    Interesting...never knew about sp_MakeWebTask and sp_RunWebTask. Still, I would strongly recommend that you look into something more robust. The best place to start would be to take a look at the .NET quickstarts: http://asp.net/QuickStart/aspnet/Default.aspx, in particular, the data access...
  16. Elegabalus

    Rows to Columns

    SQL Server 2005 Max is 3 phone numbers.
  17. Elegabalus

    Rows to Columns

    Bit of a stupid question, really, but most of the examples I've found through searching don't really do what I need. I have two tables that are joined (person and person details). When I pass in a person ID to get all the info on that person, multiple records are returned. I want to flatten...
  18. Elegabalus

    Web Service XML Document

    But that's mostly my problem: the WSDL contract generated when using a complex type is not very helpful to clients on the other end. The dataset (and the XMLDocument, I've tried both) create a WSDL that does not contain any information on the actual structure of the response; i.e., it creates a...
  19. Elegabalus

    Web Service XML Document

    This seems like a pretty straight forward question, but I can't seem to find any concrete info when I search. I have a web service that I'd like to use to return an XML document to my clients. I have to take into account that non-.NET clients may be consuming the service as well, so I can't...
  20. Elegabalus

    Return Value Best Practices

    Ah, okay. Are there reserved return values? I was reading something online that suggested that the return value will default to 0 if the stored procedure executes without errors. That is, the return value will have a value even if you don't explicitly return a value in the sproc. Is that...

Part and Inventory Search

Back
Top