Home > Archive > Programming with dBASE > July 2005 > MySql and Rowset.IndexName









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author MySql and Rowset.IndexName
Mark.I

2005-07-11, 1:23 pm

Hi All, again.

MySql is driving to the brink of putting a boot into my PC. I'll do my best
to remain calm and collected, however.

I tried Datamodref or manual linking of tables parent--<child using the
following example:

this.PARENT1 = new QUERY()
this.PARENT1.parent = this
with (this.PARENT1)
left = 221.0
top = 13.0
width = 109.0
height = 117.0
database = form.itmsql1
sql = 'Select * from PTABLE'
active = true
endwith

with (this.PARENT1.rowset)
indexName = "P_INDEX" <<==== tells me index does not exist
endwith


this.CHILD1 = new QUERY()
this.CHILD1.parent = this
with (this.CHILD1)
left = 652.0
top = 218.0
width = 114.0
height = 117.0
database = form.itmsql1
sql = 'Select * from "CTABLE"'
active = true
endwith

with (this.ITMTF1.rowset)
indexName = "C_INDEX" <<==== tells me index does not exist
masterRowset = form.parent1.rowset
masterFields = "A_CODE" <<==== tells me field does not exist
endwith


I know both tables have their relevant index already setup. I just don't
know where to go from here.

Any idea will be immensely welcomed.


TIA

Mark.i


Robert Bravery

2005-07-11, 8:23 pm

HI Mark,

What is the case of the original index as in MySQL. As MySQL is from Linus,
its indecis could be case sensitive

Robert

"Mark.I" <nospam@thisaddress.com> wrote in message
news:Gmbbh2jhFHA.1528@news-server...
> Hi All, again.
>
> MySql is driving to the brink of putting a boot into my PC. I'll do my

best
> to remain calm and collected, however.
>
> I tried Datamodref or manual linking of tables parent--<child using the
> following example:
>
> this.PARENT1 = new QUERY()
> this.PARENT1.parent = this
> with (this.PARENT1)
> left = 221.0
> top = 13.0
> width = 109.0
> height = 117.0
> database = form.itmsql1
> sql = 'Select * from PTABLE'
> active = true
> endwith
>
> with (this.PARENT1.rowset)
> indexName = "P_INDEX" <<==== tells me index does not exist
> endwith
>
>
> this.CHILD1 = new QUERY()
> this.CHILD1.parent = this
> with (this.CHILD1)
> left = 652.0
> top = 218.0
> width = 114.0
> height = 117.0
> database = form.itmsql1
> sql = 'Select * from "CTABLE"'
> active = true
> endwith
>
> with (this.ITMTF1.rowset)
> indexName = "C_INDEX" <<==== tells me index does not exist
> masterRowset = form.parent1.rowset
> masterFields = "A_CODE" <<==== tells me field does not exist
> endwith
>
>
> I know both tables have their relevant index already setup. I just don't
> know where to go from here.
>
> Any idea will be immensely welcomed.
>
>
> TIA
>
> Mark.i
>
>



Mark.I

2005-07-11, 8:23 pm

Hi Robert,

UPPER CASE

Mark.I
"Robert Bravery" <me@u.com> wrote in message
news:ItQ1LxkhFHA.444@news-server...
> HI Mark,
>
> What is the case of the original index as in MySQL. As MySQL is from

Linus,
> its indecis could be case sensitive
>
> Robert
>
> "Mark.I" <nospam@thisaddress.com> wrote in message
> news:Gmbbh2jhFHA.1528@news-server...
> best
exist[color=darkred]

>
>



Mark.I

2005-07-11, 8:23 pm

Hi Robert,

The _WHERE_ clause in my _SELECT_ statement is causing the index problem.,
because when I remove this clause the indexname problem does not occur. But,
I need this clause to speed up the opening of my query 'cos the table
contains 30 million records.


Regards
Mark.I
"Robert Bravery" <me@u.com> wrote in message
news:ItQ1LxkhFHA.444@news-server...
> HI Mark,
>
> What is the case of the original index as in MySQL. As MySQL is from

Linus,
> its indecis could be case sensitive
>
> Robert
>
> "Mark.I" <nospam@thisaddress.com> wrote in message
> news:Gmbbh2jhFHA.1528@news-server...
> best
exist[color=darkred]

>
>



Frank J. Polan

2005-07-11, 8:23 pm

Mark,

Not sure I have an answer, but you have my sympathy<g> I'm finding it
very frustrating trying to use dBASE as a front end to MySQL. It's
real straight forward on the mysql command line

Do you need an editable rowset. If not, try using a join and WHERE
and Order BY clauses

HTH

Frank Polan

On Mon, 11 Jul 2005 21:28:45 +0100, "Mark.I" <nospam@thisaddress.com>
wrote:

>
>Hi Robert,
>
>The _WHERE_ clause in my _SELECT_ statement is causing the index problem.,
>because when I remove this clause the indexname problem does not occur. But,
>I need this clause to speed up the opening of my query 'cos the table
>contains 30 million records.
>
>
>Regards
>Mark.I
>"Robert Bravery" <me@u.com> wrote in message
>news:ItQ1LxkhFHA.444@news-server...
>Linus,
>exist
>
>



David Kerber

2005-07-12, 7:26 am

In article <syKsxXlhFHA.1796@news-server>, nospam@thisaddress.com
says...
> Hi Robert,
>
> The _WHERE_ clause in my _SELECT_ statement is causing the index problem.,
> because when I remove this clause the indexname problem does not occur. But,
> I need this clause to speed up the opening of my query 'cos the table
> contains 30 million records.


Just guessing here, but try specifying an ORDER BY clause in your SQL
statement *instead* of using the .indexname property. Somehow it sticks
in my mind that the .indexname only applies to dBase (.dbf) databases,
and that other types need to use an ORDER BY clause. Don't ask me for a
refercence on that though, because I don't have one.

Another thing to check would to be sure you have an index available to
support your WHERE clause. Don't specify it in your program, just make
sure it exists in the database...

--
Remove the ns_ from if replying by e-mail (but keep posts in the
newsgroups if possible).

Mark.I

2005-07-12, 8:23 pm

I am just glad I'm not the only one to suffer.

The reason for the indexname is that I use the rowset.findkey command, and I
desperately neede it.


Thanks
Mark.i

"Frank J. Polan" <fpolan@pcassist.on.ca> wrote in message
news:f8q5d1dgfmjievq
25iqiudejsijum3hc8q@
4ax.com...
> Mark,
>
> Not sure I have an answer, but you have my sympathy<g> I'm finding it
> very frustrating trying to use dBASE as a front end to MySQL. It's
> real straight forward on the mysql command line
>
> Do you need an editable rowset. If not, try using a join and WHERE
> and Order BY clauses
>
> HTH
>
> Frank Polan
>
> On Mon, 11 Jul 2005 21:28:45 +0100, "Mark.I" <nospam@thisaddress.com>
> wrote:
>
problem.,[color=darkred]
But,[color=darkred]
my[color=darkred]
the[color=darkred]
exist[color=darkred]

don't[color=darkred]

>
>



Mark.I

2005-07-12, 8:23 pm

Hi David,

Can I use the _ORDER BY_ clause with the Rowset.findkey() command?

I'll try it, anyhow.

Thanks
Mark.I

problem.,[color=darkred]
But,[color=darkred]
>
> Just guessing here, but try specifying an ORDER BY clause in your SQL
> statement *instead* of using the .indexname property. Somehow it sticks
> in my mind that the .indexname only applies to dBase (.dbf) databases,
> and that other types need to use an ORDER BY clause. Don't ask me for a
> refercence on that though, because I don't have one.
>
> Another thing to check would to be sure you have an index available to
> support your WHERE clause. Don't specify it in your program, just make
> sure it exists in the database...
>
> --
> Remove the ns_ from if replying by e-mail (but keep posts in the
> newsgroups if possible).
>



Mark.I

2005-07-12, 8:23 pm

_ORDER BY_ would merely order the table or results, sadly it cannot be used
for a search using rowset.findkey()

Thanks
Mark.i

"David Kerber" < ns_dkerber@ns_wraenv
iro.com> wrote in message
news:MPG. 1d3ca3567d1ca17b989d
43@news.dbase.com...
> In article <syKsxXlhFHA.1796@news-server>, nospam@thisaddress.com
> says...
problem.,[color=darkred]
But,[color=darkred]
>
> Just guessing here, but try specifying an ORDER BY clause in your SQL
> statement *instead* of using the .indexname property. Somehow it sticks
> in my mind that the .indexname only applies to dBase (.dbf) databases,
> and that other types need to use an ORDER BY clause. Don't ask me for a
> refercence on that though, because I don't have one.
>
> Another thing to check would to be sure you have an index available to
> support your WHERE clause. Don't specify it in your program, just make
> sure it exists in the database...
>
> --
> Remove the ns_ from if replying by e-mail (but keep posts in the
> newsgroups if possible).
>



Frank J. Polan

2005-07-12, 8:23 pm

Mark,

How long does the first query with the WHERE clause take? I have much
smaller tables, but I've found that a Requery using the original
WHERE and an additional Column = Variable gives the same results a
findkey()

Maybe I'm missing something, but so far I've found that the Table
Designer & dQuery are virtually unuseable with MySQL

Frank Polan

On Tue, 12 Jul 2005 21:12:15 +0100, "Mark.I" <nospam@thisaddress.com>
wrote:

>
>_ORDER BY_ would merely order the table or results, sadly it cannot be used
>for a search using rowset.findkey()
>
>Thanks
>Mark.i
>
>"David Kerber" < ns_dkerber@ns_wraenv
iro.com> wrote in message
>news:MPG. 1d3ca3567d1ca17b989d
43@news.dbase.com...
>problem.,
>But,
>
>



Mark.I

2005-07-13, 3:23 am

Hi Frank,

Right now I am going back to dbf tables and I hope I won't have to reindex
the large table.

The data in all the tables is static, but rebuild/converted every 3 months
with new upgrades.

The tables are only used for lookups.


Thanks
Mark.i


Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com