Spliting Text in Sql

Results 1 to 2 of 2

Thread: Spliting Text in Sql

  1. #1
    Join Date
    Dec 1969

    Default Spliting Text in Sql

    Hello all<BR>....<BR>i hv some problem...<BR>i wanna to hv Spliing a text in SQL ...not in VB...<BR>if any one some idea plz let me know .....<BR><BR>thanks<BR>Muhammad Shahbaz<BR>

  2. #2
    peterjl@austec.net.au Guest

    Default Your db needs to be re-designed

    When designing a database you should not design fields that hold more than one piece of information.<BR><BR>E.g. If you have a field called [Description] contains the text "Dog, male, large brown", then you should have made three fields. You could have a combination of string functions (left, mid, right, search, etc) that could be successfully used to split the contents via the commas, but it would be hard work. <BR><BR>On the other hand if your had designed the table above with three separate fields, you could very easily write a query to join them.<BR><BR>So the moral is that if you find the need to split a field, then you should have had separate fields.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts