|
Posted by malcolm on 02/27/06 23:40
Hello All,
On my rented space I have only one database. I have a few users at my
site
and any mysql tables I made for them have their initials as a prefix
i.e.
aa_phonelist, aa_addresses, aa_otherjunk
bb_phonelist, bb_addresses, bb_otherjunk
I want to make a drop down selection for the tables so that each can see
his/her tables
but ONLY theirs. What I really want is a query like 'Show tables where
prefix like aa_'
and send the results to the drop down. Obviously that won't work but I
have wracked my
small brain for quite some time now and can't seem to find something that
will work.
I have tried to use the show table results with things like in_array but I
just can't
make it work. This is on a logged-in page so I know the prefix but I
can't seem to limit
show tables at all and I can't find a way to strip out the other prefixes
from the resulting
array. Not zillions but quite a few tables and new ones all the time, so
this needs to be
dynamic. Anyone with help TIA
best regards
m
Navigation:
[Reply to this message]
|