Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
O

ONeil Tomlinson

@ONeil Tomlinson
About
Posts
90
Topics
57
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Generating Custom XML from multiple rows in SQL server
    O ONeil Tomlinson

    I have the following table and i would like to generate an XML as shown below. How do i go about doing this please? All help appreciated. Thanks

    id school, name, Subject, results, studentID

    1 oxford tom Maths 98 1
    2 oxford tom English 87 1
    3 oxford tom Chemistry 63 1

    4 Cambridge john Maths 50 2
    5 Cambridge john English 72 2
    6 Cambridge john Chemistry 32 2

    <Register>
    <Schools>

    <School>
    <Name>Oxford</Name>
    <Students>
    <Student>
    <Name>tom</Name>
    <Subjects>
    <Subject>
    <Name>Maths<Name>
    <grde>98<grde>
    <Subject>
    <Subject>
    <Name>English<Name>
    <grde>87<grde>
    <Subject>
    <Subject>
    <Name>Chemistry<Name>
    <grde>63<grde>
    <Subject>
    <Subjects>
    <Student>
    <Students>
    <School>

    <School>
    <Name>Cambridge</Name>
    <Students>
    <Student>
    <Name>john</Name>
    <Subjects>
    <Subject>
    <Name>Maths<Name>
    <grde>50<grde>
    <Subject>
    <Subject>
    <Name>English<Name>
    <grde>72<grde>
    <Subject>
    <Subject>
    <Name>Chemistry<Name>
    <grde>32<grde>
    <Subject>
    <Subjects>
    <Student>
    <Students>
    <School>

    <Schools>
    <Register>

    Database question database sql-server sysadmin xml

  • System.Globalization.CultureInfo [modified]
    O ONeil Tomlinson
           string varTempStr = "20100720";
           System.Globalization.CultureInfo enUk = new System.Globalization.CultureInfo("en-GB");
           DateTime billingDate1 = System.DateTime.ParseExact(varTempStr, "yyyyMMdd", enUk);
    
           System.Globalization.CultureInfo enUS = new System.Globalization.CultureInfo("en-US");
           DateTime billingDate2 = System.DateTime.ParseExact(varTempStr, "yyyyMMdd", enUS);
    
           string x = billingDate1.ToString();
           string y = billingDate2.ToString();
    

    Why are 'x' and 'y' coming back as the same value ("20/07/2010 00:00:00")? Why not x= "20/07/2010 00:00:00" and y = "07/20/2010 00:00:00"?

    modified on Wednesday, August 11, 2010 10:02 AM

    C# question

  • Check if expath exist
    O ONeil Tomlinson

    I have an XMLDocuemt supplied by a 3rd party. I have an xpath expression checking for value for element "x". The problem is sometimes element "x" does not exist and im getting a error "bject reference not set to an instance of an Object". How do i check if element x (using xpath) exist

    C# help xml question

  • How to de-batch very large XMLDocument into bit size chunks
    O ONeil Tomlinson

    Thanks i'll give that a try

    ASP.NET xml tutorial

  • How to de-batch very large XMLDocument into bit size chunks
    O ONeil Tomlinson

    There is a sample of the child record. And there are 56,000 of them in the xml document. I can realy give you the full details of what the complicated process is doing but part of it is using the Muenchian Method grouping on 'cost_centre' and 'expense_code'. The app is runningon a dev box 2.50GH, 2GB. It has 1/2GB free when app is not running

    <Transaction>
    <Entry>
    <payroll_id>payroll_id_0</payroll_id>
    <payroll_nm>payroll_nm_0</payroll_nm>
    <payRunDate>payRunDate_0</payRunDate>
    <payRunID>payRunID_0</payRunID>
    <empno>10</empno>
    <surname>surname_0</surname>
    <forename>forename_0</forename>
    <pos_ref>pos_ref_0</pos_ref>
    <pos_name>pos_name_0</pos_name>
    <element_id>element_id_0</element_id>
    <element_name>element_name_0</element_name>
    <cost_centre>c11</cost_centre>
    <expense_code>e11</expense_code>
    <debit_credit>debit_credit_0</debit_credit>
    <amount>10</amount>
    <signed_amount>10</signed_amount>
    </Entry>
    <Entry>
    ....
    </Entry>
    </Transaction>

    XML / XSL xml tutorial

  • How to de-batch very large XMLDocument into bit size chunks
    O ONeil Tomlinson

    I have a very large XMLDocument with 56,000 child records each having 8 child field elements. The application that i have written performs a complicated process on the XML. It can process 10,000 records in 5 minutes and 20,000 in 25 minutes (increases exponentially) but takes maybe 10 hours to process the 56,000 record (which is unacceptable). Whats the best way to de-batch this XML Document into bite size chunks (eg 10,000 and after 5 iteration will process 50,000. which will execute in 25-30 minutes processing time) Thanks.

    XML / XSL xml tutorial

  • How to de-batch very large XMLDocument into bit size chunks
    O ONeil Tomlinson

    I have a very large XMLDocument with 56,000 child records each having 8 child field elements. The application that i have written performs a complicated process on the XML. It can process 10,000 records in 5 minutes and 20,000 in 25 minutes (increases exponentially) but takes maybe 10 hours to process the 56,000 record (which is unacceptable). Whats the best way to de-batch this XML Document into bite size chunks (eg 10,000 and after 5 iteration will process 50,000. which will execute in 25-30 minutes processing time) Thanks.

    ASP.NET xml tutorial

  • Multiple group using Muenchian Method [modified]
    O ONeil Tomlinson

    Thanks..Really helpful ;)

    XML / XSL xml question

  • Multiple group using Muenchian Method [modified]
    O ONeil Tomlinson

    I have the following input XML. I want to group all unique Code/ID combination.

    <List>
    <Section>
    <Code>AA</Code>
    <ID>11</ID>
    <Section>
    <Section>
    <Code>AA</Code>
    <ID>11</ID>
    <Section>
    <Section>
    <Code>CC</Code>
    <ID>11</ID>
    <Section>
    <Section>
    <Code>AA</Code>
    <ID>22</ID>
    <Section>
    <Section>
    <Code>AA</Code>
    <ID>11</ID>
    <Section>
    <List>

    So result should be as shown below.

    <Code>AA</Code>
    <ID>11</ID>

    <Code>CC</Code>
    <ID>11</ID>

    <Code>AA</Code>
    <ID>22</ID>

    Im using the Muenchian Method. Currely my XSL (below) is grouping by Code (and not Code/ID combination)

    How do i get this to use a Code/ID combination? I tried nested for-each loop but no luck. Thanks

    modified on Tuesday, February 23, 2010 11:40 AM

    XML / XSL xml question

  • Is it possible to call a comand line program from within an Xml File Preprocessor
    O ONeil Tomlinson

    Is it possible to call a comand line program from within an Xml File Preprocessor. I have a connection string that is encrypted in a settings file and i want to decrypt it before assigning it to the conString value

    <configuration>
    <appSettings>
    <!-- ifdef ${_xml_preprocess} -->
    <!-- <add key="conString" value="${connectionStringWithPassowrd}"/> -->
    <!-- else -->
    <add key="conString" value="connection string"/>
    <!-- endif -->
    </appSettings>
    </configuration>

    XML / XSL xml workspace

  • Why cant i do this?
    O ONeil Tomlinson

    Why cant i do this? The value of "args" will be of similar format to the value i assigned to it. Im getting a "Index was outside the bounds of the array" error static void Main(string[] args) { args[0] = "FrGbWOfvwO0="; }

    C# database data-structures help question

  • Regular Expresion
    O ONeil Tomlinson

    Thanks dude that worked ;)

    C# regex

  • Regular Expresion
    O ONeil Tomlinson

    I need to use a Regular expression (im passing it to a Business rule engine)

    C# regex

  • Regular Expresion
    O ONeil Tomlinson

    Hi I want to write a regular expression that will match when there is no "XXSP" at the begining of the string eg "XXSPPaabbcc1234" = No Match eg "XaXSPPaabbcc1234" = Match Thanks

    C# regex

  • Stored procedure with XML as it paramternew
    O ONeil Tomlinson

    Hi I have a stored procedure that takes an XML as a parameter. The problem is that anyone could call it passing in any XML. How do i write the stored procedure so that the XML that it takes in as a parameter is based on a specific schema? Thanks Neil

    ASP.NET database xml question help

  • Stored procedure with XML as it paramter
    O ONeil Tomlinson

    Hi I have a stored procedure that takes an XML as a parameter. The problem is that anyone could call it passing in any XML. How do i write the stored procedure so that the XML that it takes in as a parameter is based on a specific schema? Thanks Neil

    Database database xml question help

  • loop a 100 time or let SQL server deal with it
    O ONeil Tomlinson

    Hi guys I have an application that does something. It generates an XML document with 100-200 items. For each item there is an ID. I need to check if this ID exist in a table in a database. At the end of checking these ID a second XML document must be created with all the ID that was not present in the Database. There are two ways of doing this ( l prefer option 2 but my senior prefers option 1) What do you thing is the best approach. Option 1: Loop through each record in the XML and with each loop make a call to SQL server to check if this ID exist. If the ID does not exist build a list of the non existing ID in some form of collection whcih will later be used for creating the second XML document Option 2: Pass the XML document to SQL server, let SQL server do the checking against all the ID and then return an XML message of the ID that does not exist Thanks Neil

    ASP.NET database sql-server sysadmin xml

  • Check if a table is empty
    O ONeil Tomlinson

    Whats the best sql Statement to check if a table is empty? Thanks ONeil

    Database database question

  • BizUnit testing with the "FactBasedRuleEngineStep"
    O ONeil Tomlinson

    Hi Im trying to write a business rule bizunit test (using the FactBasedRuleEngineStep). the problem is that i dont understand what each element in the test represents. from the bizunit documentation there is a sample and brief description of the elements but its not emough to get an understanding, the description for the elements are as below. but they are no help really. RuleStoreName--------The location of the rule store RuleSetInfoCollectionName-------The name of the rule set collection DebugTracking--------Location of the debug tracking ResultFilePath---------The path used to write updated fact documents to Facts----------Facts to pass to rules engine prior to ruleset execution I have a Policy.xml, Vocab.xml and a InputData.xml file located at (c:\BizApp\TestApp). how do i fit this information in the sample file that comes with bizunit documentation? Thanks ONeil

    IT & Infrastructure help question testing debugging business

  • Updating the xml to be returned from stored procedure
    O ONeil Tomlinson

    Thanks you have helped alot

    Database database xml help tutorial announcement
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups