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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by brialex

  1. brialex

    Rounding currency

    This is what I ended up doing and it works also: SELECT CASE WHEN right(sug_retail,2) >50 and right(sug_retail,2)<95 then replace(sug_retail,right(sug_retail,2),95) else replace(sug_retail,right(sug_retail,2),50) end as NewPrice or for the full version: case when...
  2. brialex

    Rounding currency

    Does anyone know of a way to round currency to the nearest .50 or .95? I need to calculate the retail cost of an item by taking the price + $3.00 * 1.43 and round it to the nearest .50 or .95. We always want to round up for example 47.44 would be $7.50 and $7.51 would be $7.95.
  3. brialex

    Increment a field by 10

    Thanks Denis!
  4. brialex

    Increment a field by 10

    How would apply that is this scenario: I want to insert approx. 3900 records into table A but I have to look at table B in order to make sure I am pulling the correct records. For example: insert into cpnpmi_t (pmo_cde,itm_num,bil_cur,pmo_chc,pmo_cde1,seq_nbr8,itm_num1, sub_chc) SELECT...
  5. brialex

    Increment a field by 10

    I am trying to find a way to increment a field by 10 for each new record that is inserted into my table. The current value of the field is 00000000. I would like each record after the original to increment by 10 when added such as 00000010,00000020,00000030.... Can anyone show me how to do...
  6. brialex

    Sharp Develop not recognizing XML closing tags

    This will be a bit lengthy but here is some of the source BuildFileForm.cs using System; using System.Drawing; using System.Windows.Forms; using System.IO; using System.ComponentModel; namespace FFB { /// <summary> /// Description of BuildFileForm. /// </summary> public class...
  7. brialex

    Sharp Develop not recognizing XML closing tags

    All of the fields that have <tag/>, meaning the field is empty, pop up with an error that say field name can't be found. If I change the XML to <tag></tag> the file runs through just fine.
  8. brialex

    Sharp Develop not recognizing XML closing tags

    I am using a SharpDevelop program that takes an XML file and converts it to the format I need for data upload. The client is send the XML file with <test/> as the closing tag when a data field is empty instead of <test></test>. Does anyone know of a way I can change those tags to a well fromed...
  9. brialex

    SharpDevelop program coverting an XML file to desired layout

    I am using a SharpDevelop program that takes an XML file and converts it to the format I need for data upload. The client is send the XML file with <test/> as the closing tag when a data field is empty instead of <test></test>. Does anyone know of a way I can change those tags to a well fromed...
  10. brialex

    set item count to 0001 when only one donor/ increment by one when more

    Here's some sample data. The first column is order number and last column is donor number. For the first record I would like the itm_nbr to be 0001. The itm_nbr for the second record should be 0001 and 0002 for the third record since record 2 and 3 have the same donor number and order number...
  11. brialex

    set item count to 0001 when only one donor/ increment by one when more

    The donors each have a unique id assigned to them, such as 010000068070. If the same donor number appears twice you know that the donor has multiple gifts(donee's). The layout of my table is as follows: I need to populate the itm_nbr field with the record count as descibed. select ord_nbr...
  12. brialex

    set item count to 0001 when only one donor/ increment by one when more

    this is what I have so far DECLARE @count int DECLARE @pos int DECLARE @total_subs int DECLARE @N INT SET @pos = 1 SET @total_subs = 228 SET @n = 1 SET @count = 0 -- Declare temp variables to store row data DECLARE @v1 char(12) -- Declare cursor selecting correspoding data with temp...
  13. brialex

    set item count to 0001 when only one donor/ increment by one when more

    I need to update a table with item numbers for each record. For example if the donor only exists on the file one time, his item number would be 0001. however if the donor exists on file multiple times I need to set the first item number to 0001, the second to 0002, and so on. Any help would be...

Part and Inventory Search

Back
Top