Article View: borland.public.cppbuilder.database.dbexpress
Article #195Re: MySQL how get names and expresion of index
From: juanma
Date: Thu, 10 Jul 2008 11:27
Date: Thu, 10 Jul 2008 11:27
43 lines
2155 bytes
2155 bytes
At the moment I get all the information in a recordset with 'show index from
<tablename>',
also de precission of decimal with 'show columns from <tablename>'
For now I think this is the way...
"juanma" <juanmmm@cajamar.es> escribi๏ฟฝ en el mensaje
news:4874bc46@newsgroups.borland.com...
> Hi,
>
> I have a program where I can get all schema of a database (msql) through
> ADO component, now I'm triying to do that with dbexpres but I can't get de
> index names of a table (neither the precission of decimal field).
>
> I tried with a TSQLDataSet like:
>
> // ATb->IndexDefs->Update();
> for (int n = 0; n < ATb->IndexDefs->Count; n++) { //lsI->Count
> XSTID * xi = new XSTID;
> xi->cN = ATb->IndexDefs->Items[n]->Name;
> xi->cF = ATb->IndexDefs->Items[n]->FieldExpression;
> xi->nP = ATb->IndexDefs->Items[n]->Options.ToInt();
> xDB.xT[i]->xI.AddItem(xi);
> }
> ATb->Close();
> ....
>
> Also I tried with:
>
> ATb->SetSchemaInfo(stIndexes,(WideString)xDB.xT[i]->cN, (WideString) NULL,
> (WideString)"");
> ATb->Open();
> ....
>
> I thought that all this stuff was dummy in dbexpress, because the code
> work without error but don't get any information...
>
> do anybody know something about this? any clues?
>
> TIA
> Juanma
>
>
Technical Details
Message-ID:
<4875f235@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!feeder.erje.net!news.isoc.lu!newsgroups.borland.com!not-for-mailReferences:
<4874bc46@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: fb4e2,fd6189fe6f7720f X-Google-Attributes: gidfb4e2,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII From: "juanma" <juanmmm@cajamar.es> Newsgroups: borland.public.cppbuilder.database.dbexpress References: <4874bc46@newsgroups.borland.com> Subject: Re: MySQL how get names and expresion of index Date: Thu, 10 Jul 2008 13:27:44 +0200 Lines: 45 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.3138 X-RFC2646: Format=Flowed; Response X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198 NNTP-Posting-Host: 195.57.121.132 Message-ID: <4875f235@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1215689269 195.57.121.132 (10 Jul 2008 04:27:49 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!feeder.erje.net!news.isoc.lu!newsgroups.borland.com!not-for-mail