From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM,WEIRD_QUOTING autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,20a8fd50a2664794 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!k3g2000vbz.googlegroups.com!not-for-mail From: Shark8 Newsgroups: comp.lang.ada Subject: Re: Using Quotes in Quotes (if you see what I mean) Date: Thu, 11 Aug 2011 16:10:09 -0700 (PDT) Organization: http://groups.google.com Message-ID: <3370ee0c-9d6a-4c6c-988f-c7570dfa1f0a@k3g2000vbz.googlegroups.com> References: NNTP-Posting-Host: 24.230.151.194 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1313104210 3374 127.0.0.1 (11 Aug 2011 23:10:10 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Thu, 11 Aug 2011 23:10:10 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: k3g2000vbz.googlegroups.com; posting-host=24.230.151.194; posting-account=lJ3JNwoAAAAQfH3VV9vttJLkThaxtTfC User-Agent: G2/1.0 X-Google-Web-Client: true X-Google-Header-Order: HUALESNKRC X-HTTP-UserAgent: Mozilla/5.0 (Windows NT 6.1; rv:5.0) Gecko/20100101 Firefox/5.0,gzip(gfe) Xref: g2news1.google.com comp.lang.ada:20541 Date: 2011-08-11T16:10:09-07:00 List-Id: On Aug 5, 2:15=A0am, tonyg wrote: > I'm trying to search for a string containing the string "day =3D "2"" > within some xml using gnat ada. Unfortunately the "2" is causing a > problem in that ada thinks it is the end of the string before it gets > to the end. Can someone tell me how I need to represent this to search > successfully ? Well, if you're using that string as a constant, or an initialzation, the correct way is to double up the quotes OR use the & operator with the character literal. Examples: Search_String : String:=3D "day =3D ""2"""; OR Search_String : String:=3D "day =3D " & '"' & "2" & '"';